0

I have a clone of python cmake installed on my system cause the package causes some problems.

Now when i install a package (vaex) that has a dependency of python cmake pip reinstalls the cmake from PyPi whic is causing errors.

How can I prevent pip from reinstalling tha package from the source since the clone is already installed ?

This is how the installed package looks import pkg_resources pkg_resources.require('cmake')

Output:
[cmake 0.post2+g292abae (/data/data/com.termux/files/home/.local/lib/python3.10/site-packages)]

Haiz me
  • 1
  • 3
  • `cmake` is not related to Python. How have you installed "a clone of *python cmake*"? Also, what do you mean with `python pkg_resources.require('cmake')`"? That's not a valid Python command line. – AKX Apr 22 '22 at 07:05
  • Sorry, wrong formatting, editing here seems really different https://pypi.org/project/cmake/ – Haiz me Apr 22 '22 at 08:04
  • The `cmake` package on PyPI is a convenience packaging of the `cmake` binary and related files and does not contain any nontrivial Python code. What are you trying to do here? – AKX Apr 22 '22 at 08:09
  • I am trying to install python `vaex`, but it requires python cmake, which i ain't able to install properly thus i created a clone cmake which installs perfectly on my system. But when i install vaex again it installs `cmake` again from PyPi – Haiz me Apr 22 '22 at 08:27
  • Could you maybe show the exact steps you've taken? Which OS and Python version are you running on? – AKX Apr 22 '22 at 08:34
  • I am facing this problem the packages in question is different but problem is same. https://stackoverflow.com/questions/65495860/why-pip-install-dependencies-already-installed – Haiz me Apr 22 '22 at 09:05
  • Please tell us what OS you're running on. That linked answer is just a generic compilation problem that's likely due to missing libraries or such. – AKX Apr 22 '22 at 09:31

1 Answers1

0

Solved this issue,

First created a wheel for the clone cmake ( https://github.com/Haiz14/cmake )i made using pip wheel . -w ~/wheels

Then installed vaex by making pip search for this wheel pip install vaex --find-links ~/wheels

And no cmake problems is cropping up.


Sorry for the lack of logs in question, i am in a rush to complete a deadline and this issue wasted 3 days of mine so i will change the question to a broader topic like prevent cmake from using PyPi packages.

Haiz me
  • 1
  • 3