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

BUG: fortranapex fails with symbol not found in flat namespace #99

Closed
ljlamarche opened this issue Nov 18, 2022 · 11 comments
Closed

BUG: fortranapex fails with symbol not found in flat namespace #99

ljlamarche opened this issue Nov 18, 2022 · 11 comments
Labels

Comments

@ljlamarche
Copy link
Collaborator

Description:
Yet another instillation issue. This specifically applies to building and installing apexpy from the cloned GitHub repository, following the instructions in this section. After installing the necessary prerequisites to build the package (gfortran, build, and pkg-config), it appears to have successfully build and install the package, however apexpy (specifically fortranapex) cannot be imported:

>>> import apexpy
fortranapex module could not be imported. apexpy probably won't work. Failed with error: dlopen(/Users/e30737/Desktop/Software/apexpy/apexpy/fortranapex.cpython-39-darwin.so, 0x0002): symbol not found in flat namespace (_f2pywrapfint_)/Users/e30737/Desktop/Software/apexpy/apexpy/apex.py:15: UserWarning: fortranapex module could not be imported, so apexpy probably won't work.  Make sure you have a gfortran compiler. Failed with error: dlopen(/Users/e30737/Desktop/Software/apexpy/apexpy/fortranapex.cpython-39-darwin.so, 0x0002): symbol not found in flat namespace (_f2pywrapfint_)
  warnings.warn("".join(["fortranapex module could not be imported, so ",

I've tried many variations on the "known" tricks to solve instillation issues, nothing has worked so far.

To Reproduce:
Starting from clean conda environment in cloned apexpy repo (develop branch):

  1. Install gfortran, build, and pkg-config
% conda install -c conda-forge gfortran build pkg-config
  1. Build apexpy
% python -m build .
  1. Install apexpy
% pip install -e .
  1. Start a python session and attempt to import apexpy
(apexpy) e30737@arm64-apple-darwin20 apexpy % python
Python 3.9.13 | packaged by conda-forge | (main, May 27 2022, 17:01:00) 
[Clang 13.0.1 ] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import apexpy
fortranapex module could not be imported. apexpy probably won't work. Failed with error: dlopen(/Users/e30737/Desktop/Software/apexpy/apexpy/fortranapex.cpython-39-darwin.so, 0x0002): symbol not found in flat namespace (_f2pywrapfint_)/Users/e30737/Desktop/Software/apexpy/apexpy/apex.py:15: UserWarning: fortranapex module could not be imported, so apexpy probably won't work.  Make sure you have a gfortran compiler. Failed with error: dlopen(/Users/e30737/Desktop/Software/apexpy/apexpy/fortranapex.cpython-39-darwin.so, 0x0002): symbol not found in flat namespace (_f2pywrapfint_)
  warnings.warn("".join(["fortranapex module could not be imported, so ",

Speculation:
The problem appears to be relates to _f2pywrapfint_ in fortranapex.cpython-39-darwin.so, which is added to the apexpy directory upon pip install. Inspecting fortranapex.cpython-39-darwin.so reveals that _f2pywrapfint_ is listed as undefined.

% nm -g apexpy/fortranapex.cpython-39-darwin.so 

Pertinent block:

 000000000001bb90 T _f2pyinitapxshmodule_
                 U _f2pyinitdipole_
                 U _f2pyinitfldcomd_
                 U _f2pyinititra_
                 U _f2pyinitmagcof_
                 U _f2pywrapfint_

Full output of this command is given at the end of this description.

I've found a few other mentions of similar issues, but it's not clear that there is a definite solution (or even that they are necessarily the same problem. I think the most relevant is a quote from this comment:
"Somehow, the constant variables in the class are compiled as indirect symbols that cannot be found in flat namespace on macOS using AppleClang++."

Other potentially useful threads:
tensorflow/tensorflow#54242
tensorflow/tensorflow#41682
tensorflow/tensorflow#39262
tensorflow/tensorflow#36945

Potentially noteable is the fact that fint is the ONLY portion of fortran source code that is written as a function rather than a module. I never could figure out why this was, but it may be impacting something? I think it's far more liekly that this is a quirk with my setup.

Computer Information:

  • OS: MacOS arm64
  • Python version 3.9
  • conda 22.9.0
  • xcode version14.1
  • GNU Fortran (GCC) 11.3.0
  • clang version 14.0.6
  • Apexpy version 1.1.0; develop branch
@ljlamarche ljlamarche added the bug label Nov 18, 2022
@ljlamarche
Copy link
Collaborator Author

ljlamarche commented Nov 18, 2022

Full Output of Build
    (apexpy) e30737@arm64-apple-darwin20 apexpy % python -m build .
    * Creating venv isolated environment...
    * Installing packages in isolated environment... (Cython>=0.29.21, meson-python>=0.8.0, numpy, python-dev-tools, setuptools<60.0, wheel)
    * Getting dependencies for sdist...
    * Building sdist...
    + meson setup --native-file=/Users/e30737/Desktop/Software/apexpy/.mesonpy-native-file.ini -Ddebug=false -Doptimization=2 --prefix=/Users/e30737/miniconda3/envs/apexpy /Users/e30737/Desktop/Software/apexpy /Users/e30737/Desktop/Software/apexpy/.mesonpy-e1na6nvx/build
    The Meson build system
    Version: 0.64.0
    Source dir: /Users/e30737/Desktop/Software/apexpy
    Build dir: /Users/e30737/Desktop/Software/apexpy/.mesonpy-e1na6nvx/build
    Build type: native build
    Project name: apexpy
    Project version: 1.1.0
    C compiler for the host machine: arm64-apple-darwin20.0.0-clang (clang 14.0.6 "clang version 14.0.6")
    C linker for the host machine: arm64-apple-darwin20.0.0-clang ld64 609
    Host machine cpu family: aarch64
    Host machine cpu: aarch64
    Fortran compiler for the host machine: /Users/e30737/miniconda3/envs/apexpy/bin/arm64-apple-darwin20.0.0-gfortran (gcc 11.3.0 "GNU Fortran (GCC) 11.3.0")
    Fortran linker for the host machine: /Users/e30737/miniconda3/envs/apexpy/bin/arm64-apple-darwin20.0.0-gfortran ld64 609
    Compiler for C supports arguments -Wno-unused-but-set-variable: YES 
    Library m found: YES
    Program python found: YES (/var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-env-pynni4bs/bin/python)
    Found pkg-config: /Users/e30737/miniconda3/envs/apexpy/bin/pkg-config (0.29.2)
    Message: /var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-env-pynni4bs/bin/python
    Message: /Users/e30737/miniconda3/envs/apexpy/lib/python3.9/site-packages/
    Check usable header "Python.h" with dependency python: YES 
    Build targets in project: 3
    
    apexpy 1.1.0
    
      User defined options
        Native files: /Users/e30737/Desktop/Software/apexpy/.mesonpy-native-file.ini
        debug       : false
        optimization: 2
        prefix      : /Users/e30737/miniconda3/envs/apexpy
    
    Found ninja-1.11.1.git.kitware.jobserver-1 at /var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-env-pynni4bs/bin/ninja
    + meson dist --allow-dirty --no-tests --formats gztar
    WARNING: Repository has uncommitted changes that will not be included in the dist tarball
    Created /Users/e30737/Desktop/Software/apexpy/.mesonpy-e1na6nvx/build/meson-dist/apexpy-1.1.0.tar.gz
    * Building wheel from sdist
    * Creating venv isolated environment...
    * Installing packages in isolated environment... (Cython>=0.29.21, meson-python>=0.8.0, numpy, python-dev-tools, setuptools<60.0, wheel)
    * Getting dependencies for wheel...
    + meson setup --native-file=/private/var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-via-sdist-fxyepf27/apexpy-1.1.0/.mesonpy-native-file.ini -Ddebug=false -Doptimization=2 --prefix=/Users/e30737/miniconda3/envs/apexpy /private/var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-via-sdist-fxyepf27/apexpy-1.1.0 /private/var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-via-sdist-fxyepf27/apexpy-1.1.0/.mesonpy-jy4fraxo/build
    The Meson build system
    Version: 0.64.0
    Source dir: /private/var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-via-sdist-fxyepf27/apexpy-1.1.0
    Build dir: /private/var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-via-sdist-fxyepf27/apexpy-1.1.0/.mesonpy-jy4fraxo/build
    Build type: native build
    Project name: apexpy
    Project version: 1.1.0
    C compiler for the host machine: arm64-apple-darwin20.0.0-clang (clang 14.0.6 "clang version 14.0.6")
    C linker for the host machine: arm64-apple-darwin20.0.0-clang ld64 609
    Host machine cpu family: aarch64
    Host machine cpu: aarch64
    Fortran compiler for the host machine: /Users/e30737/miniconda3/envs/apexpy/bin/arm64-apple-darwin20.0.0-gfortran (gcc 11.3.0 "GNU Fortran (GCC) 11.3.0")
    Fortran linker for the host machine: /Users/e30737/miniconda3/envs/apexpy/bin/arm64-apple-darwin20.0.0-gfortran ld64 609
    Compiler for C supports arguments -Wno-unused-but-set-variable: YES 
    Library m found: YES
    Program python found: YES (/var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-env-bfsvee8e/bin/python)
    Found pkg-config: /Users/e30737/miniconda3/envs/apexpy/bin/pkg-config (0.29.2)
    Message: /var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-env-bfsvee8e/bin/python
    Message: /Users/e30737/miniconda3/envs/apexpy/lib/python3.9/site-packages/
    Check usable header "Python.h" with dependency python: YES 
    Build targets in project: 3
    
    apexpy 1.1.0
    
      User defined options
        Native files: /private/var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-via-sdist-fxyepf27/apexpy-1.1.0/.mesonpy-native-file.ini
        debug       : false
        optimization: 2
        prefix      : /Users/e30737/miniconda3/envs/apexpy
    
    Found ninja-1.11.1.git.kitware.jobserver-1 at /var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-env-bfsvee8e/bin/ninja
    * Installing packages in isolated environment... (wheel >= 0.36.0)
    * Building wheel...
    + meson setup --native-file=/private/var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-via-sdist-fxyepf27/apexpy-1.1.0/.mesonpy-native-file.ini -Ddebug=false -Doptimization=2 --prefix=/Users/e30737/miniconda3/envs/apexpy /private/var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-via-sdist-fxyepf27/apexpy-1.1.0 /private/var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-via-sdist-fxyepf27/apexpy-1.1.0/.mesonpy-tls7g69g/build
    The Meson build system
    Version: 0.64.0
    Source dir: /private/var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-via-sdist-fxyepf27/apexpy-1.1.0
    Build dir: /private/var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-via-sdist-fxyepf27/apexpy-1.1.0/.mesonpy-tls7g69g/build
    Build type: native build
    Project name: apexpy
    Project version: 1.1.0
    C compiler for the host machine: arm64-apple-darwin20.0.0-clang (clang 14.0.6 "clang version 14.0.6")
    C linker for the host machine: arm64-apple-darwin20.0.0-clang ld64 609
    Host machine cpu family: aarch64
    Host machine cpu: aarch64
    Fortran compiler for the host machine: /Users/e30737/miniconda3/envs/apexpy/bin/arm64-apple-darwin20.0.0-gfortran (gcc 11.3.0 "GNU Fortran (GCC) 11.3.0")
    Fortran linker for the host machine: /Users/e30737/miniconda3/envs/apexpy/bin/arm64-apple-darwin20.0.0-gfortran ld64 609
    Compiler for C supports arguments -Wno-unused-but-set-variable: YES 
    Library m found: YES
    Program python found: YES (/var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-env-bfsvee8e/bin/python)
    Found pkg-config: /Users/e30737/miniconda3/envs/apexpy/bin/pkg-config (0.29.2)
    Message: /var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-env-bfsvee8e/bin/python
    Message: /Users/e30737/miniconda3/envs/apexpy/lib/python3.9/site-packages/
    Check usable header "Python.h" with dependency python: YES 
    Build targets in project: 3
    
    apexpy 1.1.0
    
      User defined options
        Native files: /private/var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-via-sdist-fxyepf27/apexpy-1.1.0/.mesonpy-native-file.ini
        debug       : false
        optimization: 2
        prefix      : /Users/e30737/miniconda3/envs/apexpy
    
    Found ninja-1.11.1.git.kitware.jobserver-1 at /var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-env-bfsvee8e/bin/ninja
    + meson compile
    INFO: autodetecting backend as ninja
    INFO: calculating backend command to run: /var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-env-bfsvee8e/bin/ninja
    [4/14] Generating fortranapexmodule.c with a custom command
    Reading fortran codes...
	    Reading file '../../fortranapex/magfld.f90' (format:free)
	    Reading file '../../fortranapex/apex.f90' (format:free)
	    Reading file '../../fortranapex/makeapexsh.f90' (format:free)
	    Reading file '../../fortranapex/igrf.f90' (format:free)
	    Reading file '../../fortranapex/apexsh.f90' (format:free)
	    Reading file '../../fortranapex/checkapexsh.f90' (format:free)
    Post-processing...
	    Block: fortranapex
			    Block: magcof
			    Block: coeffmodule
    In: :fortranapex:../../fortranapex/magfld.f90:coeffmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:coeffmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:coeffmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:coeffmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:coeffmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:coeffmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:coeffmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:coeffmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:coeffmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:coeffmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:coeffmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
			    Block: cofrm
    In: :fortranapex:../../fortranapex/magfld.f90:cofrm
    get_useparameters: no module igrf info used by cofrm
			    Block: dypol
    In: :fortranapex:../../fortranapex/magfld.f90:dypol
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:dypol
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:dypol
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:dypol
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:dypol
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:dypol
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:dypol
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:dypol
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:dypol
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:dypol
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:dypol
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
			    Block: feldg
    In: :fortranapex:../../fortranapex/magfld.f90:feldg
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:feldg
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:feldg
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:feldg
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:feldg
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:feldg
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:feldg
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:feldg
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:feldg
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:feldg
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:feldg
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
			    Block: gd2cart
    In: :fortranapex:../../fortranapex/magfld.f90:gd2cart
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:gd2cart
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:gd2cart
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:gd2cart
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:gd2cart
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:gd2cart
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:gd2cart
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:gd2cart
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:gd2cart
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:gd2cart
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:gd2cart
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
			    Block: convrt
    In: :fortranapex:../../fortranapex/magfld.f90:convrt
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:convrt
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:convrt
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:convrt
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:convrt
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:convrt
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:convrt
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:convrt
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:convrt
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:convrt
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:convrt
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:convrt
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:convrt
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:convrt
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:convrt
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:convrt
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:convrt
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:convrt
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:convrt
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:convrt
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:convrt
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:convrt
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:convrt
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:convrt
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:convrt
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/magfld.f90:convrt
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
			    Block: apexmodule
    In: :fortranapex:../../fortranapex/apex.f90:apexmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/apex.f90:apexmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/apex.f90:apexmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/apex.f90:apexmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/apex.f90:apexmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/apex.f90:apexmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/apex.f90:apexmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/apex.f90:apexmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/apex.f90:apexmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/apex.f90:apexmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/apex.f90:apexmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
				    Block: fint
    In: :fortranapex:../../fortranapex/apex.f90:apexmodule:fint
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/apex.f90:apexmodule:fint
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/apex.f90:apexmodule:fint
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/apex.f90:apexmodule:fint
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/apex.f90:apexmodule:fint
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/apex.f90:apexmodule:fint
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/apex.f90:apexmodule:fint
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/apex.f90:apexmodule:fint
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/apex.f90:apexmodule:fint
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/apex.f90:apexmodule:fint
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/apex.f90:apexmodule:fint
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
			    Block: dipole
			    Block: fldcomd
			    Block: apxin
			    Block: itra
			    Block: apex
			    Block: linapx
			    Block: itrace
			    Block: fndapx
			    Block: dipapx
			    Block: makeapxsh
    In: :fortranapex:../../fortranapex/makeapexsh.f90:makeapxsh
    get_useparameters: no module apxshmodule info used by makeapxsh
			    Block: choldc
			    Block: cholsl
			    Block: igrf
				    Block: read_igrf
			    Block: apxshmodule
    In: :fortranapex:../../fortranapex/apexsh.f90:apxshmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/apexsh.f90:apxshmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/apexsh.f90:apxshmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/apexsh.f90:apxshmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/apexsh.f90:apxshmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/apexsh.f90:apxshmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/apexsh.f90:apxshmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/apexsh.f90:apxshmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/apexsh.f90:apxshmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/apexsh.f90:apxshmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    In: :fortranapex:../../fortranapex/apexsh.f90:apxshmodule
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
			    Block: loadapxsh
			    Block: allocatearrays
			    Block: apxg2q
			    Block: apxg2all
			    Block: apxq2g
			    Block: shcalc
			    Block: alfbasismodule
			    Block: alfbasisinit
			    Block: alfbasis
    In: :fortranapex:../../fortranapex/apexsh.f90:alfbasis
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
			    Block: checkapexsh
    In: :fortranapex:../../fortranapex/checkapexsh.f90:checkapexsh
    get_parameters: got "eval() arg 1 must be a string, bytes or code object" on 4
    Post-processing (stage 2)...
	    Block: fortranapex
		    Block: unknown_interface
			    Block: magcof
			    Block: coeffmodule
			    Block: cofrm
			    Block: dypol
			    Block: feldg
			    Block: gd2cart
			    Block: convrt
			    Block: apexmodule
				    Block: fint
			    Block: dipole
			    Block: fldcomd
			    Block: apxin
			    Block: itra
			    Block: apex
			    Block: linapx
			    Block: itrace
			    Block: fndapx
			    Block: dipapx
			    Block: makeapxsh
			    Block: choldc
			    Block: cholsl
			    Block: igrf
				    Block: read_igrf
			    Block: apxshmodule
			    Block: loadapxsh
			    Block: allocatearrays
			    Block: apxg2q
			    Block: apxg2all
			    Block: apxq2g
			    Block: shcalc
			    Block: alfbasismodule
			    Block: alfbasisinit
			    Block: alfbasis
			    Block: checkapexsh
    Building modules...
        Building module "fortranapex"...
        Generating possibly empty wrappers"
        Maybe empty "fortranapex-f2pywrappers.f"
            Constructing wrapper function "cofrm"...
              cofrm(date,filename)
        Generating possibly empty wrappers"
        Maybe empty "fortranapex-f2pywrappers.f"
            Constructing wrapper function "dypol"...
              colat,elon,vp = dypol()
        Generating possibly empty wrappers"
        Maybe empty "fortranapex-f2pywrappers.f"
            Constructing wrapper function "feldg"...
              bnrth,beast,bdown,babs = feldg(ienty,glat,glon,alt)
        Generating possibly empty wrappers"
        Maybe empty "fortranapex-f2pywrappers.f"
            Constructing wrapper function "gd2cart"...
              x,y,z = gd2cart(gdlat,glon,alt)
        Generating possibly empty wrappers"
        Maybe empty "fortranapex-f2pywrappers.f"
            Constructing wrapper function "convrt"...
              convrt(i,gdlat,alt,x1,x2)
        Generating possibly empty wrappers"
        Maybe empty "fortranapex-f2pywrappers.f"
            Constructing wrapper function "apex"...
              a,alat,alon,bmag,xmag,ymag,zmag,v = apex(date,igrffilein,dlat,dlon,alt)
        Generating possibly empty wrappers"
        Maybe empty "fortranapex-f2pywrappers.f"
            Constructing wrapper function "linapx"...
              a,alat,alon,xmag,ymag,zmag,f = linapx(gdlat,glon,alt)
        Generating possibly empty wrappers"
        Maybe empty "fortranapex-f2pywrappers.f"
            Constructing wrapper function "itrace"...
              iapx = itrace()
        Generating possibly empty wrappers"
        Maybe empty "fortranapex-f2pywrappers.f"
            Constructing wrapper function "fndapx"...
              a,alat,alon = fndapx(alt,zmag)
        Generating possibly empty wrappers"
        Maybe empty "fortranapex-f2pywrappers.f"
            Constructing wrapper function "dipapx"...
              a,alon = dipapx(gdlat,gdlon,alt,bnorth,beast,bdown)
        Generating possibly empty wrappers"
        Maybe empty "fortranapex-f2pywrappers.f"
            Constructing wrapper function "makeapxsh"...
              makeapxsh(datafilein,igrffilein,epochgridin,nepochin,lmaxin,mmaxin,nmaxin)
        Generating possibly empty wrappers"
        Maybe empty "fortranapex-f2pywrappers.f"
            Constructing wrapper function "choldc"...
              p = choldc(a,n,[np])
        Generating possibly empty wrappers"
        Maybe empty "fortranapex-f2pywrappers.f"
            Constructing wrapper function "cholsl"...
              x = cholsl(a,p,b,[n,np])
        Generating possibly empty wrappers"
        Maybe empty "fortranapex-f2pywrappers.f"
            Constructing wrapper function "loadapxsh"...
              loadapxsh(datafilenew,epochnew)
        Generating possibly empty wrappers"
        Maybe empty "fortranapex-f2pywrappers.f"
            Constructing wrapper function "allocatearrays"...
              allocatearrays()
        Generating possibly empty wrappers"
        Maybe empty "fortranapex-f2pywrappers.f"
            Constructing wrapper function "apxg2q"...
              qlatout,qlonout,f1,f2,f = apxg2q(glat,glon,alt,vecflagin)
        Generating possibly empty wrappers"
        Maybe empty "fortranapex-f2pywrappers.f"
            Constructing wrapper function "apxg2all"...
              qlatout,qlonout,mlat,mlon,f1,f2,f,d1,d2,d3,d,e1,e2,e3 = apxg2all(glat,glon,alt,hr,vecflagin)
        Generating possibly empty wrappers"
        Maybe empty "fortranapex-f2pywrappers.f"
            Constructing wrapper function "apxq2g"...
              glatout,glonout,error = apxq2g(qlat0,qlon0,alt,prec)
        Generating possibly empty wrappers"
        Maybe empty "fortranapex-f2pywrappers.f"
            Constructing wrapper function "shcalc"...
              shcalc(theta,phi)
        Generating possibly empty wrappers"
        Maybe empty "fortranapex-f2pywrappers.f"
            Constructing wrapper function "alfbasisinit"...
              alfbasisinit(nmax0in,mmax0in)
        Generating possibly empty wrappers"
        Maybe empty "fortranapex-f2pywrappers.f"
            Constructing wrapper function "alfbasis"...
              p,v,w = alfbasis(nmax,mmax,theta)
		    Constructing F90 module support for "magcof"...
		      Variables: nmax1 ichg gb gv
		    Constructing F90 module support for "coeffmodule"...
		      Variables: pi dtor rtod pid2 twopi req rep eps re ecc2 missing
		    Constructing F90 module support for "apexmodule"...
		    Creating wrapper for Fortran function "fint"("fint")...
                Constructing wrapper function "apexmodule.fint"...
                  fint = fint(x1,x2,x3,y1,y2,y3,xfit)
		    Constructing F90 module support for "dipole"...
		      Variables: colat elon vp ctp stp
		    Constructing F90 module support for "fldcomd"...
		      Variables: bx by bz bb
		    Constructing F90 module support for "apxin"...
		      Variables: yapx
		    Constructing F90 module support for "itra"...
		      Variables: nstp sgn ds y yold yp
		    Constructing F90 module support for "igrf"...
		      Variables: datel nepo nght epoch nmxe gyr hyr gt ht
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
                Constructing wrapper function "igrf.read_igrf"...
                  read_igrf(filename_in)
		    Constructing F90 module support for "apxshmodule"...
		      Variables: nterm nmax mmax lmax nepoch ntermsh vecflag coeff0 qcoeff0 gcoeff0 xqcoeff yqcoeff zqcoeff dxqdrhocoeff dyqdrhocoeff dzqdrhocoeff xgcoeff ygcoeff zgcoeff sh shgradtheta shgradphi polynomq dpolynomq polynomg pbar vbar wbar epochgrid h reph rho xq yq zq qlat qlon sinqlat cosqlat cosqlon sinqlon xqgrad yqgrad zqgrad qlatgrad qlongrad datafile epoch altlastq altlastg loadflag
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
		    Constructing F90 module support for "alfbasismodule"...
		      Variables: nmax0 mmax0 anm cm bnm dnm en marr narr
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
    getarrdims:warning: assumed shape array, using 0 instead of ':'
        Wrote C/API module "fortranapex" to file "./fortranapexmodule.c"
        Fortran 90 wrappers are saved to "./fortranapex-f2pywrappers2.f90"
    [13/14] Compiling Fortran object fortranapex.cpython...p/meson-generated_.._fortranapex-f2pywrappers2.f90.o
    fortranapex-f2pywrappers2.f90:33:41:
    
       33 |       subroutine f2pywrap_apexmodule_fint (fintf2pywrap, x1, x2, x3, y1,&
          |                                         1
    ......
       49 |       subroutine f2pywrap_apexmodule_fint (fintf2pywrap, fint, x1, x2, x&
          |                                         2
    Warning: 'f2pywrap_apexmodule_fint' has the wrong number of arguments between (1) and (2)
    fortranapex-f2pywrappers2.f90:288:10:
    
      288 |       use igrf, only : datel
          |          1
    Warning: Unused module variable ‘epoch’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:288:10:
    
      288 |       use igrf, only : datel
          |          1
    Warning: Unused module variable ‘gt’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:288:10:
    
      288 |       use igrf, only : datel
          |          1
    Warning: Unused module variable ‘gyr’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:288:10:
    
      288 |       use igrf, only : datel
          |          1
    Warning: Unused module variable ‘ht’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:288:10:
    
      288 |       use igrf, only : datel
          |          1
    Warning: Unused module variable ‘hyr’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:288:10:
    
      288 |       use igrf, only : datel
          |          1
    Warning: Unused module variable ‘nmxe’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:979:10:
    
      979 |       use apxshmodule, only : nterm
          |          1
    Warning: Unused module variable ‘coeff0’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:979:10:
    
      979 |       use apxshmodule, only : nterm
          |          1
    Warning: Unused module variable ‘dpolynomq’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:979:10:
    
      979 |       use apxshmodule, only : nterm
          |          1
    Warning: Unused module variable ‘dxqdrhocoeff’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:979:10:
    
      979 |       use apxshmodule, only : nterm
          |          1
    Warning: Unused module variable ‘dyqdrhocoeff’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:979:10:
    
      979 |       use apxshmodule, only : nterm
          |          1
    Warning: Unused module variable ‘dzqdrhocoeff’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:979:10:
    
      979 |       use apxshmodule, only : nterm
          |          1
    Warning: Unused module variable ‘epochgrid’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:979:10:
    
      979 |       use apxshmodule, only : nterm
          |          1
    Warning: Unused module variable ‘gcoeff0’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:979:10:
    
      979 |       use apxshmodule, only : nterm
          |          1
    Warning: Unused module variable ‘pbar’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:979:10:
    
      979 |       use apxshmodule, only : nterm
          |          1
    Warning: Unused module variable ‘polynomg’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:979:10:
    
      979 |       use apxshmodule, only : nterm
          |          1
    Warning: Unused module variable ‘polynomq’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:979:10:
    
      979 |       use apxshmodule, only : nterm
          |          1
    Warning: Unused module variable ‘qcoeff0’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:979:10:
    
      979 |       use apxshmodule, only : nterm
          |          1
    Warning: Unused module variable ‘sh’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:979:10:
    
      979 |       use apxshmodule, only : nterm
          |          1
    Warning: Unused module variable ‘shgradphi’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:979:10:
    
      979 |       use apxshmodule, only : nterm
          |          1
    Warning: Unused module variable ‘shgradtheta’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:979:10:
    
      979 |       use apxshmodule, only : nterm
          |          1
    Warning: Unused module variable ‘vbar’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:979:10:
    
      979 |       use apxshmodule, only : nterm
          |          1
    Warning: Unused module variable ‘wbar’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:979:10:
    
      979 |       use apxshmodule, only : nterm
          |          1
    Warning: Unused module variable ‘xgcoeff’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:979:10:
    
      979 |       use apxshmodule, only : nterm
          |          1
    Warning: Unused module variable ‘xqcoeff’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:979:10:
    
      979 |       use apxshmodule, only : nterm
          |          1
    Warning: Unused module variable ‘ygcoeff’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:979:10:
    
      979 |       use apxshmodule, only : nterm
          |          1
    Warning: Unused module variable ‘yqcoeff’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:979:10:
    
      979 |       use apxshmodule, only : nterm
          |          1
    Warning: Unused module variable ‘zgcoeff’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:979:10:
    
      979 |       use apxshmodule, only : nterm
          |          1
    Warning: Unused module variable ‘zqcoeff’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:1282:10:
    
     1282 |       use alfbasismodule, only : nmax0
          |          1
    Warning: Unused module variable ‘anm’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:1282:10:
    
     1282 |       use alfbasismodule, only : nmax0
          |          1
    Warning: Unused module variable ‘bnm’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:1282:10:
    
     1282 |       use alfbasismodule, only : nmax0
          |          1
    Warning: Unused module variable ‘cm’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:1282:10:
    
     1282 |       use alfbasismodule, only : nmax0
          |          1
    Warning: Unused module variable ‘dnm’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:1282:10:
    
     1282 |       use alfbasismodule, only : nmax0
          |          1
    Warning: Unused module variable ‘en’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:1282:10:
    
     1282 |       use alfbasismodule, only : nmax0
          |          1
    Warning: Unused module variable ‘marr’ which has been explicitly imported at (1) [-Wunused-variable]
    fortranapex-f2pywrappers2.f90:1282:10:
    
     1282 |       use alfbasismodule, only : nmax0
          |          1
    Warning: Unused module variable ‘narr’ which has been explicitly imported at (1) [-Wunused-variable]
    [14/14] Linking target fortranapex.cpython-39-darwin.so
    ld: warning: -pie being ignored. It is only used when linking a main executable
    ld: warning: could not create compact unwind for _f2py_igrf_getdims_epoch_: register 28 saved somewhere other than in frame
    ld: warning: could not create compact unwind for _f2py_igrf_getdims_nmxe_: register 28 saved somewhere other than in frame
    ld: warning: could not create compact unwind for _f2py_igrf_getdims_gyr_: registers 27 and 28 not saved contiguously in frame
    ld: warning: could not create compact unwind for _f2py_igrf_getdims_hyr_: registers 27 and 28 not saved contiguously in frame
    ld: warning: could not create compact unwind for _f2py_igrf_getdims_gt_: registers 27 and 28 not saved contiguously in frame
    ld: warning: could not create compact unwind for _f2py_igrf_getdims_ht_: registers 27 and 28 not saved contiguously in frame
    ld: warning: could not create compact unwind for _f2py_apxshmodule_getdims_coeff0_: registers 27 and 28 not saved contiguously in frame
    ld: warning: could not create compact unwind for _f2py_apxshmodule_getdims_qcoeff0_: registers 27 and 28 not saved contiguously in frame
    ld: warning: could not create compact unwind for _f2py_apxshmodule_getdims_gcoeff0_: registers 27 and 28 not saved contiguously in frame
    ld: warning: could not create compact unwind for _f2py_apxshmodule_getdims_xqcoeff_: register 28 saved somewhere other than in frame
    ld: warning: could not create compact unwind for _f2py_apxshmodule_getdims_yqcoeff_: register 28 saved somewhere other than in frame
    ld: warning: could not create compact unwind for _f2py_apxshmodule_getdims_zqcoeff_: register 28 saved somewhere other than in frame
    ld: warning: could not create compact unwind for _f2py_apxshmodule_getdims_dxqdrhocoeff_: register 28 saved somewhere other than in frame
    ld: warning: could not create compact unwind for _f2py_apxshmodule_getdims_dyqdrhocoeff_: register 28 saved somewhere other than in frame
    ld: warning: could not create compact unwind for _f2py_apxshmodule_getdims_dzqdrhocoeff_: register 28 saved somewhere other than in frame
    ld: warning: could not create compact unwind for _f2py_apxshmodule_getdims_xgcoeff_: register 28 saved somewhere other than in frame
    ld: warning: could not create compact unwind for _f2py_apxshmodule_getdims_ygcoeff_: register 28 saved somewhere other than in frame
    ld: warning: could not create compact unwind for _f2py_apxshmodule_getdims_zgcoeff_: register 28 saved somewhere other than in frame
    ld: warning: could not create compact unwind for _f2py_apxshmodule_getdims_sh_: register 28 saved somewhere other than in frame
    ld: warning: could not create compact unwind for _f2py_apxshmodule_getdims_shgradtheta_: register 28 saved somewhere other than in frame
    ld: warning: could not create compact unwind for _f2py_apxshmodule_getdims_shgradphi_: register 28 saved somewhere other than in frame
    ld: warning: could not create compact unwind for _f2py_apxshmodule_getdims_polynomq_: register 28 saved somewhere other than in frame
    ld: warning: could not create compact unwind for _f2py_apxshmodule_getdims_dpolynomq_: register 28 saved somewhere other than in frame
    ld: warning: could not create compact unwind for _f2py_apxshmodule_getdims_polynomg_: register 28 saved somewhere other than in frame
    ld: warning: could not create compact unwind for _f2py_apxshmodule_getdims_pbar_: registers 27 and 28 not saved contiguously in frame
    ld: warning: could not create compact unwind for _f2py_apxshmodule_getdims_vbar_: registers 27 and 28 not saved contiguously in frame
    ld: warning: could not create compact unwind for _f2py_apxshmodule_getdims_wbar_: registers 27 and 28 not saved contiguously in frame
    ld: warning: could not create compact unwind for _f2py_apxshmodule_getdims_epochgrid_: register 28 saved somewhere other than in frame
    ld: warning: could not create compact unwind for _f2py_alfbasismodule_getdims_anm_: registers 27 and 28 not saved contiguously in frame
    ld: warning: could not create compact unwind for _f2py_alfbasismodule_getdims_cm_: register 28 saved somewhere other than in frame
    ld: warning: could not create compact unwind for _f2py_alfbasismodule_getdims_bnm_: registers 27 and 28 not saved contiguously in frame
    ld: warning: could not create compact unwind for _f2py_alfbasismodule_getdims_dnm_: registers 27 and 28 not saved contiguously in frame
    ld: warning: could not create compact unwind for _f2py_alfbasismodule_getdims_en_: register 28 saved somewhere other than in frame
    ld: warning: could not create compact unwind for _f2py_alfbasismodule_getdims_marr_: register 28 saved somewhere other than in frame
    ld: warning: could not create compact unwind for _f2py_alfbasismodule_getdims_narr_: register 28 saved somewhere other than in frame
    ld: warning: could not create compact unwind for _cofrm_: registers 72 and 73 not saved contiguously in frame
    ld: warning: could not create compact unwind for _feldg_: registers 78 and 79 not saved contiguously in frame
    ld: warning: could not create compact unwind for _fndapx_: registers 74 and 75 not saved contiguously in frame
    ld: warning: could not create compact unwind for _makeapxsh_: registers 78 and 79 not saved contiguously in frame
    ld: warning: could not create compact unwind for ___igrf_MOD_read_igrf: registers 27 and 28 not saved contiguously in frame
    ld: warning: could not create compact unwind for _alfbasis_: register 73 saved somewhere other than in frame
    ld: warning: could not create compact unwind for _shcalc_: registers 27 and 28 not saved contiguously in frame
    ld: warning: could not create compact unwind for _apxg2q_: registers 78 and 79 not saved contiguously in frame
    ld: warning: could not create compact unwind for _alfbasisinit_: registers 27 and 28 not saved contiguously in frame
    ld: warning: could not create compact unwind for _allocatearrays_: registers 27 and 28 not saved contiguously in frame
    ld: warning: could not create compact unwind for _loadapxsh_: register 73 saved somewhere other than in frame
    ld: warning: could not create compact unwind for _apxg2all_: register 75 saved somewhere other than in frame
    ld: warning: could not create compact unwind for _apxq2g_: registers 78 and 79 not saved contiguously in frame
    + meson install --destdir /private/var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-via-sdist-fxyepf27/apexpy-1.1.0/.mesonpy-tls7g69g/install
    ninja: Entering directory `/private/var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-via-sdist-fxyepf27/apexpy-1.1.0/.mesonpy-tls7g69g/build'
    ninja: no work to do.
    Installing fortranapex.cpython-39-darwin.so to /private/var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-via-sdist-fxyepf27/apexpy-1.1.0/.mesonpy-tls7g69g/install/Users/e30737/miniconda3/envs/apexpy/lib/python3.9/site-packages/apexpy
    Installing /private/var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-via-sdist-fxyepf27/apexpy-1.1.0/apexpy/__init__.py to /private/var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-via-sdist-fxyepf27/apexpy-1.1.0/.mesonpy-tls7g69g/install/Users/e30737/miniconda3/envs/apexpy/lib/python3.9/site-packages/apexpy
    Installing /private/var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-via-sdist-fxyepf27/apexpy-1.1.0/apexpy/__main__.py to /private/var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-via-sdist-fxyepf27/apexpy-1.1.0/.mesonpy-tls7g69g/install/Users/e30737/miniconda3/envs/apexpy/lib/python3.9/site-packages/apexpy
    Installing /private/var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-via-sdist-fxyepf27/apexpy-1.1.0/apexpy/apex.py to /private/var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-via-sdist-fxyepf27/apexpy-1.1.0/.mesonpy-tls7g69g/install/Users/e30737/miniconda3/envs/apexpy/lib/python3.9/site-packages/apexpy
    Installing /private/var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-via-sdist-fxyepf27/apexpy-1.1.0/apexpy/apexsh.dat to /private/var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-via-sdist-fxyepf27/apexpy-1.1.0/.mesonpy-tls7g69g/install/Users/e30737/miniconda3/envs/apexpy/lib/python3.9/site-packages/apexpy
    Installing /private/var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-via-sdist-fxyepf27/apexpy-1.1.0/apexpy/helpers.py to /private/var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-via-sdist-fxyepf27/apexpy-1.1.0/.mesonpy-tls7g69g/install/Users/e30737/miniconda3/envs/apexpy/lib/python3.9/site-packages/apexpy
    Installing /private/var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-via-sdist-fxyepf27/apexpy-1.1.0/apexpy/igrf13coeffs.txt to /private/var/folders/yf/c17s54f12c1bg0cxdywsxyxjssh4z4/T/build-via-sdist-fxyepf27/apexpy-1.1.0/.mesonpy-tls7g69g/install/Users/e30737/miniconda3/envs/apexpy/lib/python3.9/site-packages/apexpy
    adding 'apexpy-1.1.0.dist-info/METADATA'
    adding 'apexpy-1.1.0.dist-info/WHEEL'
    adding 'apexpy-1.1.0.dist-info/LICENSE'
    Copying files to wheel...
    adding 'apexpy/fortranapex.cpython-39-darwin.so'                                           
    adding 'apexpy/__init__.py'                   
    adding 'apexpy/__main__.py'
    adding 'apexpy/apex.py'  
    adding 'apexpy/apexsh.dat' 
    adding 'apexpy/helpers.py'
    adding 'apexpy/igrf13coeffs.txt'    
    [6/6] apexpy/igrf13coeffs.txt
    adding 'apexpy-1.1.0.dist-info/RECORD'
    Successfully built apexpy-1.1.0.tar.gz and apexpy-1.1.0-cp39-cp39-macosx_12_0_arm64.whl

@ljlamarche
Copy link
Collaborator Author

ljlamarche commented Nov 29, 2022

Full Output of Inspecting fortranapex.cpython-39-darwin.so
    0000000000009fb4 T _F2PyCapsule_AsVoidPtr
    0000000000009fe4 T _F2PyCapsule_Check
    0000000000009f80 T _F2PyCapsule_FromVoidPtr
    0000000000008308 T _F2PyDict_SetItemString
    000000000000843c T _F2PyGetThreadLocalCallbackPtr
    0000000000008358 T _F2PySwapThreadLocalCallbackPtr
                     U _PyArg_ParseTupleAndKeywords
                     U _PyCapsule_GetPointer
                     U _PyCapsule_New
                     U _PyCapsule_Type
                     U _PyComplex_Type
                     U _PyDict_DelItemString
                     U _PyDict_GetItemString
                     U _PyDict_New
                     U _PyDict_SetItemString
                     U _PyErr_Clear
                     U _PyErr_Fetch
                     U _PyErr_Format
                     U _PyErr_NewException
                     U _PyErr_NoMemory
                     U _PyErr_NormalizeException
                     U _PyErr_Occurred
                     U _PyErr_Print
                     U _PyErr_Restore
                     U _PyErr_SetString
                     U _PyExc_AttributeError
                     U _PyExc_ImportError
                     U _PyExc_MemoryError
                     U _PyExc_OverflowError
                     U _PyExc_RuntimeError
                     U _PyExc_TypeError
                     U _PyExc_ValueError
                     U _PyException_SetCause
                     U _PyException_SetTraceback
                     U _PyFloat_AsDouble
                     U _PyFloat_Type
    00000000000084ac T _PyFortranObject_New
    000000000000866c T _PyFortranObject_NewAsAttr
    0000000000034520 D _PyFortran_Type
                     U _PyImport_ImportModule
    00000000000038f0 T _PyInit_fortranapex
                     U _PyLong_AsLongAndOverflow
                     U _PyLong_AsVoidPtr
                     U _PyLong_FromVoidPtr
                     U _PyMem_Free
                     U _PyMem_Malloc
                     U _PyModule_Create2
                     U _PyModule_GetDict
                     U _PyNumber_Float
                     U _PyNumber_Long
                     U _PyOS_snprintf
                     U _PyObject_Free
                     U _PyObject_GenericGetAttr
                     U _PyObject_GetAttrString
                     U _PyObject_SetAttrString
                     U _PyObject_Str
                     U _PySequence_Check
                     U _PySequence_GetItem
                     U _PyThreadState_GetDict
                     U _PyType_IsSubtype
                     U _PyType_Type
                     U _PyUnicode_AsASCIIString
                     U _PyUnicode_Concat
                     U _PyUnicode_FromFormat
                     U _PyUnicode_FromString
                     U _PyUnicode_FromStringAndSize
                     U _Py_BuildValue
                     U __PyDict_GetItemStringWithError
                     U __PyObject_New
                     U __Py_Dealloc
                     U __Py_FatalErrorFunc
                     U __Py_NoneStruct
    0000000000036660 S ___alfbasismodule_MOD_anm
    0000000000036600 S ___alfbasismodule_MOD_bnm
    00000000000365c0 S ___alfbasismodule_MOD_cm
    0000000000036560 S ___alfbasismodule_MOD_dnm
    0000000000036520 S ___alfbasismodule_MOD_en
    00000000000364e0 S ___alfbasismodule_MOD_marr
    00000000000364d0 S ___alfbasismodule_MOD_mmax0
    0000000000036490 S ___alfbasismodule_MOD_narr
    0000000000036480 S ___alfbasismodule_MOD_nmax0
    000000000000d5a0 T ___apexmodule_MOD_fint
    00000000000363f0 S ___apxin_MOD_yapx
    0000000000037228 S ___apxshmodule_MOD_altlastg
    0000000000037220 S ___apxshmodule_MOD_altlastq
    00000000000371b0 S ___apxshmodule_MOD_coeff0
    00000000000371a0 S ___apxshmodule_MOD_cosqlat
    0000000000037198 S ___apxshmodule_MOD_cosqlon
    0000000000036db0 S ___apxshmodule_MOD_datafile
    0000000000036d70 S ___apxshmodule_MOD_dpolynomq
    0000000000036d30 S ___apxshmodule_MOD_dxqdrhocoeff
    0000000000036cf0 S ___apxshmodule_MOD_dyqdrhocoeff
    0000000000036cb0 S ___apxshmodule_MOD_dzqdrhocoeff
    0000000000036ca0 S ___apxshmodule_MOD_epoch
    0000000000036c60 S ___apxshmodule_MOD_epochgrid
    0000000000036c00 S ___apxshmodule_MOD_gcoeff0
    0000000000036bf0 S ___apxshmodule_MOD_h
    0000000000036bec S ___apxshmodule_MOD_lmax
    0000000000034aa8 D ___apxshmodule_MOD_loadflag
    0000000000036be8 S ___apxshmodule_MOD_mmax
    0000000000036be4 S ___apxshmodule_MOD_nepoch
    0000000000036be0 S ___apxshmodule_MOD_nmax
    0000000000036bdc S ___apxshmodule_MOD_nterm
    0000000000036bd8 S ___apxshmodule_MOD_ntermsh
    0000000000036b80 S ___apxshmodule_MOD_pbar
    0000000000036b40 S ___apxshmodule_MOD_polynomg
    0000000000036b00 S ___apxshmodule_MOD_polynomq
    0000000000036aa0 S ___apxshmodule_MOD_qcoeff0
    0000000000036a98 S ___apxshmodule_MOD_qlat
    0000000000036a80 S ___apxshmodule_MOD_qlatgrad
    0000000000036a78 S ___apxshmodule_MOD_qlon
    0000000000036a60 S ___apxshmodule_MOD_qlongrad
    0000000000036a58 S ___apxshmodule_MOD_reph
    0000000000036a50 S ___apxshmodule_MOD_rho
    0000000000036a10 S ___apxshmodule_MOD_sh
    00000000000369d0 S ___apxshmodule_MOD_shgradphi
    0000000000036990 S ___apxshmodule_MOD_shgradtheta
    0000000000036980 S ___apxshmodule_MOD_sinqlat
    0000000000036978 S ___apxshmodule_MOD_sinqlon
    0000000000036920 S ___apxshmodule_MOD_vbar
    0000000000036918 S ___apxshmodule_MOD_vecflag
    00000000000368c0 S ___apxshmodule_MOD_wbar
    0000000000036880 S ___apxshmodule_MOD_xgcoeff
    0000000000036870 S ___apxshmodule_MOD_xq
    0000000000036830 S ___apxshmodule_MOD_xqcoeff
    0000000000036810 S ___apxshmodule_MOD_xqgrad
    00000000000367d0 S ___apxshmodule_MOD_ygcoeff
    00000000000367c0 S ___apxshmodule_MOD_yq
    0000000000036780 S ___apxshmodule_MOD_yqcoeff
    0000000000036760 S ___apxshmodule_MOD_yqgrad
    0000000000036720 S ___apxshmodule_MOD_zgcoeff
    0000000000036710 S ___apxshmodule_MOD_zq
    00000000000366d0 S ___apxshmodule_MOD_zqcoeff
    00000000000366b8 S ___apxshmodule_MOD_zqgrad
    0000000000036478 S ___dipole_MOD_colat
    0000000000036470 S ___dipole_MOD_ctp
    0000000000036468 S ___dipole_MOD_elon
    0000000000036460 S ___dipole_MOD_stp
    0000000000036458 S ___dipole_MOD_vp
    0000000000036450 S ___fldcomd_MOD_bb
    0000000000036448 S ___fldcomd_MOD_bx
    0000000000036440 S ___fldcomd_MOD_by
    0000000000036438 S ___fldcomd_MOD_bz
    0000000000035510 S ___igrf_MOD_datel
    00000000000354d0 S ___igrf_MOD_epoch
    0000000000035470 S ___igrf_MOD_gt
    0000000000035400 S ___igrf_MOD_gyr
    00000000000353a0 S ___igrf_MOD_ht
    0000000000035330 S ___igrf_MOD_hyr
    0000000000035324 S ___igrf_MOD_nepo
    0000000000035320 S ___igrf_MOD_nght
    00000000000352e0 S ___igrf_MOD_nmxe
    000000000000a130 T ___igrf_MOD_read_igrf
    00000000000363e8 S ___itra_MOD_ds
    00000000000363e0 S ___itra_MOD_nstp
    00000000000363d8 S ___itra_MOD_sgn
    00000000000363c0 S ___itra_MOD_y
    00000000000363a0 S ___itra_MOD_yold
    0000000000036340 S ___itra_MOD_yp
    0000000000035c30 S ___magcof_MOD_gb
    0000000000035528 S ___magcof_MOD_gv
    0000000000035520 S ___magcof_MOD_ichg
    0000000000035518 S ___magcof_MOD_nmax1
                     U ___sprintf_chk
                     U ___stack_chk_fail
                     U ___stack_chk_guard
                     U ___stderrp
                     U ___strcat_chk
                     U __gfortran_exit_i4
                     U __gfortran_fseek_sub
                     U __gfortran_ftell
                     U __gfortran_os_error_at
                     U __gfortran_runtime_error
                     U __gfortran_runtime_error_at
                     U __gfortran_set_args
                     U __gfortran_set_options
                     U __gfortran_st_close
                     U __gfortran_st_open
                     U __gfortran_st_read
                     U __gfortran_st_read_done
                     U __gfortran_st_write
                     U __gfortran_st_write_done
                     U __gfortran_stop_string
                     U __gfortran_string_len_trim
                     U __gfortran_transfer_array
                     U __gfortran_transfer_array_write
                     U __gfortran_transfer_character
                     U __gfortran_transfer_character_write
                     U __gfortran_transfer_integer
                     U __gfortran_transfer_integer_write
                     U __gfortran_transfer_real_write
    00000000000352d0 S __npy_f2py_ARRAY_API
                     U _acos
    000000000000e6f0 T _alfbasis_
    0000000000010f44 T _alfbasisinit_
    00000000000117f0 T _allocatearrays_
    000000000000e560 T _apex_
    0000000000013120 T _apxg2all_
    000000000000f5c0 T _apxg2q_
    0000000000013980 T _apxq2g_
    000000000000910c T _array_from_pyobj
                     U _asin
                     U _atan2
                     U _bzero
                     U _cexp
    0000000000015560 T _choldc_
    00000000000151b0 T _cholsl_
    000000000000c5b4 T _cofrm_
    000000000000c2e0 T _convrt_
    0000000000009f60 T _copy_ND_array
                     U _cos
    000000000000d610 T _dipapx_
    000000000000cc44 T _dypol_
    000000000001af20 T _f2py_alfbasismodule_getdims_anm_
    000000000001b2c0 T _f2py_alfbasismodule_getdims_bnm_
    000000000001b130 T _f2py_alfbasismodule_getdims_cm_
    000000000001b4d0 T _f2py_alfbasismodule_getdims_dnm_
    000000000001b6e0 T _f2py_alfbasismodule_getdims_en_
    000000000001b870 T _f2py_alfbasismodule_getdims_marr_
    000000000001ba00 T _f2py_alfbasismodule_getdims_narr_
    0000000000018920 T _f2py_apxshmodule_getdims_coeff0_
    000000000001a440 T _f2py_apxshmodule_getdims_dpolynomq_
    00000000000194a0 T _f2py_apxshmodule_getdims_dxqdrhocoeff_
    0000000000019630 T _f2py_apxshmodule_getdims_dyqdrhocoeff_
    00000000000197c0 T _f2py_apxshmodule_getdims_dzqdrhocoeff_
    000000000001ad90 T _f2py_apxshmodule_getdims_epochgrid_
    0000000000018de0 T _f2py_apxshmodule_getdims_gcoeff0_
    000000000001a760 T _f2py_apxshmodule_getdims_pbar_
    000000000001a5d0 T _f2py_apxshmodule_getdims_polynomg_
    000000000001a2b0 T _f2py_apxshmodule_getdims_polynomq_
    0000000000018bd0 T _f2py_apxshmodule_getdims_qcoeff0_
    0000000000019e00 T _f2py_apxshmodule_getdims_sh_
    000000000001a120 T _f2py_apxshmodule_getdims_shgradphi_
    0000000000019f90 T _f2py_apxshmodule_getdims_shgradtheta_
    000000000001a970 T _f2py_apxshmodule_getdims_vbar_
    000000000001ab80 T _f2py_apxshmodule_getdims_wbar_
    0000000000019950 T _f2py_apxshmodule_getdims_xgcoeff_
    0000000000018ff0 T _f2py_apxshmodule_getdims_xqcoeff_
    0000000000019ae0 T _f2py_apxshmodule_getdims_ygcoeff_
    0000000000019180 T _f2py_apxshmodule_getdims_yqcoeff_
    0000000000019c70 T _f2py_apxshmodule_getdims_zgcoeff_
    0000000000019310 T _f2py_apxshmodule_getdims_zqcoeff_
    000000000001be30 T _f2pyinitalfbasismodule_
                     U _f2pyinitapxin_
    000000000001bb90 T _f2pyinitapxshmodule_
                     U _f2pyinitdipole_
                     U _f2pyinitfldcomd_
                     U _f2pyinititra_
                     U _f2pyinitmagcof_
                     U _f2pywrapfint_
    000000000000ccf0 T _feldg_
                     U _fint_
    000000000000d7b4 T _fndapx_
                     U _fprintf
                     U _free
    000000000000c210 T _gd2cart_
    000000000000dc50 T _itrace_
    000000000000e1c4 T _linapx_
    0000000000012814 T _loadapxsh_
    000000000001bea0 S _main
    0000000000015770 T _makeapxsh_
                     U _malloc
                     U _memcmp
                     U _memcpy
                     U _memset
                     U _realloc
    000000000000efb0 T _shcalc_
                     U _sin
                     U _snprintf
                     U _sprintf
                     U _strcmp
                     U _strlen
                     U _strncpy
                     U dyld_stub_binder

@ljlamarche
Copy link
Collaborator Author

ljlamarche commented Nov 29, 2022

This may not be a completely isolated issue. I managed to (unintentionally) produce something similar installing apexpy on a CentOS7 machine. Here's the specific error:

>>> import apexpy
fortranapex module could not be imported. apexpy probably won't work. Failed with error: /home/llamarche/Tools/apexpy/apexpy/fortranapex.cpython-39-x86_64-linux-gnu.so: undefined symbol: fint_/home/llamarche/Tools/apexpy/apexpy/apex.py:15: UserWarning: fortranapex module could not be imported, so apexpy probably won't work.  Make sure you have a gfortran compiler. Failed with error: /home/llamarche/Tools/apexpy/apexpy/fortranapex.cpython-39-x86_64-linux-gnu.so: undefined symbol: fint_

It's a different error, but still seems related to the fint function.

Steps to reproduce:

  1. Install build requirements
  2. Build apexpy
    $ FC=/opt/rh/devtoolset-7/root/bin/gfortran CC=/opt/rh/devtoolset-7/root/bin/gcc python -m build .
  3. Install apexpy
    FC=/opt/rh/devtoolset-7/root/bin/gfortran CC=/opt/rh/devtoolset-7/root/bin/gcc pip install -e .

Full Output of Inspecting fortranapex.cpython-39-x86_64-linux-gnu.so

Full Output of Inspecting fortranapex.cpython-39-x86_64-linux-gnu.so
                 U acos@@GLIBC_2.2.5
00000000000171f0 T alfbasis_
000000000001b1e0 T alfbasisinit_
0000000000240a80 B __alfbasismodule_MOD_anm
0000000000240a30 B __alfbasismodule_MOD_bnm
0000000000240a00 B __alfbasismodule_MOD_cm
00000000002409b0 B __alfbasismodule_MOD_dnm
0000000000240980 B __alfbasismodule_MOD_en
0000000000240950 B __alfbasismodule_MOD_marr
0000000000240940 B __alfbasismodule_MOD_mmax0
0000000000240910 B __alfbasismodule_MOD_narr
0000000000240900 B __alfbasismodule_MOD_nmax0
000000000001c5f0 T allocatearrays_
0000000000016fd0 T apex_
0000000000015980 T __apexmodule_MOD_fint
000000000001ee90 T apxg2all_
00000000000190d0 T apxg2q_
0000000000240840 B __apxin_MOD_yapx
000000000001fb60 T apxq2g_
00000000002415a0 B __apxshmodule_MOD_altlastg
0000000000241590 B __apxshmodule_MOD_altlastq
0000000000241530 B __apxshmodule_MOD_coeff0
0000000000241520 B __apxshmodule_MOD_cosqlat
0000000000241510 B __apxshmodule_MOD_cosqlon
0000000000241120 B __apxshmodule_MOD_datafile
00000000002410f0 B __apxshmodule_MOD_dpolynomq
00000000002410c0 B __apxshmodule_MOD_dxqdrhocoeff
0000000000241090 B __apxshmodule_MOD_dyqdrhocoeff
0000000000241060 B __apxshmodule_MOD_dzqdrhocoeff
0000000000241050 B __apxshmodule_MOD_epoch
0000000000241020 B __apxshmodule_MOD_epochgrid
0000000000240fd0 B __apxshmodule_MOD_gcoeff0
0000000000240fc0 B __apxshmodule_MOD_h
0000000000240fb0 B __apxshmodule_MOD_lmax
000000000023ee70 D __apxshmodule_MOD_loadflag
0000000000240fa0 B __apxshmodule_MOD_mmax
0000000000240f90 B __apxshmodule_MOD_nepoch
0000000000240f80 B __apxshmodule_MOD_nmax
0000000000240f70 B __apxshmodule_MOD_nterm
0000000000240f60 B __apxshmodule_MOD_ntermsh
0000000000240f10 B __apxshmodule_MOD_pbar
0000000000240ee0 B __apxshmodule_MOD_polynomg
0000000000240eb0 B __apxshmodule_MOD_polynomq
0000000000240e60 B __apxshmodule_MOD_qcoeff0
0000000000240e50 B __apxshmodule_MOD_qlat
0000000000240e30 B __apxshmodule_MOD_qlatgrad
0000000000240e20 B __apxshmodule_MOD_qlon
0000000000240e00 B __apxshmodule_MOD_qlongrad
0000000000240df0 B __apxshmodule_MOD_reph
0000000000240de0 B __apxshmodule_MOD_rho
0000000000240db0 B __apxshmodule_MOD_sh
0000000000240d80 B __apxshmodule_MOD_shgradphi
0000000000240d50 B __apxshmodule_MOD_shgradtheta
0000000000240d40 B __apxshmodule_MOD_sinqlat
0000000000240d30 B __apxshmodule_MOD_sinqlon
0000000000240ce0 B __apxshmodule_MOD_vbar
0000000000240cd0 B __apxshmodule_MOD_vecflag
0000000000240c80 B __apxshmodule_MOD_wbar
0000000000240c50 B __apxshmodule_MOD_xgcoeff
0000000000240c40 B __apxshmodule_MOD_xq
0000000000240c10 B __apxshmodule_MOD_xqcoeff
0000000000240bf0 B __apxshmodule_MOD_xqgrad
0000000000240bc0 B __apxshmodule_MOD_ygcoeff
0000000000240bb0 B __apxshmodule_MOD_yq
0000000000240b80 B __apxshmodule_MOD_yqcoeff
0000000000240b60 B __apxshmodule_MOD_yqgrad
0000000000240b30 B __apxshmodule_MOD_zgcoeff
0000000000240b20 B __apxshmodule_MOD_zq
0000000000240af0 B __apxshmodule_MOD_zqcoeff
0000000000240ad0 B __apxshmodule_MOD_zqgrad
000000000000f800 T array_from_pyobj
                 U asin@@GLIBC_2.2.5
                 U atan2@@GLIBC_2.2.5
000000000023f688 B __bss_start
0000000000022190 T choldc_
0000000000021d20 T cholsl_
00000000000143f0 T cofrm_
0000000000013e40 T convrt_
0000000000010430 T copy_ND_array
                 U cos@@GLIBC_2.2.5
                 w __cxa_finalize@@GLIBC_2.2.5
0000000000015a20 T dipapx_
00000000002408f8 B __dipole_MOD_colat
00000000002408f0 B __dipole_MOD_ctp
00000000002408e0 B __dipole_MOD_elon
00000000002408d0 B __dipole_MOD_stp
00000000002408c8 B __dipole_MOD_vp
0000000000014cf0 T dypol_
000000000023f688 D _edata
00000000002415b0 B _end
0000000000029df0 T f2py_alfbasismodule_getdims_anm_
000000000002a150 T f2py_alfbasismodule_getdims_bnm_
000000000002a010 T f2py_alfbasismodule_getdims_cm_
000000000002a370 T f2py_alfbasismodule_getdims_dnm_
000000000002a590 T f2py_alfbasismodule_getdims_en_
000000000002a6d0 T f2py_alfbasismodule_getdims_marr_
000000000002a810 T f2py_alfbasismodule_getdims_narr_
0000000000027c70 T f2py_apxshmodule_getdims_coeff0_
00000000000293d0 T f2py_apxshmodule_getdims_dpolynomq_
0000000000028750 T f2py_apxshmodule_getdims_dxqdrhocoeff_
0000000000028890 T f2py_apxshmodule_getdims_dyqdrhocoeff_
00000000000289d0 T f2py_apxshmodule_getdims_dzqdrhocoeff_
0000000000029cb0 T f2py_apxshmodule_getdims_epochgrid_
0000000000028170 T f2py_apxshmodule_getdims_gcoeff0_
0000000000029650 T f2py_apxshmodule_getdims_pbar_
0000000000029510 T f2py_apxshmodule_getdims_polynomg_
0000000000029290 T f2py_apxshmodule_getdims_polynomq_
0000000000027f50 T f2py_apxshmodule_getdims_qcoeff0_
0000000000028ed0 T f2py_apxshmodule_getdims_sh_
0000000000029150 T f2py_apxshmodule_getdims_shgradphi_
0000000000029010 T f2py_apxshmodule_getdims_shgradtheta_
0000000000029870 T f2py_apxshmodule_getdims_vbar_
0000000000029a90 T f2py_apxshmodule_getdims_wbar_
0000000000028b10 T f2py_apxshmodule_getdims_xgcoeff_
0000000000028390 T f2py_apxshmodule_getdims_xqcoeff_
0000000000028c50 T f2py_apxshmodule_getdims_ygcoeff_
00000000000284d0 T f2py_apxshmodule_getdims_yqcoeff_
0000000000028d90 T f2py_apxshmodule_getdims_zgcoeff_
0000000000028610 T f2py_apxshmodule_getdims_zqcoeff_
0000000000010c80 T F2PyCapsule_AsVoidPtr
0000000000010cb0 T F2PyCapsule_Check
0000000000010450 T F2PyCapsule_FromVoidPtr
000000000000f460 T F2PyDict_SetItemString
000000000000f590 T F2PyGetThreadLocalCallbackPtr
000000000002aca0 T f2pyinitalfbasismodule_
                 U f2pyinitapxin_
000000000002a950 T f2pyinitapxshmodule_
                 U f2pyinitdipole_
                 U f2pyinitfldcomd_
                 U f2pyinititra_
                 U f2pyinitmagcof_
000000000000f4b0 T F2PySwapThreadLocalCallbackPtr
                 U f2pywrapfint_
0000000000014df0 T feldg_
000000000002ad00 T _fini
                 U fint_
00000000002408c0 B __fldcomd_MOD_bb
00000000002408b0 B __fldcomd_MOD_bx
00000000002408a0 B __fldcomd_MOD_by
0000000000240890 B __fldcomd_MOD_bz
0000000000015e10 T fndapx_
                 U fprintf@@GLIBC_2.2.5
                 U free@@GLIBC_2.2.5
0000000000014380 T gd2cart_
                 U _gfortran_compare_string@@GFORTRAN_1.0
                 U _gfortran_exit_i4@@GFORTRAN_1.0
                 U _gfortran_fseek_sub@@GFORTRAN_1.0
                 U _gfortran_ftell2@@GFORTRAN_1.5
                 U _gfortran_os_error@@GFORTRAN_1.0
                 U _gfortran_runtime_error_at@@GFORTRAN_1.0
                 U _gfortran_runtime_error@@GFORTRAN_1.0
                 U _gfortran_set_args@@GFORTRAN_1.0
                 U _gfortran_set_options@@GFORTRAN_1.0
                 U _gfortran_st_close@@GFORTRAN_1.0
                 U _gfortran_st_open@@GFORTRAN_1.0
                 U _gfortran_stop_string@@GFORTRAN_1.0
                 U _gfortran_st_read_done@@GFORTRAN_1.0
                 U _gfortran_st_read@@GFORTRAN_1.0
                 U _gfortran_string_len_trim@@GFORTRAN_1.0
                 U _gfortran_st_write_done@@GFORTRAN_1.0
                 U _gfortran_st_write@@GFORTRAN_1.0
                 U _gfortran_transfer_array@@GFORTRAN_1.0
                 U _gfortran_transfer_array_write@@GFORTRAN_1.4
                 U _gfortran_transfer_character@@GFORTRAN_1.0
                 U _gfortran_transfer_character_write@@GFORTRAN_1.4
                 U _gfortran_transfer_integer@@GFORTRAN_1.0
                 U _gfortran_transfer_integer_write@@GFORTRAN_1.4
                 U _gfortran_transfer_real_write@@GFORTRAN_1.4
                 w __gmon_start__
000000000023f8e0 B __igrf_MOD_datel
000000000023f8b0 B __igrf_MOD_epoch
000000000023f860 B __igrf_MOD_gt
000000000023f800 B __igrf_MOD_gyr
000000000023f7b0 B __igrf_MOD_ht
000000000023f750 B __igrf_MOD_hyr
000000000023f744 B __igrf_MOD_nepo
000000000023f740 B __igrf_MOD_nght
000000000023f710 B __igrf_MOD_nmxe
0000000000010cd0 T __igrf_MOD_read_igrf
0000000000006ed0 T _init
                 w _ITM_deregisterTMCloneTable
                 w _ITM_registerTMCloneTable
0000000000016570 T itrace_
0000000000240820 B __itra_MOD_ds
0000000000240810 B __itra_MOD_nstp
0000000000240800 B __itra_MOD_sgn
00000000002407e0 B __itra_MOD_y
00000000002407c0 B __itra_MOD_yold
0000000000240760 B __itra_MOD_yp
                 w _Jv_RegisterClasses
0000000000016b30 T linapx_
000000000001e0f0 T loadapxsh_
0000000000240040 B __magcof_MOD_gb
000000000023f920 B __magcof_MOD_gv
000000000023f910 B __magcof_MOD_ichg
000000000023f900 B __magcof_MOD_nmax1
0000000000007730 T main
0000000000022450 T makeapxsh_
                 U malloc@@GLIBC_2.2.5
                 U memcpy@@GLIBC_2.14
                 U memmove@@GLIBC_2.2.5
                 U memset@@GLIBC_2.2.5
00000000002415a8 B _npy_f2py_ARRAY_API
                 U PyArg_ParseTupleAndKeywords
                 U Py_BuildValue
                 U PyCapsule_GetPointer
                 U PyCapsule_New
                 U PyCapsule_Type
                 U PyComplex_Type
                 U _Py_Dealloc
                 U PyDict_DelItemString
                 U PyDict_GetItemString
                 U _PyDict_GetItemStringWithError
                 U PyDict_New
                 U PyDict_SetItemString
                 U PyErr_Clear
                 U PyErr_Fetch
                 U PyErr_Format
                 U PyErr_NewException
                 U PyErr_NoMemory
                 U PyErr_NormalizeException
                 U PyErr_Occurred
                 U PyErr_Print
                 U PyErr_Restore
                 U PyErr_SetString
                 U PyExc_AttributeError
                 U PyException_SetCause
                 U PyException_SetTraceback
                 U PyExc_ImportError
                 U PyExc_MemoryError
                 U PyExc_OverflowError
                 U PyExc_RuntimeError
                 U PyExc_TypeError
                 U PyExc_ValueError
                 U _Py_FatalErrorFunc
                 U PyFloat_AsDouble
                 U PyFloat_Type
000000000000f650 T PyFortranObject_New
000000000000f600 T PyFortranObject_NewAsAttr
000000000023e8c0 D PyFortran_Type
                 U PyImport_ImportModule
000000000000e510 T PyInit_fortranapex
                 U PyLong_AsLongAndOverflow
                 U PyLong_AsVoidPtr
                 U PyLong_FromVoidPtr
                 U PyMem_Free
                 U PyMem_Malloc
                 U PyModule_Create2
                 U PyModule_GetDict
                 U _Py_NoneStruct
                 U PyNumber_Float
                 U PyNumber_Long
                 U PyObject_Free
                 U PyObject_GenericGetAttr
                 U PyObject_GetAttrString
                 U _PyObject_New
                 U PyObject_SetAttrString
                 U PyObject_Str
                 U PyOS_snprintf
                 U PySequence_Check
                 U PySequence_GetItem
                 U PyThreadState_GetDict
                 U PyType_IsSubtype
                 U PyType_Type
                 U PyUnicode_AsASCIIString
                 U PyUnicode_Concat
                 U PyUnicode_FromFormat
                 U PyUnicode_FromString
                 U PyUnicode_FromStringAndSize
                 U realloc@@GLIBC_2.2.5
0000000000018840 T shcalc_
                 U sincos@@GLIBC_2.2.5
                 U sin@@GLIBC_2.2.5
                 U snprintf@@GLIBC_2.2.5
                 U sprintf@@GLIBC_2.2.5
                 U sqrtf@@GLIBC_2.2.5
                 U sqrt@@GLIBC_2.2.5
                 U stderr@@GLIBC_2.2.5
                 U strcmp@@GLIBC_2.2.5
                 U strlen@@GLIBC_2.2.5
                 U strncpy@@GLIBC_2.2.5

I assume this is still something wierd I'm doing because noone else is having this issue, but I can't figure out what... Unless anyone has a better idea, I might try reformulating fint as a module just to see if it makes the problem magically go away?

@aburrell
Copy link
Owner

What happens if you use pip without the -e flag?

@ljlamarche
Copy link
Collaborator Author

No such luck, same issue :( ...

@aburrell
Copy link
Owner

aburrell commented Dec 1, 2022

Ah, I got a similar error pairing CC clang with FC gfortran. From your output:

C compiler for the host machine: arm64-apple-darwin20.0.0-clang (clang 14.0.6 "clang version 14.0.6")
C linker for the host machine: arm64-apple-darwin20.0.0-clang ld64 609

It looks like the CC to gcc isn't working?

@ljlamarche
Copy link
Collaborator Author

Ah, I forgot there were sometimes issues with clang! Do you suppose specifying CC to some version of gcc would help? I can try in a few minutes.

@aburrell
Copy link
Owner

aburrell commented Dec 1, 2022

I think it will fix your issue, it worked for me!

@ljlamarche
Copy link
Collaborator Author

ljlamarche commented Dec 1, 2022

Oh no, now it doesn't install at all!

gcc: error: this compiler does not support arm64

Let me see if I can update gcc. The default is identified as "experimental".

@ljlamarche ljlamarche mentioned this issue Dec 5, 2022
11 tasks
@aburrell
Copy link
Owner

aburrell commented Dec 6, 2022

@ljlamarche has this been resolved now?

@ljlamarche
Copy link
Collaborator Author

Yes. Ultimately there's two things to remember when building/testing apexpy:

  1. You can't use the -e flag with meson
  2. You can't test the installation in the apexpy directory because it imports it directly from the source there rather than using the installed and compiled version (which I suspect is fundamentally the same issue)

I don't THINK the gcc thing actually had anything to do with this, although I haven't tested it thoroughly. The instructions to use -e were removed from the documentation, so I think we're set with this!

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

No branches or pull requests

2 participants