尝试安装以管理员身份运行的xclip,但得到了这个:
$ apt-cyg install xclip Installing xclip xclip-0.12-2.tar.xz: OK Unpacking... Package xclip requires the following packages, installing: bash coreutils cygwin gzip libX11_6 libXmu6 tar Package bash is already installed, skipping Package coreutils is already installed, skipping Package cygwin is already installed, skipping Package gzip is already installed, skipping Package libX11_6 is already installed, skipping Package libXmu6 is already installed, skipping Package tar is already installed, skipping Package xclip installed Tommy@Tommy-PC ~ $ xclip C:/opt/cygwin64/bin/xclip.exe: error while loading shared libraries: cygXmu-6.dll: cannot open shared object file: No such file or directory
所以我删除了所有X11库并尝试重新安装。但这给出了一个更有帮助的错误:
Tommy@Tommy-PC ~ $ apt-cyg remove libXmu6 libX11_6 libX11_6 libXt6 Removing libXmu6 Package libXmu6 removed Removing libX11_6 Package libX11_6 removed Package libX11_6 is not installed, skipping Removing libXt6 Package libXt6 removed Tommy@Tommy-PC ~ $ apt-cyg install libXmu6 libX11_6 libX11_6 libXt6 Installing libXmu6 libXmu6-1.1.2-1.tar.xz: OK Unpacking... Package libXmu6 requires the following packages, installing: cygwin libX11_6 libXext6 libXt6 Package cygwin is already installed, skipping Installing libX11_6 --2018-05-22 09:45:18-- http://cygwin.mirror.constant.com//x86_64/release/libX11/libX11_6/libX11_6-1.6.5-1.tar.xz Resolving cygwin.mirror.constant.com... 108.61.5.83 Connecting to cygwin.mirror.constant.com|108.61.5.83|:80... connected. HTTP request sent, awaiting response... 200 OK Length: 750980 (733K) [application/octet-stream] Saving to: `libX11_6-1.6.5-1.tar.xz' libX11_6-1.6.5-1.ta 100%[===================>] 733.38K 1.11MB/s in 0.6s 2018-05-22 09:45:19 (1.11 MB/s) - `libX11_6-1.6.5-1.tar.xz' saved [750980/750980] libX11_6-1.6.5-1.tar.xz: OK Unpacking... Package libX11_6 requires the following packages, installing: cygwin libxcb1 Package cygwin is already installed, skipping Package libxcb1 is already installed, skipping Package libXext6 is already installed, skipping Installing libXt6 libXt6-1.1.5-1.tar.xz: OK Unpacking... Package libXt6 requires the following packages, installing: cygwin libICE6 libSM6 libX11_6 Package cygwin is already installed, skipping Package libICE6 is already installed, skipping Package libSM6 is already installed, skipping Package libX11_6 is already installed, skipping Package libXmu6 installed Package libX11_6 is already installed, skipping Package libX11_6 is already installed, skipping Package libXt6 is already installed, skipping Tommy@Tommy-PC ~ $ xclip C:/opt/cygwin64/bin/xclip.exe: error while loading shared libraries: ?: cannot open shared object file: No such file or directory
也许我可以尝试从源代码编译或使用Cygwin安装程序?
答案 0 :(得分:1)
安装软件包的规范方法是使用cygwin安装程序 apt-cyg可能很方便,但它不是官方套餐。
验证软件包安装的规范方法是使用cygcheck。
avg()
如果我们模拟包裹的损坏
$ cygcheck -c libX11_6
Cygwin Package Information
Package Version Status
libX11_6 1.6.5-1 OK
您还可以使用cygcheck-dep包来查询依赖项,例如:
$ mv /usr/bin/cygX11-6.dll /usr/bin/cygX11-6.dll.tmp
$ cygcheck -cv libX11_6
Cygwin Package Information
Last downloaded files to: e:\downloads\cygwin_cache
Last downloaded files from: http://mirrors.kernel.org/sourceware/cygwin/
Package Version Status
Missing file: /usr/bin/cygX11-6.dll from package libX11_6
libX11_6 1.6.5-1 Incomplete