我如何告诉Cygwin一个依赖是从源代码构建的? [英] How can I tell Cygwin that a dependency was built from source?

查看:320
本文介绍了我如何告诉Cygwin一个依赖是从源代码构建的?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用Git与Cygwin(我喜欢Cygwin到Mingw,我不grok PoshGit)。

I'm using Git with Cygwin (I prefer Cygwin to Mingw, and I do not grok PoshGit).

不幸的是,Git版本的Cygwin库是旧的(1.7.9-1)。所以我从源代码编译git 1.8(其实btw其实并不是我想象的那么难,但是我离题)。

Unfortunately, the version of Git available on Cygwin repository is kind of old (1.7.9-1). So I built git 1.8 from source (which btw was in fact not so hard as I thought it would be, but I digress).

唯一的问题是Cygwin安装程序不会知道Git已经安装。如果我尝试安装一些依赖于Git的软件包(例如, Tig ),Cygwin安装程序将告诉我它需要安装Git。

The only problem is that the Cygwin setup does not become "aware" that Git is already installed. If I try to install some package that depends on Git (for instance, Tig), the Cygwin setup will tell me that it needs to install Git.

有没有办法解决这个问题?我可以以某种方式通知Git已经安装,并且Cygwin安装程序应该尝试使用它来解决对Git包的任何依赖。

Is there any way to fix that? Can I inform, somehow, that Git is already installed, and that the Cygwin setup should try to use that to resolve any dependency on the Git package?

推荐答案

有同样的问题。而不是安装一个git完成的包,还有另一种方法。从 https://下载git-completion.bash文件raw.githubusercontent.com/git/git/master/contrib/completion/git-completion.bash ,将其放在/etc/bash_completion.d/目录中,将文件重命名为git并重新启动Cygwin。你得到git完成(假设你已经安装了bash-completion)没有任何依赖。缺点是你没有自动更新这个文件,但Cygwin版本是更古老的。

Had the same problem. Instead of installing a package for git-completion, there is another way to do it. Download the git-completion.bash file from https://raw.githubusercontent.com/git/git/master/contrib/completion/git-completion.bash, put it in /etc/bash_completion.d/ directory, rename the file to "git" and restart Cygwin. You get git completion (assuming you have bash-completion installed already) without any dependencies. The disadvantage is that you don't have auto update for this file, but the Cygwin version is more ancient anyway.

这篇关于我如何告诉Cygwin一个依赖是从源代码构建的?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆