[ET Trac] [Einstein Toolkit] #768: Change per thorn -DTHORN_IS_xxx to a per thorn -I bindings/include/xxx
Einstein Toolkit
trac-noreply at einsteintoolkit.org
Tue Apr 24 14:56:42 CDT 2012
#768: Change per thorn -DTHORN_IS_xxx to a per thorn -I bindings/include/xxx
--------------------------+-------------------------------------------------
Reporter: sbrandt | Owner:
Type: enhancement | Status: new
Priority: optional | Milestone: Cactus_4.1.0
Component: Cactus | Version: Cactus_4.0.0
Resolution: | Keywords: build system
--------------------------+-------------------------------------------------
Comment (by eschnett):
This patch fails for me when I build with DEBUG=yes. The errors look like
/home/eschnett/Cvanilla/src/include/cctk.h(309): error: identifier
"CCTK_THORNSTRING" is undefined
__LINE__, __FILE__, CCTK_THORNSTRING,
compilation aborted for /home/eschnett/Cvanilla/configs/sim-
debug/build/CactusBindings/Variables/ADM.c (code 2)
This is because the auto-generated file ADM.c includes cctk, which
defines
static inline functions that use CCTK_THORNSTRING. However, at the
including place this is not defined.
I can see three solutions:
(1) require every place that include cctk.h to define CCTK_THORNSTRING
(possibly explicitly)
(2) augment definethisthorn.h to define CCTK_THORNSTRING to "no thorn
active" if no thorn is active
(3) put some preprocessor logic into cctk.h to ensure CCTK_THORNSTRING is
defined there
--
Ticket URL: <https://trac.einsteintoolkit.org/ticket/768#comment:4>
Einstein Toolkit <http://einsteintoolkit.org>
The Einstein Toolkit
More information about the Trac
mailing list