Code Monkey home page Code Monkey logo

Comments (7)

hrp1000 avatar hrp1000 commented on June 19, 2024 1

Hi João

The wheel installation seems to work - "import pyKVFinder" and "help(pyKVFinder)" both give sensible replies at the python3 prompt.

Many thanks for this!

from pykvfinder.

hrp1000 avatar hrp1000 commented on June 19, 2024

I think I've found the answer to this - pip install for this package seems to only work with OSX 10.14+ - getting lots of errors with "pip install -vv pyKVFinder" that have lines like these -

Skipping link: none of the wheel's tags (cp37-cp37m-macosx_10_14_x86_64) are compatible (run pi

Skipping link: none of the wheel's tags (cp310-cp310-macosx_10_15_x86_64) are compatible (run p

but lines like these indicate that if I had a Linux dating back 8 years or more pip install might work

Skipping link: none of the wheel's tags (cp39-cp39-manylinux2014_x86_64, cp39-cp39-manylinux_2_

so I guess I'll have to try to build it locally.

from pykvfinder.

jvsguerra avatar jvsguerra commented on June 19, 2024

Hi @hrp1000,

Thank you for reporting your issue.

There is no pyKVFinder distribution compatible with your OS (macOS High Sierra - 10.13) in PYPI. The oldest OS supported is macOS Catalina (10.15). I will carefully consider including macOS High Sierra in pyKVFinder deployment.

For now, please install the developmental version by building it locally.

To do this:

  1. Clone this repository
git clone https://github.com/LBC-LNBio/pyKVFinder
  1. Build pyKVFinder locally
pip install -e pyKVFinder/

Hope it helps you!
If you have more questions, feel free to ask me.

from pykvfinder.

hrp1000 avatar hrp1000 commented on June 19, 2024

Thanks for the rapid repsonse.

Unfortunately, building pyKVFinder locally barfs -

running build_ext
building '_pyKVFinder' extension
swigging C/pyKVFinder.i to C/pyKVFinder_wrap.c
swig -python -o C/pyKVFinder_wrap.c C/pyKVFinder.i
clang -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -fwrapv -O2 -Wall -fPIC -O2 -isystem /Applications/miniconda3/include -fPIC -O2 -isystem /Applications/miniconda3/include -I/Applications/miniconda3/lib/python3.9/site-packages/numpy/core/include -IC -I/Applications/miniconda3/include/python3.9 -c C/pyKVFinder.c -o build/temp.macosx-10.9-x86_64-cpython-39/C/pyKVFinder.o -fopenmp -Ofast -lm
clang: warning: -lm: 'linker' input unused [-Wunused-command-line-argument]
clang: error: unsupported option '-fopenmp'
error: command '/usr/bin/clang' failed with exit code 1

removing the "-fopenmp" from compiler =flags gives other warnings and error.

I'm unfamiliar with swig - how do I change the default compiler from clang to gcc?

My clang looks like -

[MacPro:~/pykvfinder/pyKVFinder] harry% clang --version
Apple LLVM version 10.0.0 (clang-1000.11.45.5)
Target: x86_64-apple-darwin17.7.0
Thread model: posix
InstalledDir: /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin

from pykvfinder.

jvsguerra avatar jvsguerra commented on June 19, 2024

Hi again @hrp1000,

Compiling pyKVFinder uses gcc as the C compiler.
You must change the default compiler from clang to gcc, as you said above.
However, I managed to create a wheel for macOS High Sierra (10.13).

Wheel installation

I am sharing pyKVFinder wheels for different python versions here: wheels.zip

To install using the wheels, follow these steps:

  1. Unzip the wheels.zip.
unzip wheels.zip
  1. Install the pyKVFinder wheel using pip.
    Based on you first comment, you are using python 3.9, so you should run:
pip3 install pyKVFinder-0.4.5-cp39-cp39-macosx_10_13_x86_64.whl

Please let me know if the wheel installation worked.

Build from source

On the other hand, if you still want to build pyKVFinder from source.
First, you need to install:

  • Homebrew package manager;
  • Command Line Tools (CLT) for Xcode (xcode-select --install) or
    Xcode.

To install the available default version of GCC on your Homebrew
package manager, type:

brew install gcc

Note: check the GCC version, using brew info gcc, to make sure you
have installed a version later than 10. Also, Homebrew installation
will not override Clang LLVM compiler link.

If the default version GCC is not later than 10, you can install it directly by typing:

# GCC version 10
$ brew install gcc@10

Then, to set GCC as the default C compiler to build pyKVFinder from source, you would type:

  • Create a symbolic link to your custom GCC
$ sudo ln -s $(brew --prefix)/bin/gcc-X /usr/local/bin/gcc

Note: X is the version of GCC you have installed.

If you have more questions, feel free to ask me.

from pykvfinder.

jvsguerra avatar jvsguerra commented on June 19, 2024

Thanks for reporting this issue, @hrp1000.
If you have any questions, you can open a new issue or reopen this one.

from pykvfinder.

jvsguerra avatar jvsguerra commented on June 19, 2024

Following up on this issue, pyKVFinder builds in PYPI are now compatible with older versions of macOS.

from pykvfinder.

Related Issues (10)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.