Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Recently installed php5.3.22 on Ubuntu 12.04 from an excellent install script provided by git:// This works perfectly.

The issue I have is that I now want to also install phpunit. When i try apt-get install phpunit - It wants to also include a bunch of dependencies such as php5-common, etc. (I suspect apt-get does not already know that I have php5.3.22 installed and wants to install php5.4.x - since it is the distro release version.)

I do not want to conflict/overwrite my (already tuned) php5.3.22 install.

I thought about using a php phar file to run php unit. but first want to know if anyone knows simple step by step instructions to inform apt-get about the existing php5.3.22 install so that I can use apt-get in the future to configure php for upgrades, add modules, etc.

There are many questions about installing older versions of software on Ubuntu, but I am looking specifically to inform the package management system about which is the installed current version.

share|improve this question

migrated from Mar 9 '13 at 16:30

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

I'd suggest using composer in your PHP project to manage/install phpunit.

Just add the following to your composer.json file

"require-dev": {
    "phpunit/PHPUnit": "3.7.*"
share|improve this answer
Thanks for the suggestion Lee, but what i am really after is a way to tell apt-get about the current version of php that already exists on my system so that i can use apt-get to do upgrades. your suggestions is a good alternative to get the project working with the required dependencies. but I think that can also be accomplished with phar right? – windsor Mar 8 '13 at 15:41
perhaps this is a serverfault question? – windsor Mar 8 '13 at 15:45
up vote 0 down vote accepted

You use equivs to inform the package management system that you've installed software through other means. See, e.g., - credit: and andrew beacock

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .