Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

After I run yum install git

it shows the error

Error: Package: git-1.7.6.1-1.el5.rf.i386 (rpmforge)
       Requires: libcurl.so.3
You could try using --skip-broken to work around the problem
You could try running: rpm -Va --nofiles --nodigest

Do I need to install libcurl.so.3 or download git from the web and install?

share|improve this question
add comment

migrated from stackoverflow.com Sep 3 '11 at 11:29

This question came from our site for professional and enthusiast programmers.

9 Answers

You should install curl, since it is listed as a direct dependency for git (alongside openssl-1.0.0d, libssh2, libiconv, libintl, libidn, expat and zlib)

Make sure it is a curl 7.21.7, because the previous one was broken for any ssh access.

As Keith mentions (+1), you need curl-devel. There is only a libcurl-devel-7.19.7-16.el6.i686.rpm package which could be old enough for ssh to still work.

share|improve this answer
    
I already installed crul, but it still shows the error –  Juni Sep 3 '11 at 0:37
add comment

I don't think installing the curl package installs libcurl.so.3. The curl package provides the curl program and associated files, not the library.

For Centos, the package you need is probably called something like curl-devel.

I'm a surprised yum didn't offer to install the dependencies for you. On CentOS 5.6, the yum man page says that yum install "Is used to install the latest version of a package or group of packages while ensuring that all dependencies are satisfied". I suppose it's possible that the dependencies aren't configured correctly, but that seems unlikely for something as popular as git.

Try yum install curl-devel followed by yum install git.

share|improve this answer
    
Agree, except I don't find very recent curl-devel rpm for CentOS6. +1 –  VonC Sep 3 '11 at 8:43
add comment

libcurl.so.3 does come from curl package.

rpm -qf libcurl.so.3.0.0
curl-7.15.5-9.el5_6.2

I created a symbolic link on my system under /usr/lib64.

libcurl.so.3 -> libcurl.so.4.1.1
share|improve this answer
    
This looks like it was intended to be a comment to Keith Thompson's answer. –  bahamat Sep 13 '11 at 16:02
add comment

The problem is that you are trying to install the el5 version of git (git-1.7.6.1-1.el5.rf.i386). I had the same issue as described here.

I fixed it by enabling the rpmforge extras and it picked up el6 of git (then could just yum install)

I'm sure this is an issue with the centos default repos, I mean it should install el6 by default?

share|improve this answer
    
i have enabled it, also didarestart, but still its pointing to el5. Plz help –  Avi C Jul 23 '13 at 16:28
    
ok. Norrad's answer worked –  Avi C Jul 23 '13 at 18:08
    
For me it was a combination of this and Norrad's answers. After installing the el6 version I had to run "yum clean all" as yum was still reading the old cached repo data. –  Juan Oct 9 '13 at 19:10
add comment

First off, under root, at /etc/yum.conf edit the file, and comment out the exclude line with a leading ; i.e. ;exclude (I use WinSCP at http://winscp.net to log in as it has a built-in modified notepad editor, along with PuTTY for SSH access.)

After reading the above about installing curl-devel, it didn't work for me. But yum reinstall curl-devel worked. I then followed that up with yum install git, and it proceeded to install git and 2 additional needed files.

share|improve this answer
add comment

I tried

$ yum install git-all.noarch which doesn't depend on architectures.

share|improve this answer
add comment

Git is included with the EL6 base repository; it's not necessary to install another repository to get access to it.

In the case of the original question, it looks like you are trying to use the rpmforge repo for EL5 on an EL6 system. Your best bet here is to fix or remove the repo from /etc/yum.repos.d.

share|improve this answer
add comment

I had the same problem under CentOS 6.3. Running yum provides git gave me two choices:

 git-1.7.1-2.el6_0.1.x86_64 : Fast Version Control System
 git-1.7.4.1-1.el5.x86_64 : Fast Version Control System

So, I did a yum install git-1.7.1-2.el6_0.1.x86_64 and it installed the .el6 version of git, along with perl-Error and perl-Git, and issues no errors and NO missing libcurl.so.3 files!

share|improve this answer
    
works for me.. thanks... –  Gaurav Sharma Jul 23 '13 at 11:54
    
worked for me too. Thanx –  Avi C Jul 23 '13 at 18:09
add comment

From https://forum.linode.com/viewtopic.php?t=8777

Changing el5 to el6 seems to do the job.

su root
cd /etc/yum.repos.d
for FILE in *; do mv $FILE $FILE.old; sed 's/el5/el6/g' $FILE.old > $FILE; done
yum clean all

This fixed it for me.

share|improve this answer
add comment

protected by Gilles Apr 17 '13 at 23:35

Thank you for your interest in this question. Because it has attracted low-quality answers, posting an answer now requires 10 reputation on this site.

Would you like to answer one of these unanswered questions instead?