Hi, I just tried to compile the ET (ET_RELEASE = ET_2010_11) and got many errors in the linking stage of the sort
/u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/build/Cactus/main/Parameters.c:(.text+0x36): undefined reference to `regfreeA'
For the full output see below. I was using the intel compiler version 10.1. The same source tree compiled fine before on other systems using gnu and xlc compilers. I don't know however if the problem is really related to the compiler, I'll try with gnu as well. During the configure stage, regexp.h was found on the system. I remember that Cactus has its own version of regexp, maybe there is a conflict.
Any ideas ?
Regards, Wolfgang.
--------------------
Creating cactus_pizza_dev in /u/ap/kastaun/sim_build/pizza_dev/exe from EinsteinBase/ADMBase AEIThorns/AEILocalInterp CactusBase/Boundary Carpet/Carpet Carpet/CarpetEvolutionMask Carpet/CarpetIOASCII Carpet/CarpetIOBasic Carpet/CarpetIOHDF5 Carpet/CarpetIOScalar Carpet/CarpetInterp Carpet/CarpetInterp2 Carpet/CarpetLib Carpet/CarpetMask Carpet/CarpetReduce Carpet/CarpetRegrid Carpet/CarpetRegrid2 Carpet/CarpetSlab Carpet/CarpetTracker CactusBase/CartGrid3D CactusBase/CoordBase CactusBase/Fortran ExternalLibraries/GSL ExternalLibraries/HDF5 EinsteinBase/HydroBase PizzaDev/HydroBase_RNSID CactusBase/IOASCII CactusBase/IOBasic CactusBase/IOUtil CactusBase/InitBase CactusBase/LocalInterp CactusBase/LocalReduce Carpet/LoopControl CactusNumerical/MoL EinsteinAnalysis/Multipole CactusUtils/Nice CactusNumerical/Norms CactusNumerical/Periodic PizzaDev/Pizza PizzaDev/PizzaBase PizzaDev/PizzaIDBase PizzaDev/PizzaIDFile PizzaDev/PizzaMultipoles PizzaDev/PizzaMultipoles2 PizzaDev/PizzaPertEFF PizzaDev/PizzaPerturb PizzaDev/PizzaRNSA PizzaDev/PizzaRecycle PizzaDev/PizzaSample PizzaDev/PizzaStar PizzaDev/PizzaTOV CactusNumerical/ReflectionSymmetry CactusNumerical/RotatingSymmetry180 CactusNumerical/RotatingSymmetry90 CactusNumerical/Slab CactusNumerical/SlabTest CactusNumerical/SpaceMask CactusNumerical/SphericalSurface CactusBase/SymBase CactusUtils/TerminationTrigger CactusBase/Time CactusUtils/TimerReport /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/lib/libthorn_Cactus.a(Parameters.c.o): In function `CCTK_ParameterSetNotifyUnregister': /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/build/Cactus/main/Parameters.c:(.text+0x36): undefined reference to `regfreeA' /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/build/Cactus/main/Parameters.c:(.text+0x4a): undefined reference to `regfreeA' /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/lib/libthorn_Cactus.a(Parameters.c.o): In function `cctk_parametersetnotifyunregister_': /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/build/Cactus/main/Parameters.c:(.text+0xad): undefined reference to `regfreeA' /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/build/Cactus/main/Parameters.c:(.text+0xc1): undefined reference to `regfreeA' /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/lib/libthorn_Cactus.a(Parameters.c.o): In function `CCTK_ParameterSetNotifyRegister': /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/build/Cactus/main/Parameters.c:(.text+0x1a2): undefined reference to `regcompA' /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/build/Cactus/main/Parameters.c:(.text+0x1be): undefined reference to `regcompA' /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/lib/libthorn_Cactus.a(Parameters.c.o): In function `cctk_parametersetnotifyregister_': /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/build/Cactus/main/Parameters.c:(.text+0x317): undefined reference to `regcompA' /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/build/Cactus/main/Parameters.c:(.text+0x33b): undefined reference to `regcompA' /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/lib/libthorn_Cactus.a(Parameters.c.o): In function `CCTK_ParameterSet': /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/build/Cactus/main/Parameters.c:(.text+0x1122): undefined reference to `regexecA' /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/build/Cactus/main/Parameters.c:(.text+0x1141): undefined reference to `regexecA' /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/lib/libthorn_Cactus.a(Parameters.c.o): In function `cctk_parameterset_': /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/build/Cactus/main/Parameters.c:(.text+0x1aba): undefined reference to `regexecA' /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/build/Cactus/main/Parameters.c:(.text+0x1ad9): undefined reference to `regexecA' /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/lib/libthorn_Cactus.a(Misc.c.o): In function `CCTK_RegexMatch': /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/build/Cactus/util/Misc.c:(.text+0x1ac): undefined reference to `regcompA' /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/build/Cactus/util/Misc.c:(.text+0x1d1): undefined reference to `regexecA' /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/build/Cactus/util/Misc.c:(.text+0x1dc): undefined reference to `regfreeA' /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/lib/libthorn_Cactus.a(Misc.c.o): In function `CCTK_SetStringInRegexList': /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/build/Cactus/util/Misc.c:(.text+0x6bc): undefined reference to `regcompA' /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/build/Cactus/util/Misc.c:(.text+0x6d7): undefined reference to `regexecA' /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/build/Cactus/util/Misc.c:(.text+0x6e7): undefined reference to `regfreeA' /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/lib/libthorn_Cactus.a(Misc.c.o): In function `Util_IntInRange': /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/build/Cactus/util/Misc.c:(.text+0xbca): undefined reference to `regcompA' /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/build/Cactus/util/Misc.c:(.text+0xc0b): undefined reference to `regexecA' /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/build/Cactus/util/Misc.c:(.text+0xc17): undefined reference to `regfreeA' /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/lib/libthorn_Cactus.a(Misc.c.o): In function `Util_DoubleInRange': /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/build/Cactus/util/Misc.c:(.text+0x111d): undefined reference to `regcompA' /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/build/Cactus/util/Misc.c:(.text+0x115e): undefined reference to `regexecA' /u/ap/kastaun/sim_build/pizza_dev/configs/pizza_dev/build/Cactus/util/Misc.c:(.text+0x116a): undefined reference to `regfreeA' make[1]: *** [/u/ap/kastaun/sim_build/pizza_dev/exe/cactus_pizza_dev] Error 1 make: *** [pizza_dev] Error 2
Hi,
On Wed, Jun 22, 2011 at 05:21:55PM +0200, Wolfgang Kastaun wrote:
During the configure stage, regexp.h was found on the system. I remember that Cactus has its own version of regexp, maybe there is a conflict.
Cactus has its own version in case there is non on a system. regexpA is a symbol from the boost library, so regex.h is probably used from the boost installation, but boost isn't linked in at link time. A solution probably involves either to make sure that this regex.h isn't used (did you specify to use boost, is boost in the INCLUDE_PATH?), or to make sure that the boost regex implementation is linked in (maybe -lboost_regex helps).
Frank
On Wed, 2011-06-22 at 11:23 -0500, Frank Loeffler wrote:
Hi,
On Wed, Jun 22, 2011 at 05:21:55PM +0200, Wolfgang Kastaun wrote:
During the configure stage, regexp.h was found on the system. I remember that Cactus has its own version of regexp, maybe there is a conflict.
Cactus has its own version in case there is non on a system. regexpA is a symbol from the boost library, so regex.h is probably used from the boost installation, but boost isn't linked in at link time. A solution probably involves either to make sure that this regex.h isn't used (did you specify to use boost, is boost in the INCLUDE_PATH?), or to make sure that the boost regex implementation is linked in (maybe -lboost_regex helps). Frank
Thanks, this explains it. Indeed, I had Boost in the include path to compile some of my thorns which use boost libraries (not regexp). Since I only use header-only components, I did not compile the boost libs, and I'd prefer not having to do this on every system without a boost installation, i.e. -lboost_regex would be inconvinient.
Is there a way to switch off the usage of Boost regexp without removing boost from the include path ? I didn't know that Cactus is Boost-aware. Are there configuration options like for GSL or HDF5 ?
Wolfgang.
Cactus is not Boost-aware.
Cactus checks during the configure stage whether the system provides a header file regex.h, and uses its own only if this is not the case. My guess is that this configure stage sees you Boost include path, and hence uses the Boost regex.h file.
It may be that you specify the include path to Boost in a way that is too general, i.e. in a way that is not specific to your thorn, but rather to all of Cactus.
Can you tell us more about your configure options?
You can e.g. copy the thorn GSL and thus create a Boost-awareness thorn.
-erik
On Wed, Jun 22, 2011 at 12:54 PM, Wolfgang Kastaun kastaun@sissa.it wrote:
On Wed, 2011-06-22 at 11:23 -0500, Frank Loeffler wrote:
Hi,
On Wed, Jun 22, 2011 at 05:21:55PM +0200, Wolfgang Kastaun wrote:
During the configure stage, regexp.h was found on the system. I remember that Cactus has its own version of regexp, maybe there is a conflict.
Cactus has its own version in case there is non on a system. regexpA is a symbol from the boost library, so regex.h is probably used from the boost installation, but boost isn't linked in at link time. A solution probably involves either to make sure that this regex.h isn't used (did you specify to use boost, is boost in the INCLUDE_PATH?), or to make sure that the boost regex implementation is linked in (maybe -lboost_regex helps). Frank
Thanks, this explains it. Indeed, I had Boost in the include path to compile some of my thorns which use boost libraries (not regexp). Since I only use header-only components, I did not compile the boost libs, and I'd prefer not having to do this on every system without a boost installation, i.e. -lboost_regex would be inconvinient.
Is there a way to switch off the usage of Boost regexp without removing boost from the include path ? I didn't know that Cactus is Boost-aware. Are there configuration options like for GSL or HDF5 ?
Wolfgang.
Users mailing list Users@einsteintoolkit.org http://lists.einsteintoolkit.org/mailman/listinfo/users
Hi Erik,
On Wed, 2011-06-22 at 13:34 -0400, Erik Schnetter wrote:
Cactus is not Boost-aware.
Cactus checks during the configure stage whether the system provides a header file regex.h, and uses its own only if this is not the case. My guess is that this configure stage sees you Boost include path, and hence uses the Boost regex.h file.
That would be strange:
I do have an entry -I /u/ap/kastaun/sim_build/boost_1_46_1 in my Cactus CPPFLAGS. However, _all_ header files reside in a subdirectory /u/ap/kastaun/sim_build/boost_1_46_1/boost To include the boost version of regex, one would need to write explicitly #include <boost/regex.h>
So if Cactus does not know about boost, I can't understand how any Cactus component can be influenced.
It may be that you specify the include path to Boost in a way that is too general, i.e. in a way that is not specific to your thorn, but rather to all of Cactus.
Adding the top boost directory (not the subdirectory with the actual headers) to the Cactus-wide include path should be pretty much equivalent to a system where Boost is installed system-wide. Note some distributions (Ubuntu) split boost into several packages, e.g. the components with compiled libraries are optional.
Can you tell us more about your configure options?
CC = icc CXX = icpc LD = icpc F90 = ifort F77 = ifort CPP = cpp FPP = cpp
CPPFLAGS = -DCARPET_INT -DCARPET_REAL -DCARPET_COMPLEX -DMPICH_IGNORE_CXX_SEEK -I /u/ap/kastaun/sim_build/boost_1_46_1
FPPFLAGS = -traditional
DEBUG = no OPTIMISE = yes
C_OPTIMISE_FLAGS = -xT -O3 -funroll-loops CXX_OPTIMISE_FLAGS = -xT -O3 -funroll-loops F90_OPTIMISE_FLAGS = -xT -O3 F77_OPTIMISE_FLAGS = -xT -O3
WARN = yes
HDF5 = yes HDF5_DIR = /opt/hdf5/1.8.5p1/gnu GSL = yes GSL_DIR = /opt/gsl/1.12/intel MPI = OpenMPI OPENMPI_DIR = /opt/openmpi/1.4.2/intel-10.1/ PTHREADS = no
You can e.g. copy the thorn GSL and thus create a Boost-awareness thorn.
Or I could finish my article..
Wolfgang.
-erik
On Wed, Jun 22, 2011 at 12:54 PM, Wolfgang Kastaun kastaun@sissa.it wrote:
On Wed, 2011-06-22 at 11:23 -0500, Frank Loeffler wrote:
Hi,
On Wed, Jun 22, 2011 at 05:21:55PM +0200, Wolfgang Kastaun wrote:
During the configure stage, regexp.h was found on the system. I remember that Cactus has its own version of regexp, maybe there is a conflict.
Cactus has its own version in case there is non on a system. regexpA is a symbol from the boost library, so regex.h is probably used from the boost installation, but boost isn't linked in at link time. A solution probably involves either to make sure that this regex.h isn't used (did you specify to use boost, is boost in the INCLUDE_PATH?), or to make sure that the boost regex implementation is linked in (maybe -lboost_regex helps). Frank
Thanks, this explains it. Indeed, I had Boost in the include path to compile some of my thorns which use boost libraries (not regexp). Since I only use header-only components, I did not compile the boost libs, and I'd prefer not having to do this on every system without a boost installation, i.e. -lboost_regex would be inconvinient.
Is there a way to switch off the usage of Boost regexp without removing boost from the include path ? I didn't know that Cactus is Boost-aware. Are there configuration options like for GSL or HDF5 ?
Wolfgang.
Users mailing list Users@einsteintoolkit.org http://lists.einsteintoolkit.org/mailman/listinfo/users
Hi Wolfgang,
On Wed, Jun 22, 2011 at 08:14:30PM +0200, Wolfgang Kastaun wrote:
Cactus checks during the configure stage whether the system provides a header file regex.h, and uses its own only if this is not the case. My guess is that this configure stage sees you Boost include path, and hence uses the Boost regex.h file.
That would be strange:
I do have an entry -I /u/ap/kastaun/sim_build/boost_1_46_1 in my Cactus CPPFLAGS. However, _all_ header files reside in a subdirectory /u/ap/kastaun/sim_build/boost_1_46_1/boost To include the boost version of regex, one would need to write explicitly #include <boost/regex.h>
I see. I assumed you do have /u/ap/kastaun/sim_build/boost_1_46_1/include in your INCLUDE_DIR environment variable, in which case it would be picked up by Cactus.
Cactus checks for the presence of regex.h using the autoconf tools, in particular by compiling
#include "confdefs.h" #include <stdio.h> #include <regex.h> int main() { return 0; ; return 0; }
This doesn't mention boost. It would be interesting to know which regex.h configure actually finds in your case, if it is the boost one, and if so, why.
Can you tell us more about your configure options?
They look fine. Can you also tell us about your environment, in particular INCLUDE_DIR ?
Frank
Cactus keeps track of include dependencies for make. You can look into the corresponding *.d file (in configs/.../build/Cactus) to see which regex.h was picked up.
-erik
Hi Wolfgang,
Doesn't this link failure occur randomly? I saw the same error occurring randomly (a few times a month) in my old machine. Only way to fix it was reinstalling whole Cactus directory. I hadn't noticed any system changes or user-level changes which could be relevant to the problem. Actually it was too weird to report it to other people.
Hee Il
They look fine. Can you also tell us about your environment, in particular INCLUDE_DIR ?
Frank
Problem solved, it compiles now. It turned out I forgot to unload the module for an outdated boost version already installed on the cluster.
INCLUDE_DIR was empty. However:
[kastaun@i909 ~]$ env | grep -i boost LD_LIBRARY_PATH=/opt/boost/1.33/lib64:/opt/openmpi/1.4.2/intel-10.1/lib:/opt/ofed/1.3.1-lustre1.6.5.1/lib64:/opt/libnuma/2.0.2/intel/lib64:/opt/gsl/1.12/intel/lib:/opt/hdf5/1.8.5p1/gnu/lib:/opt/intel/cce/10.1.018/lib:/opt/intel/fce/10.1.018/lib CPATH=/opt/boost/1.33/include _LMFILES_=/opt/Modules/3.2.6/compilers/intel/10.1:/opt/Modules/3.2.6/libraries/hdf5/1.8.5p1/gnu:/opt/Modules/3.2.6/libraries/gsl/1.12/intel:/opt/Modules/3.2.6/libraries/libnuma/2.0.2/intel:/opt/Modules/3.2.6/mpi/openmpi/1.4.2/intel/10.1:/opt/Modules/3.2.6/libraries/boost/1.33 LOADEDMODULES=intel/10.1:hdf5/1.8.5p1/gnu:gsl/1.12/intel:libnuma/2.0.2/intel:openmpi/1.4.2/intel/10.1:boost/1.33
In the directory $CPATH I found a boost version of regex.h, which had a line #include <boost/cregex.hpp>
This picked up the boost version I added via the cactus include path, which explains the mixed dependencies below.
Cactus keeps track of include dependencies for make. You can look into the corresponding *.d file (in configs/.../build/Cactus) to see which regex.h was picked up.
-erik
[kastaun@i909 Cactus]$ grep regex main/Parameters.c.d /opt/boost/1.33/include/regex.h \ /u/ap/kastaun/sim_build/boost_1_46_1/boost/cregex.hpp \ /u/ap/kastaun/sim_build/boost_1_46_1/boost/regex/config.hpp \ /u/ap/kastaun/sim_build/boost_1_46_1/boost/regex/v4/cregex.hpp \ /u/ap/kastaun/sim_build/boost_1_46_1/boost/regex/v4/match_flags.hpp \ /u/ap/kastaun/sim_build/boost_1_46_1/boost/regex/v4/error_type.hpp \
Anyway, after unloading the boost module, deleting the whole configuration, and starting from scratch, it compiled fine. My thorns used the boost version I specified via CPPFLAGS, without affecting the rest of Cactus.
Wolfgang.
Hi Wolfgang,
On Wed, Jun 22, 2011 at 06:54:40PM +0200, Wolfgang Kastaun wrote:
I'd prefer not having to do this on every system without a boost installation, i.e. -lboost_regex would be inconvinient.
I don't suggest to add this to your thorn, but rather to the configuration options for this machine. This way boost wouldn't be picked up on other systems, but would only be used there.
Is there a way to switch off the usage of Boost regexp without removing boost from the include path ?
I don't know of any. You should probably either not use boost in the include path (likely a problem if you actually use it), or specify to link against it as well.
Frank
On Wed, 2011-06-22 at 12:50 -0500, Frank Loeffler wrote:
Hi Wolfgang,
On Wed, Jun 22, 2011 at 06:54:40PM +0200, Wolfgang Kastaun wrote:
I'd prefer not having to do this on every system without a boost installation, i.e. -lboost_regex would be inconvinient.
I don't suggest to add this to your thorn, but rather to the configuration options for this machine. This way boost wouldn't be picked up on other systems, but would only be used there.
That's not what I meant, It's just that in order to use -lboost_regex, I need to compile boost, which is unnecessary since my thorns only use the header-only libs. Additionally, if Cactus suddenly using the boost version of regexp calls for trouble.
Wolfgang.
Is there a way to switch off the usage of Boost regexp without removing boost from the include path ?
I don't know of any. You should probably either not use boost in the include path (likely a problem if you actually use it), or specify to link against it as well.
Frank
users@lists.einsteintoolkit.org