The Astaroth Code Compiler (acc) is now built with cmake. Additionally, make is now used to generate the CUDA headers from DSL sources. The headers are also properly regenerated whenever a DSL file has been changed. With this commit, the DSL is now seamlessly integrated to the library and we no longer need complicated scripts to figure out the correct files. The current workflow for using custom DSL sources is to pass the DSL module directory to cmake, f.ex. cmake -DDSL_MODULE_DIR=/acc/mhd_solver. Note that the path must be absolute or then given relative to the CMakeLists.txt directory. f.ex cd build && cmake -DDSL_MODULE_DIR=../acc/mhd_solver does not work. CMake then takes all DSL files in that directory and handles the rest.

This commit is contained in:
jpekkila
2019-09-18 17:28:29 +03:00
parent bce3e4de03
commit 3bb6ca1712
7 changed files with 55 additions and 13 deletions

View File

@@ -1,4 +1,4 @@
#!/bin/bash
# Preprocesses the give file using GCC. This script is usually automatically called in
# ./compile.sh, but may be called also individually for debugging purposes.
cat ${@} | gcc -x c -E - | sed "s/#.*//g"
cat $1 | gcc ${@:2} -x c -E - | sed "s/#.*//g"