Forum Message

 

 

We have moved the forum to https://forum.ngsolve.org . This is an archived version of the topics until 05/05/23. All the topics were moved to the new forum and conversations can be continued there. This forum is just kept as legacy to not invalidate old links. If you want to continue a conversation just look for the topic in the new forum.

Notice

The forum is in read only mode.

Apple Silicon

More
2 years 7 months ago #3915 by alex.v
Replied by alex.v on topic Apple Silicon
I have had time to get back to this. The currently prebuilt .dmg is currently built for python3.8, but I am using python3.9 so instead I am trying to build from source.

I have cloned the ngsolve repo into /Users/alex/Documents/GitHub/ngsolve/ngsolve-source, and then am running the following code, one line at a time.

I get the following error "ld: in '/opt/homebrew/opt/llvm/lib/libunwind.dylib', building for macOS-x86_64 but attempting to link with file built for macOS-arm64" in "/Users/alex/Documents/GitHub/ngsolve/ngsolve-build/netgen/dependencies/src/project_tkdnd-stamp/project_tkdnd-build-err.log".

I have tried it without the "-DUSE_NATIVE_ARCH=ON", same issue.

Any help on what I should do to fix this?
Code:
export NGROOT=/Users/alex/Documents/GitHub/ngsolve mkdir $NGROOT/ngsolve-build cd $NGROOT/ngsolve-build cmake $NGROOT/ngsolve-src -DPYTHON_INCLUDE_DIR=$(python3 -c "from distutils.sysconfig import get_python_inc; print(get_python_inc())") -DPYTHON_LIBRARY=$(python3 -c "import distutils.sysconfig as sysconfig; print(sysconfig.get_config_var('LIBDIR')+'/libpython3.9.dylib')") -DUSE_NATIVE_ARCH=ON make -j 8 make install export PYTHONPATH=$PYTHONPATH:/Applications/Netgen.app/Contents/Resources/lib/python3.9/site-packages:. export NETGENDIR=/Applications/Netgen.app/Contents/MacOS export DYLD_LIBRARY_PATH=$DYLD_LIBRARY_PATH:$NETGENDIR export DYLD_FRAMEWORK_PATH=$DYLD_FRAMEWORK_PATH:$NETGENDIR/../Frameworks export PATH=$NETGENDIR:$PATH
More
2 years 7 months ago - 2 years 7 months ago #3917 by matthiash
Replied by matthiash on topic Apple Silicon
Hi Alex,

could you attach ngsolve-buid/netgen/CMakeCache.txt ?
I suspect that you are mixing compilers here for some reason ("ld: in '/opt/homebrew/opt/llvm/lib/libunwind.dylib', why not using the system toolchain?)

Best,
Matthias
Last edit: 2 years 7 months ago by matthiash.
More
2 years 7 months ago #3918 by alex.v
Replied by alex.v on topic Apple Silicon
Hi Matthias,

I am not sure why it used ld form /opt/homebrew. If I run
Code:
which ld
I get
Code:
/usr/bin/ld

I have attached CMakeCache.txt.

Alex
Attachments:
More
2 years 7 months ago #3953 by alex.v
Replied by alex.v on topic Apple Silicon
Hi Matthias,

Did the CMakeCache.txt provide any info?

Alex
Time to create page: 0.152 seconds