Skip to content Skip to sidebar Skip to footer

Python Rpm I Built Won't Install

Because I have to install multiple versions of Python on multiple Oracle Linux servers which are built via a kickstart process, I wanted to build a python rpm for our yum repositor

Solution 1:

You should be able to fix this issue by adding the following line to your spec file:

AutoReq:no

Here is my understanding of why this is necessary. When rpmbuild runs across .py files with a #! (shebang) it will automatically add the binary that the shebang specifies as a requirement. Not only that, if the shebang is #!/usr/bin/env python, it will add a dependency for whatever that resolves to (first python on $PATH).

You either need to turn off the automatic requirement processing or find all shebangs that will cause problems and change them to something else.

Solution 2:

rpmbuild can get pretty smart and this is one of those cases. It probably pulled the /usr/local/bin/python from one of your script files containing something like:

#!/usr/local/bin/python

at the top. Try grep'ing for this path in the files within your bz2 file.

Post a Comment for "Python Rpm I Built Won't Install"