Skip to content
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

Undefined symbols for architecture arm64: "_signa_", referenced from: ___fabm_cosine_misc_MOD_pt_in_poly #2

Open
platipodium opened this issue Jun 22, 2022 · 5 comments

Comments

@platipodium
Copy link
Member

When making the python driver, the cosine model is lacking the _signa_ symbol

cmake -S /Users/Lemmen/devel/fabm/fabm-schism/src/drivers/python -B /Users/Lemmen/devel/fabm/fabm-schism/build -DFABM_HOST=python 
make -C /Users/Lemmen/devel/fabm/fabm-schism/build install
...
Scanning dependencies of target fabm_c
[ 93%] Building Fortran object fabm/c/CMakeFiles/fabm_c.dir/c_helper.F90.o
[ 94%] Building Fortran object fabm/c/CMakeFiles/fabm_c.dir/helper.F90.o
[ 95%] Building Fortran object fabm/c/CMakeFiles/fabm_c.dir/fabm_c.F90.o
[ 96%] Building Fortran object fabm/c/CMakeFiles/fabm_c.dir/integrate.F90.o
[ 96%] Building Fortran object fabm/c/CMakeFiles/fabm_c.dir/link_list.F90.o
[ 97%] Building Fortran object fabm/c/CMakeFiles/fabm_c.dir/parameter.F90.o
[ 98%] Building Fortran object fabm/c/CMakeFiles/fabm_c.dir/variable.F90.o
[ 98%] Linking Fortran shared library libfabm_c.dylib
Undefined symbols for architecture arm64:
  "_signa_", referenced from:
      ___fabm_cosine_misc_MOD_pt_in_poly in libfabm.a(fabm_cosine_misc.F90.o)
ld: symbol(s) not found for architecture arm64
collect2: error: ld returned 1 exit status
make[3]: *** [fabm/c/libfabm_c.dylib] Error 1
make[2]: *** [fabm/c/CMakeFiles/fabm_c.dir/all] Error 2
make[1]: *** [all] Error 2
make: *** [pyfabm] Error 2
@platipodium
Copy link
Member Author

The function signa depends on the SCHISM host, so cannot be found when used with a different host like python. @wzhengui we should make this more generic, the grid_cell_area is a property we can pull from the host without this calculation in fabm_misc_cosine.

@wzhengui
Copy link

wzhengui commented Oct 14, 2022 via email

@platipodium
Copy link
Member Author

Your commit fixes #1 Thx! This one here is harder, as we would have to take the misc source apart and also do some work on the host side

@wzhengui
Copy link

Thanks again. I agree with you. I put this on my note. Re-organizing fabm_cosine_misc.F90 is a good idea, as many parts are not needed for fabm.

@platipodium
Copy link
Member Author

See fabm-model#26 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants