I want to install a non-Ubuntu package manager like Portage (Gentoo) or Pacman (Arch) on Ubuntu 12.04 LTS.

How do I do that?


You don't. A package manager is central to a specific distribution. Gentoo, Arch, Redhat -- they all use different packaging systems. Gentoo's portage packages usually compile from source, Arch uses its own binary package format, Redhat uses RPM as packaging system -- and Debian as well as Ubuntu and Linux Mint use Debian Packages (.deb). Managing your local installation takes place using graphical frontends like Synaptic and Adept, or command-line tools like apt-get, aptitude and dpkg.

Though it is possible to install other package managers on Ubuntu (else they wouldn't be in the repositories), this is not to be recommended for the unexperienced user. One should be quite familiar with packages and package managers, how they work, etc. before even thinking about using them alongside. Otherwise it is very likely to end up with a very broken system -- as one package manager is not aware of the others, they would e.g. overwrite each others files/configurations, uninstalling a package with one package manager could break dependencies with the other, and more.

So for now I'd strongly suggest you stay with the package managers native to your system (see above).

  • 2
    Actually, we can. I just couldn't understand the contents of this guide. forums.gentoo.org/… Jul 9 '12 at 11:19
  • 9
    I didn't say "you can't", but "you don't". For "normal users" I see no reason why they would want/need to do so. There may be special cases (or they wouldn't have those things in the repos), but an unexperienced user is more likely to mess up the system if mixing them. So before doing a thing like that, one should at least be familiar with the different packaging systems, and how the stuff works -- or you end up with a broken system, as one package manager is not aware of the other, files/configurations get overwritten, an uninstall by one breaks the dependencies on the other...
    – Izzy
    Jul 9 '12 at 11:35

You cannot should not

Package managers are usually very tightly integrated with a particular Linux distribution, and you cannot usually install a native manager for one distro onto another and expect it to just work. (but see note at the end)

You can install the resulting packages, however, using tools to convert e.g. RPM to DEB, etc. This may be possible for Pacman packages. Portage, as you may be aware, builds everything from source, and you can do this on any distro, not just Gentoo.

Note: While some like yum are available in the Ubuntu Universe repositories, and even Pacman, Portage etc. could be installed in theory, it's a bad idea in practice because the packages themselves may not be suited (directory structure, etc.) for Ubuntu.

  • 4
    I don't think the internal package structure is important here (that should be handled by the concerned manager). It's rather dependencies getting messed up, files/configurations overwriting each other... in short: system integrety being in danger. One should be quite familiar with packages, packaging, and package managers before playing with "alien things".
    – Izzy
    Jul 9 '12 at 11:57
  • 2
    Yupp, you're welcome. As for the package conversion, alien might be worth mentioning as the most-commonly used tool for this task. Another possibility is using the extracted source RPM to create a .deb using debbuild. Or to use the source tarball (e.g. from Arch/Gentoo) and build your own .deb with checkinstall.
    – Izzy
    Jul 9 '12 at 12:14

Due to the different packaging systems, the package managers are not interchangeable without a lot of blood, sweat and tears. Even then, there are a lot of dependency issues, and bugs, and errors, and rabbit holes that you cannot find your way out of. No, it's not it's not impossible, but, it's not recommended. PacApt is your best bet to use Pacman AND Portage commands in Ubuntu without destroying your computer. I believe that it supports commands from all of the major package managers. This is probably your safest bet for installation of Pacman/Portage-likeness in Ubuntu. Check it out.

If it isn't what you are looking for, your best bet (and recommended course of action) may be to install the distribution of the package manager that you want to use.

PacApt Brings Arch Linux’s Amazing Pacman Package Manager to Other Linux Distributions (Well, Sort Of)

Source:  LifeHacker

Here people decribe how to install portage on other linux distibutions than gentoo: https://forums.gentoo.org/viewtopic-t-125553-postdays-0-postorder-asc-start-300.html

Here a man describe how to install whole gento on other partition from Ubuntu http://blog.abhiomkar.in/2008/07/17/install-gentoo-when-other-linux-running/

  • 3
    Welcome to Ask Ubuntu! Whilst this may theoretically answer the question, it would be preferable to include the essential parts of the answer here, and provide the link for reference. Sep 6 '16 at 23:20
  • 1
    Apart from that, both guides are almost 10 years old (2008 vs. 2007). Are you certain they still apply to recent and up-to-date installations (or even the 12.04 mentioned in the question)? Moreover, reading the OP is "a Newbie to Linux" and "Just wondering" if it works, simply pointing to some howto without mentioning the implications is a bit "careless" at least – as a newbie would almost certainly end up with a messed-up system (as I pointed out with my answer).
    – Izzy
    Sep 7 '16 at 9:56

Today there is a lot of solutions:

  • zpkg: you can install any package from alpine, centos, debian, fedora, gentoo, archlinux, ubuntu.

    With zpkg you can install programs from other distributions into your system
    zpkg will install programs to your home directory. Global installations are also supported (via -g).



  • Nix: this have a big repository.

    Nix is a powerful package manager for Linux and other Unix systems that makes package management reliable and reproducible. Nix runs on Linux, macOS and other systems. Nixpkgs, the Nix Packages collection, contains thousands of packages, many pre-compiled.


  • Another one:

JuNest (Jailed User NEST) is a lightweight Arch Linux based distribution that allows to have an isolated GNU/Linux environment inside any generic host GNU/Linux OS and without the need to have root privileges for installing packages.



I can think of a good reason to want to install Portage on a Debian system. Dependency Hell. Not just for quagmires that people encounter when there are conflicts, but to get-RID of applications that are listed as dependencies that some users may not want.


What if I am paranoid and do not want "security enhanced Linux" or anything NSA produced on my system? I am not claiming that it is inherently a security flaw, though some exploits have been found in it. What if I am just biased and want it OFF of my system, for no other reason than because the idea of it irritates me? Why should it have to remove every other important application on my system to do it?....I am not saying not to include it in your default system if you want it, but why make it such an arbitrary dependency when it clearly is NOT one?

Netmask? It is not a true dependency for your network manager. I can see how it might be useful on servers, but why do desktop users need it? In fact, it can be a liability to users who want more anonymity by using virtual systems. It also has a bug that lets you do a really easy DDOS-attack, or did back when everyone was mad about it.

Avahi server? Again, could be useful, but why do I need my desktop advertising all its services and daemons? If I wanted more anonymity I would not want such a program advertising my computers services to any hacker or government stooge that wanted it. The printer should be the one saying "I am a printer"....My computer does not need to be the one saying "I am a computer listening on all these ports, are you a printer...are you a printer...are you a printer..". When I try to remove it, it takes too much with it.

Net-bios? Dont need it. Don't want it.

What is the standard reply? Don't remove it. Its an easy answer, but it sucks.

Something like Portage, which CAN install binaries, or even Slackwares style of file management, could do some good for a Debian/Ubuntu based operating system....but then users would just have too much control over their own computers, and we can have that in the open source world now can we?

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