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.

I want to force the install system on debian linux, apt-get, to install unstable (i.e. a later version) of a package, later than the stable one recognised by the debian package maintainer.

This because I want to take advantage of new features in the later release.

I have tried the combinations of the following but none force a later version of what I want:

  • the apt-get -t unstable option
  • editing /etc/apt/apt.conf APT::Default-Release "unstable";
  • editing /etc/apt/source.list ftp.uk.debian.org/debian unstable main

Please advise.

The following is optional, if you are interested (!): I have given some specific background as to what I am trying to achieve below.

My Specific situation in detail

I want gcc 4.4 on my Debian 4 Etch system but apt-get reports latest as being 4.1.

It reports 4.1 as this is the latest stable release supported by the central Debian package maintainer.

Later versions are regarded as unstable.

I need 4.4 because it I need to install the PerlMagick module required by some graphical features in my bugzilla-3.4.4 installation.

Without 4.4 I get an error during a make/compile stage in the Perl module install for the PerlMagick module: "unrecognised command line option "-fopenmp"" - this error is about multi-processor support and is available in the latest 4.4 version of gcc but not in 4.1 which is what the debian package maintainer regards as the latest stable.

I'm hoping that if I can get gcc 4.4 on my machine then this error will not appear if I re-run the Perl install for the PerlMagick module and the graphical features will be enabled.

share|improve this question
add comment

1 Answer

up vote 3 down vote accepted

Add the testing repos to your sources.list:

deb http://ftp.debian.org/debian testing main contrib

Now do 'apt-get install gcc-4.4' ; it turns out that 4.4 is packaged so it can be installed alongside the straight 'gcc' package.

share|improve this answer
    
Can you give an example of the entry in sources.list looks exactly? I added the line: deb ftp.uk.debian.org/debian testing main to the end of sources.list but I get the error W: "Couldn't stat source package list ftp.uk.debian.org testing/main Packages (/val/lib/apt/lists/ftp.uk.debian.org_debian_dists_testing_main_binary-i386_Pack‌​ages) - stat (2 No such file or directory) W: You may want to run apt-get update to correct these problems E: Couldn't find package gcc-4.4 continued in next comment... –  therobyouknow Dec 15 '09 at 16:40
    
I ran apt-get update, then had to add APT::CacheLimit "16777216" in /etc/apt/apt.conf.d/70debconf to cure a problem with not enough "cache" memory during the update. continued in next comment... –  therobyouknow Dec 15 '09 at 16:41
    
But I can't fix these errors. How do I get these dependencies to install. # apt-get install gcc-4.4 <snip> The following packages have unmet dependencies. gcc-4.4: Depends: gcc-4.4-base (= 4.4.2-3) but 4.4.2-5 is to be installed Depends: cpp-4.4 (= 4.4.2-3) but it is not going to be installed Depends: libgcc1 (>= 1:4.4.2-3) but 1:4.1.1-21 is to be installed Depends: libgomp1 (>= 4.4.2-3) but it is not going to be installed E: Broken packages Thanks so far for your help. –  therobyouknow Dec 15 '09 at 16:43
    
So I think I solved the "Couldn't stat source package list ftp.uk.debian.org testing/main Package" error, I think my sources.list is correct but I can't get apt-get to install the dependencies mentioned in last comment above. –  therobyouknow Dec 15 '09 at 16:45
    
+1 and accepted answer, sorry it took so long, for your approach to use testing repos to control which versions are used. –  therobyouknow Dec 21 '10 at 9:44
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.