-
Notifications
You must be signed in to change notification settings - Fork 14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CGAL explicitly requested and not found or not functional #193
Comments
Unfortunately, we don't have binaries for Apple silicon yet which means that fastjet has to be compiled by pip locally. |
The error message is more than 1300 lines. Here it is. Error log:
|
Can you try after installing the following?
|
I had all of them installed already. I still did a |
Okay. Can you try the following just in case it works better?
|
That also does not help. I get the same error. |
FWIW I get the same error on my M1 MBP running latest Ventura. There's some messiness with the build environment I can't figure out. I ended up just building in a debian python container and bind-mounting fastjet! |
It looks like it can't find the brew installed gmp. Perhaps something like the following could help
However, we override these in setup.py... |
@chrispap95 I tried the one with I also edited the lines in I still don't see any changes in the log. |
I am afraid I can't do much since I don't have a machine with Apple silicon. Can you try the following? Just to see if it can find gmp. cat >> test.c << "EOF"
#include <gmp.h>
int main(){return 0;}
EOF
gcc -o test test.c -lgmp If the last line fails, then try with gcc -o test test.c -I`brew --prefix gmp`/include -L`brew --prefix gmp`/lib If this fails as well, then I have really no idea how to get this working. |
Yes, the last line failed.
This did not fail. So, maybe we know where the problem is?
|
Okay, very interesting. So these flags seem to work but we need to figure out how to pass them to You could try this by changing to the branch |
Hmm, this does not work. Here are the initial lines of the log I got. log:
|
It seems like this is related. |
If the rest of the printout looks the same as before, then I have no idea what to try next, and without a machine available to experiment I can't go wild with trials to fix this. The solution that Lindsey provided doesn't look that bad. Maybe try that instead? |
Thanks a lot @chrispap95 for the help. Do you have a sample |
You'll have to apt install packages and such to build, you might want to make your own Dockerfile for sanity's sake. Since I was doing a one-off I didn't make one. |
I recently got access to an Apple silicon (M2) machine that I can use for dev work as well. I haven't done local dev work on an Apple computer for about 12 years at this point (👴) so while I know that At the moment I have a name: fastjet-dev
channels:
- conda-forge
dependencies:
- python=3.11
- autoconf
- automake
- cgal-cpp
- gmp
- libtool
- make
- patch
- pybind11
- swig removal of the
...
and a #!/bin/bash
rm -rf CGAL-5.6*
rm -rf build
cd fastjet-core
git reset --hard fastjet-3.4.2
cd ..
python -m pip install --upgrade --verbose . So far I'm failing extremely early
but I'm curious if this is possible at all to do with just conda-forge. |
Using the changes from PR #315, I've found that it is possible to build using conda-forge tooling if the block # change executable names when running on Macs
# if test x`uname` = xDarwin; then
if [ `uname` == "Darwin" ]; then
echo "Detected Mac OSX"
if [ x$(which glibtool) == "x" ]; then
echo ""
echo "On Mac OSX, $0 requires the GNU libtool and libtoolize scripts,"
echo "renamed glibtol and glibtoolize respectively by Apple to avoid"
echo "conflict with Apple-provided libtool."
echo ""
echo "They should be already installed, together with Apple developer tools,"
echo "in /usr/bin. If you see this message, they are not."
echo ""
echo "The GNU version can be retrieved from http://ftp.gnu.org/gnu/libtool/."
echo "If they are (re)installed from sources in a different location,"
echo "autogen.sh should then be modified accordingly."
exit
fi
LIBTOOL=glibtool
LIBTOOLIZE=glibtoolize
fi from the export CXXFLAGS="-I${CONDA_PREFIX}/include"
export LDFLAGS="-L${CONDA_PREFIX}/lib"
unset HOMEBREW_PREFIX
python -m pip install --upgrade --verbose . is used. The overriding of |
This text is wrong. Apple doesn't rename tools to provide "g". They don't / can't provide GNU licensed tools. Homebrew provides g-prefixed utilities to avoid conflicting with Apple's BSD utilities.
I would try glibtool if it exists, then fall back on libtool. Doesn't matter what platform it's on, or if Conda-build / conda-forge is installed. |
(There's a way in homebrew to expose the non-g-prefixed tools, as well) |
@henryiii Yup. c.f. https://gitlab.com/fastjet/fastjet/-/merge_requests/5 where I correct this.
Hm, maybe you can comment on my MR (https://gitlab.com/fastjet/fastjet/-/merge_requests/5) to provide additional context so that the FastJet team will see it too? I don't disagree necessarily, but that's a departure from their defaults. edit: I applied your suggestions to the MR. They were a nice improvement! Though I understand the point of trying for the exceptional case and then fall back to a default, so I'll implement that in the MR tomorrow.
Yeah,
|
Trying to
pip install fastjet
on Mac M2, but getting errors like CGAL not found.Steps taken:
brew install cgal
. This installs CGAL 5.5.2.pip install --upgrade pip wheel
brew install cgal gmp wget
.But so far nothing helped. Any ideas?
The text was updated successfully, but these errors were encountered: