gtool ビルドログ @ pifront

  • 作業日 2021/09/24 修正
  • 作業者 高橋芳幸

準備

必要なファイルの取得

必要なファイル

  • gtool
https://www.gfd-dennou.org/library/gtool/gtool5/gtool5-20160613.tgz
ver. 20160613

ビルド

gtool5

ビルドは, ~/tmp/gtool 以下で行う.

$ tar xvf gtool5-20160613.tgz
$ cd gtool5-20160613

$ export FC=mpiifort
$ export FFLAGS="-march=core-avx2 -qopenmp"
$ export SYSFFLAGS="-march=core-avx2 -qopenmp -I/home/G50002/yot/local/netcdf-c-4.8.0-fortran-4.5.3-intel/include"

$ ./configure \
--with-netcdf=/home/G50002/yot/local/netcdf-c-4.8.0-fortran-4.5.3-intel/lib/libnetcdf.a \
--with-netcdff=/home/G50002/yot/local/netcdf-c-4.8.0-fortran-4.5.3-intel/lib/libnetcdff.a \
--prefix=/home/G50002/yot/local/gtool5-20160613-intel \
--enable-mpi

$ make

下のようなエラーが出る.

mpiifort -o gtdata_internal_vartable.o -c -I../../include -march=core-avx2 -qopenmp -march=core-avx2 -qopenmp -I/home/G50002/yot/local/netcdf-c-4.8.0-fortran-4.5.3-intel/include    gtdata_internal_vartable.f90
ifort: command line warning #10121: overriding '-march=core-avx2' with '-march=core-avx2'
'gtdata_internal_vartable.mod' -> '../../include/gtdata_internal_vartable.mod'
mpiifort -o gtdata_internal_map.o -c -I../../include -march=core-avx2 -qopenmp -march=core-avx2 -qopenmp -I/home/G50002/yot/local/netcdf-c-4.8.0-fortran-4.5.3-intel/include    gtdata_internal_map.f90
ifort: command line warning #10121: overriding '-march=core-avx2' with '-march=core-avx2'
gtdata_internal_map.f90(86): error #7002: Error in opening the compiled module file.  Check INCLUDE paths.   [GTDATA_GENERIC]
    use gtdata_generic, only: open, close
--------^
gtdata_internal_map.f90(93): error #6632: Keyword arguments are invalid without an explicit interface.   [COUNT_COMPACT]
    call open(dimvar, var, dimno, count_compact=.true.)
----------------------------------^
gtdata_internal_map.f90(86): error #6580: Name in only-list does not exist or is not accessible.   [CLOSE]
    use gtdata_generic, only: open, close
------------------------------------^
gtdata_internal_map.f90(86): error #6580: Name in only-list does not exist or is not accessible.   [OPEN]
    use gtdata_generic, only: open, close
------------------------------^
compilation aborted for gtdata_internal_map.f90 (code 1)
make[2]: *** [../../rules.make:39: gtdata_internal_map.o] Error 1
make[2]: Leaving directory '/home/G50002/yot/tmp/gtool/gtool5-20160613/src/gtdata'
make[1]: *** [Makefile:35: rb2f90] Error 1
make[1]: Leaving directory '/home/G50002/yot/tmp/gtool/gtool5-20160613/src'
make: *** [Makefile:39: all] Error 2

そこで, src/gtdata/depend の gtdata_internal_map.o: の行にある gtdata_generic.erb を gtdata_generic.o に書き換えて再び make

$ make

成功

$ make test
$ make install
$ make test-installed