Problem installing RPM on Ubuntu [closed]

0

I'm trying to install some RPM packages in my Ubuntu , but I'm getting messages from dependency failures. The strange thing is that all the dependencies are already installed in my SO .

I created a deps directory with 4 rpm: eventlet-0.17.1-1.noarch.rpm , greenlet-0.4.5-1.x86_64.rpm , pycrypto-2.6.1-2.x86_64.rpm , pyparsing-2.0.3-1.noarch.rpm .

I ran the following command:

sudo rpm -ivh *.rpm

I get the following error message:

  

python (abi) = 2.7 is needed by eventlet-0.17.1-1.noarch   libc.so.6 () (64bit) is needed by greenlet-0.4.5-1.x86_64   libc.so.6 (GLIBC_2.14) (64bit) is needed by greenlet-0.4.5-1.x86_64   libc.so.6 (GLIBC_2.2.5) (64bit) is needed by greenlet-0.4.5-1.x86_64   libc.so.6 (GLIBC_2.4) (64bit) is needed by greenlet-0.4.5-1.x86_64   libpthread.so.0 () (64bit) is needed by greenlet-0.4.5-1.x86_64   libpython2.7.so.1.0 () (64bit) is needed by greenlet-0.4.5-1.x86_64   python (abi) = 2.7 is needed by greenlet-0.4.5-1.x86_64 rtld (GNU_HASH)   is needed by greenlet-0.4.5-1.x86_64 libc.so.6 () (64bit) is needed by   pycrypto-2.6.1-2.x86_64 libc.so.6 (GLIBC_2.14) (64bit) is needed by   pycrypto-2.6.1-2.x86_64 libc.so.6 (GLIBC_2.2.5) (64bit) is needed by   pycrypto-2.6.1-2.x86_64 libc.so.6 (GLIBC_2.4) (64bit) is needed by   pycrypto-2.6.1-2.x86_64 libpthread.so.0 () (64bit) is needed by   pycrypto-2.6.1-2.x86_64 libpython2.7.so.1.0 () (64bit) is needed by   pycrypto-2.6.1-2.x86_64 python (abi) = 2.7 is needed by   pycrypto-2.6.1-2.x86_64 rtld (GNU_HASH) is needed by   pycrypto-2.6.1-2.x86_64 python (abi) = 2.7 is needed by   pyparsing-2.0.3-1.noarch

The first dependency that is required is Python 2.7 , but when I run python --version , I get Python 2.7.6 .

Any idea what the problem is?

    
asked by anonymous 24.03.2016 / 13:44

1 answer

2

And why do you want to install RPM packages on your Ubuntu?

Do not do this - install the native Ubuntu packages from some appropriate repository - if you need a Python library that is not in the Ubuntu repositories, the best thing to do is to create a virtualenv Python, and install the library there with pip install ...

Linux packages like ".deb" and ".rpm" are not just "the program and the necessary files" - they are the "program and files needed" carefully arranged with metadata so that program dependencies can be found, that the files remain in folders consistent with the other folders on your system, and finally, so that the system knows how to manage all the files installed as part of each package in order to manage the package versions correctly.

An "rpm" is a file made for a different Linux distribution from Ubuntu (and even a .deb for other distributions could have the same problems) - and regardless of whether you have tools that can "open and install" rpm, at least problems like the one above - in your case, one of the systems "sees" Python 2.7.6 and another "sees" Python 2.7 (in terms of compatibility and libraries the two are the same).

Now all these packages you mention are well-known and well-used projects in the Python community - and you certainly just have to type apt-get install python-eventlet python-greenlet python-crypto python-pyparsing so that your system automatically looks for these packages and dependencies on the internet. And when some of them are upgraded, your system's automatic updates will still catch on.

Now, remember virtualenv - while you're just experimenting, okay to use operating system packages - if you're starting a software project that uses these libraries, using virtualenv is highly recommended - it lets you fix the versions of Python libraries that work for you, regardless of the versions used by your system, and this is replicable on other Linux machines, regardless of the versions as well.

    
25.03.2016 / 05:07