Adding rudimentary building script
Usage:
$ ./test_build.py
Usage:
./test_build.py dwarfs_to_build.json [compilers.json]
It uses json
configuration files: dwarfs_to_build.json
is a configuration file with dwarfs/contribution that need to be tested for build. compiler.sjon
is a list of compilers for c++
, c
and fortran
. Provided one for linux with default compilers for ICC,PGI,GCC,CLANG and for OSX with MacPorts.
If using non-standard compilers, copy an appropriate json
file and adjust it; same applies for json
file for dwarfs/contributions to be tested.
Example output on my macbook:
$ ./test_build.py dwarfs_to_build.json compilers_osx_macports.json
Going to build the following dwarfs:
*everything*
src/1_dense
src/3_spectral
src/4_nbody
src/8_IO
src/4_nbody/hermite4
src/4_nbody/bhtree
-------------------------
Using the following compilers:
{'CLANG': {'cc': 'clang', 'cxx': 'clang++'},
'GCC': {'cc': 'gcc-mp-4.9',
'cxx': 'g++-mp-4.9',
'fortran': 'gfortran-mp-4.9'},
'ICC': {'cc': 'icc', 'cxx': 'icpc', 'fortran': 'ifort'},
'PGI': {'cc': 'pgcc', 'cxx': 'pgc++', 'fortran': 'pgf90'}}
-------------------------
Attempting to build with ICC ... OK log is in _build_log_2015_08_12_15_19_32/_ICC.log
Attempting to build src/1_dense with ICC ... OK log is in _build_log_2015_08_12_15_19_32/src_1_dense_ICC.log
Attempting to build src/3_spectral with ICC ... OK log is in _build_log_2015_08_12_15_19_32/src_3_spectral_ICC.log
Attempting to build src/4_nbody with ICC ... OK log is in _build_log_2015_08_12_15_19_32/src_4_nbody_ICC.log
Attempting to build src/8_IO with ICC ... OK log is in _build_log_2015_08_12_15_19_32/src_8_IO_ICC.log
Attempting to build src/4_nbody/hermite4 with ICC ... OK log is in _build_log_2015_08_12_15_19_32/src_4_nbody_hermite4_ICC.log
Attempting to build src/4_nbody/bhtree with ICC ... OK log is in _build_log_2015_08_12_15_19_32/src_4_nbody_bhtree_ICC.log
Attempting to build with GCC ... OK log is in _build_log_2015_08_12_15_19_32/_GCC.log
Attempting to build src/1_dense with GCC ... OK log is in _build_log_2015_08_12_15_19_32/src_1_dense_GCC.log
Attempting to build src/3_spectral with GCC ... OK log is in _build_log_2015_08_12_15_19_32/src_3_spectral_GCC.log
Attempting to build src/4_nbody with GCC ... OK log is in _build_log_2015_08_12_15_19_32/src_4_nbody_GCC.log
Attempting to build src/8_IO with GCC ... OK log is in _build_log_2015_08_12_15_19_32/src_8_IO_GCC.log
Attempting to build src/4_nbody/hermite4 with GCC ... OK log is in _build_log_2015_08_12_15_19_32/src_4_nbody_hermite4_GCC.log
Attempting to build src/4_nbody/bhtree with GCC ... OK log is in _build_log_2015_08_12_15_19_32/src_4_nbody_bhtree_GCC.log
Attempting to build with CLANG ... OK log is in _build_log_2015_08_12_15_19_32/_CLANG.log
Attempting to build src/1_dense with CLANG ... OK log is in _build_log_2015_08_12_15_19_32/src_1_dense_CLANG.log
Attempting to build src/3_spectral with CLANG ... OK log is in _build_log_2015_08_12_15_19_32/src_3_spectral_CLANG.log
Attempting to build src/4_nbody with CLANG ... OK log is in _build_log_2015_08_12_15_19_32/src_4_nbody_CLANG.log
Attempting to build src/8_IO with CLANG ... OK log is in _build_log_2015_08_12_15_19_32/src_8_IO_CLANG.log
Attempting to build src/4_nbody/hermite4 with CLANG ... OK log is in _build_log_2015_08_12_15_19_32/src_4_nbody_hermite4_CLANG.log
Attempting to build src/4_nbody/bhtree with CLANG ... OK log is in _build_log_2015_08_12_15_19_32/src_4_nbody_bhtree_CLANG.log
Attempting to build with PGI ... *FAIL* log is in _build_log_2015_08_12_15_19_32/_PGI.log
Attempting to build src/1_dense with PGI ... *FAIL* log is in _build_log_2015_08_12_15_19_32/src_1_dense_PGI.log
Attempting to build src/3_spectral with PGI ... *FAIL* log is in _build_log_2015_08_12_15_19_32/src_3_spectral_PGI.log
Attempting to build src/4_nbody with PGI ... *FAIL* log is in _build_log_2015_08_12_15_19_32/src_4_nbody_PGI.log
Attempting to build src/8_IO with PGI ... *FAIL* log is in _build_log_2015_08_12_15_19_32/src_8_IO_PGI.log
Attempting to build src/4_nbody/hermite4 with PGI ... *FAIL* log is in _build_log_2015_08_12_15_19_32/src_4_nbody_hermite4_PGI.log
Attempting to build src/4_nbody/bhtree with PGI ... OK log is in _build_log_2015_08_12_15_19_32/src_4_nbody_bhtree_PGI.log