Skip to content

Instantly share code, notes, and snippets.

@czgdp1807
Last active February 16, 2022 06:04
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save czgdp1807/a4ad276fdb42f6ebb043389427fba635 to your computer and use it in GitHub Desktop.
Save czgdp1807/a4ad276fdb42f6ebb043389427fba635 to your computer and use it in GitHub Desktop.
Current state: Compiling `stdlib` with `lfortran`
  1. Fetch numfocus-round2 for lfortran branch from here. Do a clean build of lfortran after checking out to numfocus-round2.
  2. Fetch master-lfortran for stdlib branch from here. Check out to master-lfortran.
  3. Run, FFLAGS=“--non-symtab-only” FC=lfortran cmake . inside stdlib.
  4. Run, make. You should be able to see the following logs,
[ 48%] Building Fortran object src/CMakeFiles/fortran_stdlib.dir/stdlib_system.F90.o
[ 49%] Linking Fortran static library libfortran_stdlib.a
warning: /Library/Developer/CommandLineTools/usr/bin/ranlib: archive library: libfortran_stdlib.a the table of contents is empty (no object file members in the library define global symbols)
[ 49%] Built target fortran_stdlib
Scanning dependencies of target test_always_skip
[ 50%] Building Fortran object src/tests/CMakeFiles/test_always_skip.dir/test_always_skip.f90.o
semantic error: Module 'stdlib_error' not declared in the current source and the modfile was not found
 --> /Users/czgdp1807/lfortran_project/stdlib/src/tests/test_always_skip.f90:3:1
  |
3 | use stdlib_error, only: check
  | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ 
  1. Now, fetch stdlib_non_symtab for lfortran from here. Do a clean build after checking out to stdlib_non_symtab.
  2. Run, FC=lfortran cmake . and then make in stdlib. Though note that for stdlib you don’t have to change in branches. You should be able to see the following logs,
Note: if any of the above error or warning messages are not clear or are lacking
context please report it to us (we consider that a bug that needs to be fixed).
[ 24%] Building Fortran object src/CMakeFiles/fortran_stdlib.dir/stdlib_bitsets.f90.o
[ 25%] Building Fortran object src/CMakeFiles/fortran_stdlib.dir/stdlib_bitsets_64.f90.o

Please let me know if you face any problem in the above steps. Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment