summaryrefslogtreecommitdiff
path: root/lib/make/configure.in
diff options
context:
space:
mode:
authoreschnett <eschnett@17b73243-c579-4c4c-a9d2-2d5706c11dac>2012-05-02 00:26:14 +0000
committereschnett <eschnett@17b73243-c579-4c4c-a9d2-2d5706c11dac>2012-05-02 00:26:14 +0000
commitb7e100f8ac916f47f4a6b01002bd5157a2eccdf0 (patch)
tree013aee66410b173897b28b4a8783473f10a6493a /lib/make/configure.in
parent9ebfa0fd87f4582f90f58f979e5a5b8deb659501 (diff)
Support OpenCL source code (.cl files)
OpenCL source code needs to be compiled at run time, and thus needs to be passed as string to the OpenCL run-time library. This makes writing OpenCL source code inconvenient. This patch adds *.cl as supported file type to Cactus. *.cl files are transformed into globally visible strings, with a name consisting of the thorn name and file name. These strings can then be easily used at run time to build and run OpenCL code. Since *.cl files are converted to strings (and are not OpenCL-compiled at build time), there are no CL* options specifying compiler type, compiler flags etc. git-svn-id: http://svn.cactuscode.org/flesh/trunk@4808 17b73243-c579-4c4c-a9d2-2d5706c11dac
Diffstat (limited to 'lib/make/configure.in')
-rw-r--r--lib/make/configure.in18
1 files changed, 18 insertions, 0 deletions
diff --git a/lib/make/configure.in b/lib/make/configure.in
index df2dc0ca..b673cbd3 100644
--- a/lib/make/configure.in
+++ b/lib/make/configure.in
@@ -1186,6 +1186,14 @@ if test "$host_os" = 'cygwin' ; then
PERL_CONFIGURE_SCRIPT=`echo $PERL_CONFIGURE_SCRIPT | sed 's,^/cygdrive/\(.\)/,\1:/,' | sed 's,^//\(.\)/,\1:/,'`
fi
+# An OpenCL source file has no external dependencies
+AC_SUBST(CL_DEPEND)
+# This command will not output a correct dependency by itself (it
+# does not output a target), but the Cactus dependency fixer will
+# overwrite the target anyway with the correct information.
+: ${CL_DEPEND='echo :'}
+AC_SUBST(CL_DEPEND_OUT)
+: ${CL_DEPEND_OUT=' > $@'}
AC_SUBST(BUILD_ACTIVETHORNS)
BUILD_ACTIVETHORNS='$(CCTK_HOME)/lib/sbin/BuildActiveThorns.pl'
@@ -1208,6 +1216,14 @@ AC_SUBST(FCOMPILEONLY)
: ${CCOMPILEONLY='-c -o'}
: ${FCOMPILEONLY='-c -o'}
+# An OpenCL source file has no external dependencies
+AC_SUBST(CL_DEPEND)
+# This command will not output a correct dependency by itself (it
+# does not output a target), but the Cactus dependency fixer will
+# overwrite the target anyway with the correct information.
+: ${CL_DEPEND='echo :'}
+AC_SUBST(CL_DEPEND_OUT)
+: ${CL_DEPEND_OUT=' > $@'}
# Set the createexe flag if it's not been set by now
AC_SUBST(CREATEEXE)
@@ -1268,6 +1284,8 @@ AC_SUBST(C_POSTPROCESSING)
: ${C_POSTPROCESSING=''}
AC_SUBST(CXX_POSTPROCESSING)
: ${CXX_POSTPROCESSING=''}
+AC_SUBST(CL_POSTPROCESSING)
+: ${CL_POSTPROCESSING=''}
AC_SUBST(CU_POSTPROCESSING)
: ${CU_POSTPROCESSING=''}
AC_SUBST(F77_POSTPROCESSING)