Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

Am trying to install cURL on my ubuntu server using the command

sudo apt-get install php5-curl

However i get the following error

Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
php5-curl: Depends: phpapi-20060613+lfs
Depends: php5-common (= 5.2.6.dfsg.1-3ubuntu4.5) but 5.3.2-0.dotdeb.1 is to be installed
E: Broken packages

I am running PHP Version 5.3.2-0.dotdeb.1 on my server.

When I try this command

sudo apt-get install curl libcurl3 libcurl3-dev php5-curl

I get the following output

Reading package lists... Done
Building dependency tree
Reading state information... Done
Package libcurl3-dev is a virtual package provided by:
  libcurl4-openssl-dev 7.18.2-8ubuntu4.1
You should explicitly select one to install.
E: Package libcurl3-dev has no installation candidate
root@server:~# sudo apt-get install curl libcurl3 libcurl3-dev php5-curl
Reading package lists... Done
Building dependency tree
Reading state information... Done
Package libcurl3-dev is a virtual package provided by:
  libcurl4-openssl-dev 7.18.2-8ubuntu4.1
You should explicitly select one to install.
E: Package libcurl3-dev has no installation candidate

Whats the issue? I need to get curl up and running.

share|improve this question
1  
Did you do some pinning to get dotdeb to work? You will need to get curl from the same repo as php. –  Zoredache Feb 24 '12 at 9:01
    
Pinning? Please explain. The php/apache installation works just fine for quite sometime now and its only recently that I need cURL for a particular app. –  davykiash Feb 24 '12 at 9:06
    
Post the output of these commands apt-cache policy php5-common, apt-cache policy php5-curl, cat /etc/apt/sources.list /etc/apt/sources.list.d/*, and cat /etc/apt/preferences.d/*. –  Zoredache Feb 25 '12 at 1:34
    
For the record DOTDEB is not designed to be used with Ubuntu. It may work in some conditions, it is certainly not supported. You may have just reached a point where what you want is simply impossible with that set of packages. –  Zoredache Feb 25 '12 at 1:38
    
I got it working by changing my sources.Thanx –  davykiash Mar 19 '12 at 10:35
add comment

1 Answer

Depends: php5-common (= 5.2.6.dfsg.1-3ubuntu4.5) but 5.3.2-0.dotdeb.1 is to be installed

apt is not comfortable with your 5.3.2-0.dotdeb.1 so it misses php5-common.

fix your php version. easiest way should be to install php5-common regularly over apt and try again.

share|improve this answer
    
If he does that, he will almost certainly break his PHP installation, or possibly just force it to revert back to 5.2.6 instead of 5.3.2. –  Zoredache Feb 25 '12 at 1:30
    
As you wrote, dotdeb isn't thought for ubuntu. So the best way would be to get back to start by removing it and using the main apt repos. Don't know why this should break everything... –  Mose Feb 25 '12 at 10:04
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.