Hi,
compiling ALPS on SuSE 11.4 crashes with errors as listed at the end of this mail. [gcc version 4.5.1 20101208 [gcc-4_5-branch revision 167585] (SUSE Linux), kernel 2.6.37.1-1.2-desktop]
The err msgs seem to point to the 'TIME' typename in a bunch of header files in alps_whatever/applications/qmc/looper/looper, namely in
correlation.h susceptibility.h measurement.h custom.h operator.h stiffness.h
Indeed, simply changing 'TIME' in these headers into something else, say 'MyTIME', does away with the compile error. However if this fix will induce other errors at run-time, I don't know?
Does anybody have a clue on this?
Wolfram Brenig
PS.: Actually, there seems to be a somehow similar issue with VTK, over which I stumbled while compiling it prior to vistrails, and which seems to have bugged also others: http://comments.gmane.org/gmane.comp.lib.vtk.user/55300
compile errs:--------------------------------------------
[ 49%] Building CXX object applications/qmc/looper/CMakeFiles/loop.dir/loop_custom.C.o cd /home/userxx/temporary/alpsbuilt/applications/qmc/looper && /usr/bin/c++ -O3 -march=core2 -DNDEBUG -I/usr/local/include -I/usr/lib64/python2.7/site-packages/numpy/core/include -I/usr/include/python2.7 -I/home/userxx/temporary/alpsbuilt/src -I/home/userxx/temporary/alps/src -I/home/userxx/temporary/alps/applications/qmc/looper -o CMakeFiles/loop.dir/loop_custom.C.o -c /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C In file included from /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:29:0, from /home/userxx/temporary/alps/applications/qmc/looper/loop_config.h:38, from /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C:26: /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:182:72: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:182:72: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:418:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:418:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:422:13: error: expected unqualified-id before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:483:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:483:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:490:13: error: expected unqualified-id before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:491:49: error: type/value mismatch at argument 3 in template parameter list for ‘template<class MEASUREMENT1, class MEASUREMENT2> template<class MC, class LAT, int <anonymous> > struct looper::composite_measurement<M1, M2>::estimator’ /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:491:49: error: expected a constant of type ‘int’, got ‘time_t’ In file included from /home/userxx/temporary/alps/applications/qmc/looper/loop_config.h:38:0, from /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C:26: /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:37:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:37:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:41:13: error: expected unqualified-id before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:136:60: error: ‘"16:54:59"’ is not a valid template argument for type ‘int’ because string literals can never be used in this context /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:136:61: error: ‘<declaration error>’ is not a template /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:139:60: error: ‘"16:54:59"’ is not a valid template argument for type ‘int’ because string literals can never be used in this context /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:139:61: error: ‘<declaration error>’ is not a template In file included from /home/userxx/temporary/alps/applications/qmc/looper/loop_config.h:39:0, from /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C:26: /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:63:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:63:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:127:60: error: ‘"16:54:59"’ is not a valid template argument for type ‘int’ because string literals can never be used in this context /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:127:61: error: ‘<declaration error>’ is not a template /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:130:60: error: ‘"16:54:59"’ is not a valid template argument for type ‘int’ because string literals can never be used in this context /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:130:61: error: ‘<declaration error>’ is not a template In file included from /home/userxx/temporary/alps/applications/qmc/looper/loop_config.h:40:0, from /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C:26: /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:40:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:40:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:45:13: error: expected unqualified-id before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:46:49: error: type/value mismatch at argument 3 in template parameter list for ‘template<unsigned int MAX_DIM> template<class MC, class LAT, int <anonymous> > struct looper::stiffness<MAX_DIM>::estimator’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:46:49: error: expected a constant of type ‘int’, got ‘time_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h: In member function ‘void looper::stiffness<MAX_DIM>::estimator<MC, LAT, <anonymous> >::estimate::begin_bs(const looper::stiffness::estimator::estimator_t&, const lattice_t&, double, int, int, int)’: /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:98:15: error: request for member ‘bond_vector_relative’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:98:40: error: request for member ‘real_bond’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:99:33: error: request for member ‘dim’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h: In member function ‘void looper::stiffness<MAX_DIM>::estimator<MC, LAT, <anonymous> >::estimate::end_bs(const looper::stiffness::estimator::estimator_t&, const lattice_t&, double, int, int, int)’: /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:105:15: error: request for member ‘bond_vector_relative’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:105:40: error: request for member ‘real_bond’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:106:33: error: request for member ‘dim’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ In file included from /home/userxx/temporary/alps/applications/qmc/looper/loop_config.h:41:0, from /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C:26: /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h: At global scope: /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:37:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:37:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:41:13: error: expected unqualified-id before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:42:49: error: type/value mismatch at argument 3 in template parameter list for ‘template<class MC, class LAT, int <anonymous> > struct looper::susceptibility::estimator’ /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:42:49: error: expected a constant of type ‘int’, got ‘time_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h: In member function ‘void looper::susceptibility::estimator<MC, LAT, <anonymous> >::estimate::end_s(const looper::susceptibility::estimator::estimator_t&, const lattice_t&, double, int, int)’: /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:128:25: error: request for member ‘gauge’ in ‘emt’, which is of non-class type ‘const looper::susceptibility::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h: In member function ‘void looper::susceptibility::estimator<MC, LAT, <anonymous> >::estimate::start_bottom(const looper::susceptibility::estimator::estimator_t&, const lattice_t&, double, int, int)’: /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:140:25: error: request for member ‘gauge’ in ‘emt’, which is of non-class type ‘const looper::susceptibility::estimator::estimator_t’ make[2]: *** [applications/qmc/looper/CMakeFiles/loop.dir/loop_custom.C.o] Error 1 make[2]: Leaving directory `/home/userxx/temporary/alpsbuilt' make[1]: *** [applications/qmc/looper/CMakeFiles/loop.dir/all] Error 2 make[1]: Leaving directory `/home/userxx/temporary/alpsbuilt' make: *** [all] Error 2
Dear Wolfram,
Thank you for your report. I suspect that a harmful macro TIME is defined on SUSE.
Could you try to insert the following lines
#ifdef TIME # undef TIME #endif
in the header files and see if the error is fixed?
Best, Synge
On 2011/04/18, at 21:15, Wolfram Brenig wrote:
Hi,
compiling ALPS on SuSE 11.4 crashes with errors as listed at the end of this mail. [gcc version 4.5.1 20101208 [gcc-4_5-branch revision 167585] (SUSE Linux), kernel 2.6.37.1-1.2-desktop]
The err msgs seem to point to the 'TIME' typename in a bunch of header files in alps_whatever/applications/qmc/looper/looper, namely in
correlation.h susceptibility.h measurement.h custom.h operator.h stiffness.h
Indeed, simply changing 'TIME' in these headers into something else, say 'MyTIME', does away with the compile error. However if this fix will induce other errors at run-time, I don't know?
Does anybody have a clue on this?
Wolfram Brenig
PS.: Actually, there seems to be a somehow similar issue with VTK, over which I stumbled while compiling it prior to vistrails, and which seems to have bugged also others: http://comments.gmane.org/gmane.comp.lib.vtk.user/55300
compile errs:--------------------------------------------
[ 49%] Building CXX object applications/qmc/looper/CMakeFiles/loop.dir/loop_custom.C.o cd /home/userxx/temporary/alpsbuilt/applications/qmc/looper && /usr/bin/c++ -O3 -march=core2 -DNDEBUG -I/usr/local/include -I/usr/lib64/python2.7/site-packages/numpy/core/include -I/usr/include/python2.7 -I/home/userxx/temporary/alpsbuilt/src -I/home/userxx/temporary/alps/src -I/home/userxx/temporary/alps/applications/qmc/looper -o CMakeFiles/loop.dir/loop_custom.C.o -c /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C In file included from /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:29:0, from /home/userxx/temporary/alps/applications/qmc/looper/loop_config.h:38, from /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C:26: /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:182:72: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:182:72: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:418:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:418:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:422:13: error: expected unqualified-id before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:483:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:483:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:490:13: error: expected unqualified-id before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:491:49: error: type/value mismatch at argument 3 in template parameter list for ‘template<class MEASUREMENT1, class MEASUREMENT2> template<class MC, class LAT, int <anonymous> > struct looper::composite_measurement<M1, M2>::estimator’ /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:491:49: error: expected a constant of type ‘int’, got ‘time_t’ In file included from /home/userxx/temporary/alps/applications/qmc/looper/loop_config.h:38:0, from /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C:26: /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:37:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:37:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:41:13: error: expected unqualified-id before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:136:60: error: ‘"16:54:59"’ is not a valid template argument for type ‘int’ because string literals can never be used in this context /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:136:61: error: ‘<declaration error>’ is not a template /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:139:60: error: ‘"16:54:59"’ is not a valid template argument for type ‘int’ because string literals can never be used in this context /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:139:61: error: ‘<declaration error>’ is not a template In file included from /home/userxx/temporary/alps/applications/qmc/looper/loop_config.h:39:0, from /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C:26: /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:63:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:63:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:127:60: error: ‘"16:54:59"’ is not a valid template argument for type ‘int’ because string literals can never be used in this context /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:127:61: error: ‘<declaration error>’ is not a template /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:130:60: error: ‘"16:54:59"’ is not a valid template argument for type ‘int’ because string literals can never be used in this context /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:130:61: error: ‘<declaration error>’ is not a template In file included from /home/userxx/temporary/alps/applications/qmc/looper/loop_config.h:40:0, from /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C:26: /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:40:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:40:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:45:13: error: expected unqualified-id before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:46:49: error: type/value mismatch at argument 3 in template parameter list for ‘template<unsigned int MAX_DIM> template<class MC, class LAT, int <anonymous> > struct looper::stiffness<MAX_DIM>::estimator’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:46:49: error: expected a constant of type ‘int’, got ‘time_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h: In member function ‘void looper::stiffness<MAX_DIM>::estimator<MC, LAT, <anonymous> >::estimate::begin_bs(const looper::stiffness::estimator::estimator_t&, const lattice_t&, double, int, int, int)’: /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:98:15: error: request for member ‘bond_vector_relative’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:98:40: error: request for member ‘real_bond’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:99:33: error: request for member ‘dim’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h: In member function ‘void looper::stiffness<MAX_DIM>::estimator<MC, LAT, <anonymous> >::estimate::end_bs(const looper::stiffness::estimator::estimator_t&, const lattice_t&, double, int, int, int)’: /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:105:15: error: request for member ‘bond_vector_relative’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:105:40: error: request for member ‘real_bond’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:106:33: error: request for member ‘dim’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ In file included from /home/userxx/temporary/alps/applications/qmc/looper/loop_config.h:41:0, from /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C:26: /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h: At global scope: /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:37:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:37:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:41:13: error: expected unqualified-id before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:42:49: error: type/value mismatch at argument 3 in template parameter list for ‘template<class MC, class LAT, int <anonymous> > struct looper::susceptibility::estimator’ /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:42:49: error: expected a constant of type ‘int’, got ‘time_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h: In member function ‘void looper::susceptibility::estimator<MC, LAT, <anonymous> >::estimate::end_s(const looper::susceptibility::estimator::estimator_t&, const lattice_t&, double, int, int)’: /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:128:25: error: request for member ‘gauge’ in ‘emt’, which is of non-class type ‘const looper::susceptibility::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h: In member function ‘void looper::susceptibility::estimator<MC, LAT, <anonymous> >::estimate::start_bottom(const looper::susceptibility::estimator::estimator_t&, const lattice_t&, double, int, int)’: /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:140:25: error: request for member ‘gauge’ in ‘emt’, which is of non-class type ‘const looper::susceptibility::estimator::estimator_t’ make[2]: *** [applications/qmc/looper/CMakeFiles/loop.dir/loop_custom.C.o] Error 1 make[2]: Leaving directory `/home/userxx/temporary/alpsbuilt' make[1]: *** [applications/qmc/looper/CMakeFiles/loop.dir/all] Error 2 make[1]: Leaving directory `/home/userxx/temporary/alpsbuilt' make: *** [all] Error 2
Hi Synge,
I checked with
CMAKE_VERBOSE_MAKEFILE ON
for the include files of loop_custom.C and then with
find include_dirs -name '*' -exec grep -l ' TIME ' '{}' ;
on the relevant directories which might be the 'sinner'. And I found it. It is
pyconfig.h
The final few lines of my systems pyconfig.h are:
#endif /*Py_PYCONFIG_H*/
#define COMPILER "[GCC]" #define DATE "Aug 07 2010" #define TIME "16:54:59" <----- Here we go
If I comment away this #define TIME, then ALPS compiles with the original typename TIME in the looper headers.
I have no idea if these #defines are SuSE specific or not? Most pyconfig.h's I've seen end with #endif /*Py_PYCONFIG_H*/
Moreover I have no idea if one is actually allowed to comment these #defines away on a given vendors distribution.
Best, Wolfram
On 04/19/2011 10:38 AM, Synge Todo wrote:
Dear Wolfram,
Thank you for your report. I suspect that a harmful macro TIME is defined on SUSE.
Could you try to insert the following lines
#ifdef TIME # undef TIME #endif
in the header files and see if the error is fixed?
Best, Synge
On 2011/04/18, at 21:15, Wolfram Brenig wrote:
Hi,
compiling ALPS on SuSE 11.4 crashes with errors as listed at the end of this mail. [gcc version 4.5.1 20101208 [gcc-4_5-branch revision 167585] (SUSE Linux), kernel 2.6.37.1-1.2-desktop]
The err msgs seem to point to the 'TIME' typename in a bunch of header files in alps_whatever/applications/qmc/looper/looper, namely in
correlation.h susceptibility.h measurement.h custom.h operator.h stiffness.h
Indeed, simply changing 'TIME' in these headers into something else, say 'MyTIME', does away with the compile error. However if this fix will induce other errors at run-time, I don't know?
Does anybody have a clue on this?
Wolfram Brenig
PS.: Actually, there seems to be a somehow similar issue with VTK, over which I stumbled while compiling it prior to vistrails, and which seems to have bugged also others: http://comments.gmane.org/gmane.comp.lib.vtk.user/55300
compile errs:--------------------------------------------
[ 49%] Building CXX object applications/qmc/looper/CMakeFiles/loop.dir/loop_custom.C.o cd /home/userxx/temporary/alpsbuilt/applications/qmc/looper&& /usr/bin/c++ -O3 -march=core2 -DNDEBUG -I/usr/local/include -I/usr/lib64/python2.7/site-packages/numpy/core/include -I/usr/include/python2.7 -I/home/userxx/temporary/alpsbuilt/src -I/home/userxx/temporary/alps/src -I/home/userxx/temporary/alps/applications/qmc/looper -o CMakeFiles/loop.dir/loop_custom.C.o -c /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C In file included from /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:29:0, from /home/userxx/temporary/alps/applications/qmc/looper/loop_config.h:38, from /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C:26: /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:182:72: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:182:72: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:418:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:418:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:422:13: error: expected unqualified-id before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:483:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:483:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:490:13: error: expected unqualified-id before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:491:49: error: type/value mismatch at argument 3 in template parameter list for ‘template<class MEASUREMENT1, class MEASUREMENT2> template<class MC, class LAT, int<anonymous> > struct looper::composite_measurement<M1, M2>::estimator’ /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:491:49: error: expected a constant of type ‘int’, got ‘time_t’ In file included from /home/userxx/temporary/alps/applications/qmc/looper/loop_config.h:38:0, from /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C:26: /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:37:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:37:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:41:13: error: expected unqualified-id before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:136:60: error: ‘"16:54:59"’ is not a valid template argument for type ‘int’ because string literals can never be used in this context /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:136:61: error: ‘<declaration error>’ is not a template /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:139:60: error: ‘"16:54:59"’ is not a valid template argument for type ‘int’ because string literals can never be used in this context /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:139:61: error: ‘<declaration error>’ is not a template In file included from /home/userxx/temporary/alps/applications/qmc/looper/loop_config.h:39:0, from /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C:26: /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:63:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:63:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:127:60: error: ‘"16:54:59"’ is not a valid template argument for type ‘int’ because string literals can never be used in this context /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:127:61: error: ‘<declaration error>’ is not a template /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:130:60: error: ‘"16:54:59"’ is not a valid template argument for type ‘int’ because string literals can never be used in this context /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:130:61: error: ‘<declaration error>’ is not a template In file included from /home/userxx/temporary/alps/applications/qmc/looper/loop_config.h:40:0, from /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C:26: /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:40:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:40:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:45:13: error: expected unqualified-id before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:46:49: error: type/value mismatch at argument 3 in template parameter list for ‘template<unsigned int MAX_DIM> template<class MC, class LAT, int <anonymous> > struct looper::stiffness<MAX_DIM>::estimator’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:46:49: error: expected a constant of type ‘int’, got ‘time_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h: In member function ‘void looper::stiffness<MAX_DIM>::estimator<MC, LAT, <anonymous> >::estimate::begin_bs(const looper::stiffness::estimator::estimator_t&, const lattice_t&, double, int, int, int)’: /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:98:15: error: request for member ‘bond_vector_relative’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:98:40: error: request for member ‘real_bond’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:99:33: error: request for member ‘dim’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h: In member function ‘void looper::stiffness<MAX_DIM>::estimator<MC, LAT, <anonymous> >::estimate::end_bs(const looper::stiffness::estimator::estimator_t&, const lattice_t&, double, int, int, int)’: /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:105:15: error: request for member ‘bond_vector_relative’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:105:40: error: request for member ‘real_bond’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:106:33: error: request for member ‘dim’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ In file included from /home/userxx/temporary/alps/applications/qmc/looper/loop_config.h:41:0, from /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C:26: /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h: At global scope: /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:37:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:37:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:41:13: error: expected unqualified-id before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:42:49: error: type/value mismatch at argument 3 in template parameter list for ‘template<class MC, class LAT, int<anonymous> > struct looper::susceptibility::estimator’ /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:42:49: error: expected a constant of type ‘int’, got ‘time_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h: In member function ‘void looper::susceptibility::estimator<MC, LAT, <anonymous> >::estimate::end_s(const looper::susceptibility::estimator::estimator_t&, const lattice_t&, double, int, int)’: /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:128:25: error: request for member ‘gauge’ in ‘emt’, which is of non-class type ‘const looper::susceptibility::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h: In member function ‘void looper::susceptibility::estimator<MC, LAT, <anonymous> >::estimate::start_bottom(const looper::susceptibility::estimator::estimator_t&, const lattice_t&, double, int, int)’: /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:140:25: error: request for member ‘gauge’ in ‘emt’, which is of non-class type ‘const looper::susceptibility::estimator::estimator_t’ make[2]: *** [applications/qmc/looper/CMakeFiles/loop.dir/loop_custom.C.o] Error 1 make[2]: Leaving directory `/home/userxx/temporary/alpsbuilt' make[1]: *** [applications/qmc/looper/CMakeFiles/loop.dir/all] Error 2 make[1]: Leaving directory `/home/userxx/temporary/alpsbuilt' make: *** [all] Error 2
Dear Wolfram,
Thank you for your report. I've just applied the attached fix on the trunk, which will be reflected to the next nightly snapshot of ALPS.
Best regards, Synge
On 2011/04/19, at 22:46, Wolfram Brenig wrote:
Hi Synge,
I checked with
CMAKE_VERBOSE_MAKEFILE ON
for the include files of loop_custom.C and then with
find include_dirs -name '*' -exec grep -l ' TIME ' '{}' ;
on the relevant directories which might be the 'sinner'. And I found it. It is
pyconfig.h
The final few lines of my systems pyconfig.h are:
#endif /*Py_PYCONFIG_H*/
#define COMPILER "[GCC]" #define DATE "Aug 07 2010" #define TIME "16:54:59" <----- Here we go
If I comment away this #define TIME, then ALPS compiles with the original typename TIME in the looper headers.
I have no idea if these #defines are SuSE specific or not? Most pyconfig.h's I've seen end with #endif /*Py_PYCONFIG_H*/
Moreover I have no idea if one is actually allowed to comment these #defines away on a given vendors distribution.
Best, Wolfram
On 04/19/2011 10:38 AM, Synge Todo wrote:
Dear Wolfram,
Thank you for your report. I suspect that a harmful macro TIME is defined on SUSE.
Could you try to insert the following lines
#ifdef TIME # undef TIME #endif
in the header files and see if the error is fixed?
Best, Synge
On 2011/04/18, at 21:15, Wolfram Brenig wrote:
Hi,
compiling ALPS on SuSE 11.4 crashes with errors as listed at the end of this mail. [gcc version 4.5.1 20101208 [gcc-4_5-branch revision 167585] (SUSE Linux), kernel 2.6.37.1-1.2-desktop]
The err msgs seem to point to the 'TIME' typename in a bunch of header files in alps_whatever/applications/qmc/looper/looper, namely in
correlation.h susceptibility.h measurement.h custom.h operator.h stiffness.h
Indeed, simply changing 'TIME' in these headers into something else, say 'MyTIME', does away with the compile error. However if this fix will induce other errors at run-time, I don't know?
Does anybody have a clue on this?
Wolfram Brenig
PS.: Actually, there seems to be a somehow similar issue with VTK, over which I stumbled while compiling it prior to vistrails, and which seems to have bugged also others: http://comments.gmane.org/gmane.comp.lib.vtk.user/55300
compile errs:--------------------------------------------
[ 49%] Building CXX object applications/qmc/looper/CMakeFiles/loop.dir/loop_custom.C.o cd /home/userxx/temporary/alpsbuilt/applications/qmc/looper&& /usr/bin/c++ -O3 -march=core2 -DNDEBUG -I/usr/local/include -I/usr/lib64/python2.7/site-packages/numpy/core/include -I/usr/include/python2.7 -I/home/userxx/temporary/alpsbuilt/src -I/home/userxx/temporary/alps/src -I/home/userxx/temporary/alps/applications/qmc/looper -o CMakeFiles/loop.dir/loop_custom.C.o -c /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C In file included from /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:29:0, from /home/userxx/temporary/alps/applications/qmc/looper/loop_config.h:38, from /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C:26: /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:182:72: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:182:72: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:418:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:418:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:422:13: error: expected unqualified-id before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:483:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:483:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:490:13: error: expected unqualified-id before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:491:49: error: type/value mismatch at argument 3 in template parameter list for ‘template<class MEASUREMENT1, class MEASUREMENT2> template<class MC, class LAT, int<anonymous> > struct looper::composite_measurement<M1, M2>::estimator’ /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:491:49: error: expected a constant of type ‘int’, got ‘time_t’ In file included from /home/userxx/temporary/alps/applications/qmc/looper/loop_config.h:38:0, from /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C:26: /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:37:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:37:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:41:13: error: expected unqualified-id before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:136:60: error: ‘"16:54:59"’ is not a valid template argument for type ‘int’ because string literals can never be used in this context /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:136:61: error: ‘<declaration error>’ is not a template /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:139:60: error: ‘"16:54:59"’ is not a valid template argument for type ‘int’ because string literals can never be used in this context /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:139:61: error: ‘<declaration error>’ is not a template In file included from /home/userxx/temporary/alps/applications/qmc/looper/loop_config.h:39:0, from /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C:26: /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:63:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:63:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:127:60: error: ‘"16:54:59"’ is not a valid template argument for type ‘int’ because string literals can never be used in this context /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:127:61: error: ‘<declaration error>’ is not a template /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:130:60: error: ‘"16:54:59"’ is not a valid template argument for type ‘int’ because string literals can never be used in this context /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:130:61: error: ‘<declaration error>’ is not a template In file included from /home/userxx/temporary/alps/applications/qmc/looper/loop_config.h:40:0, from /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C:26: /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:40:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:40:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:45:13: error: expected unqualified-id before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:46:49: error: type/value mismatch at argument 3 in template parameter list for ‘template<unsigned int MAX_DIM> template<class MC, class LAT, int <anonymous> > struct looper::stiffness<MAX_DIM>::estimator’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:46:49: error: expected a constant of type ‘int’, got ‘time_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h: In member function ‘void looper::stiffness<MAX_DIM>::estimator<MC, LAT, <anonymous> >::estimate::begin_bs(const looper::stiffness::estimator::estimator_t&, const lattice_t&, double, int, int, int)’: /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:98:15: error: request for member ‘bond_vector_relative’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:98:40: error: request for member ‘real_bond’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:99:33: error: request for member ‘dim’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h: In member function ‘void looper::stiffness<MAX_DIM>::estimator<MC, LAT, <anonymous> >::estimate::end_bs(const looper::stiffness::estimator::estimator_t&, const lattice_t&, double, int, int, int)’: /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:105:15: error: request for member ‘bond_vector_relative’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:105:40: error: request for member ‘real_bond’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:106:33: error: request for member ‘dim’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ In file included from /home/userxx/temporary/alps/applications/qmc/looper/loop_config.h:41:0, from /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C:26: /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h: At global scope: /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:37:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:37:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:41:13: error: expected unqualified-id before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:42:49: error: type/value mismatch at argument 3 in template parameter list for ‘template<class MC, class LAT, int<anonymous> > struct looper::susceptibility::estimator’ /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:42:49: error: expected a constant of type ‘int’, got ‘time_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h: In member function ‘void looper::susceptibility::estimator<MC, LAT, <anonymous> >::estimate::end_s(const looper::susceptibility::estimator::estimator_t&, const lattice_t&, double, int, int)’: /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:128:25: error: request for member ‘gauge’ in ‘emt’, which is of non-class type ‘const looper::susceptibility::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h: In member function ‘void looper::susceptibility::estimator<MC, LAT, <anonymous> >::estimate::start_bottom(const looper::susceptibility::estimator::estimator_t&, const lattice_t&, double, int, int)’: /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:140:25: error: request for member ‘gauge’ in ‘emt’, which is of non-class type ‘const looper::susceptibility::estimator::estimator_t’ make[2]: *** [applications/qmc/looper/CMakeFiles/loop.dir/loop_custom.C.o] Error 1 make[2]: Leaving directory `/home/userxx/temporary/alpsbuilt' make[1]: *** [applications/qmc/looper/CMakeFiles/loop.dir/all] Error 2 make[1]: Leaving directory `/home/userxx/temporary/alpsbuilt' make: *** [all] Error 2
-- __________________________________________________________ Univ. Prof. Dr. Wolfram Brenig Institute for Theoretical Physics Technical University Braunschweig and NTH Lower Saxony Mendelssohnstr. 3 38106 Braunschweig GERMANY
Tel: +49 531 391 5180/81 FAX: +49 531 391 5833 Mobile: upon request Email: w.brenig@tu-bs.de WWW: http://www.fkt.tu-bs.de PGPkey: http://www.fkt.tu-bs.de/brenig/wbpubkey.shtml
Synge, can you please also apply it to the 2.0.1 branch?
Matthias
On Apr 20, 2011, at 10:06 AM, Synge Todo wrote:
Dear Wolfram,
Thank you for your report. I've just applied the attached fix on the trunk, which will be reflected to the next nightly snapshot of ALPS.
Best regards, Synge
On 2011/04/19, at 22:46, Wolfram Brenig wrote:
Hi Synge,
I checked with
CMAKE_VERBOSE_MAKEFILE ON
for the include files of loop_custom.C and then with
find include_dirs -name '*' -exec grep -l ' TIME ' '{}' ;
on the relevant directories which might be the 'sinner'. And I found it. It is
pyconfig.h
The final few lines of my systems pyconfig.h are:
#endif /*Py_PYCONFIG_H*/
#define COMPILER "[GCC]" #define DATE "Aug 07 2010" #define TIME "16:54:59" <----- Here we go
If I comment away this #define TIME, then ALPS compiles with the original typename TIME in the looper headers.
I have no idea if these #defines are SuSE specific or not? Most pyconfig.h's I've seen end with #endif /*Py_PYCONFIG_H*/
Moreover I have no idea if one is actually allowed to comment these #defines away on a given vendors distribution.
Best, Wolfram
On 04/19/2011 10:38 AM, Synge Todo wrote:
Dear Wolfram,
Thank you for your report. I suspect that a harmful macro TIME is defined on SUSE.
Could you try to insert the following lines
#ifdef TIME # undef TIME #endif
in the header files and see if the error is fixed?
Best, Synge
On 2011/04/18, at 21:15, Wolfram Brenig wrote:
Hi,
compiling ALPS on SuSE 11.4 crashes with errors as listed at the end of this mail. [gcc version 4.5.1 20101208 [gcc-4_5-branch revision 167585] (SUSE Linux), kernel 2.6.37.1-1.2-desktop]
The err msgs seem to point to the 'TIME' typename in a bunch of header files in alps_whatever/applications/qmc/looper/looper, namely in
correlation.h susceptibility.h measurement.h custom.h operator.h stiffness.h
Indeed, simply changing 'TIME' in these headers into something else, say 'MyTIME', does away with the compile error. However if this fix will induce other errors at run-time, I don't know?
Does anybody have a clue on this?
Wolfram Brenig
PS.: Actually, there seems to be a somehow similar issue with VTK, over which I stumbled while compiling it prior to vistrails, and which seems to have bugged also others: http://comments.gmane.org/gmane.comp.lib.vtk.user/55300
compile errs:--------------------------------------------
[ 49%] Building CXX object applications/qmc/looper/CMakeFiles/loop.dir/loop_custom.C.o cd /home/userxx/temporary/alpsbuilt/applications/qmc/looper&& /usr/bin/c++ -O3 -march=core2 -DNDEBUG -I/usr/local/include -I/usr/lib64/python2.7/site-packages/numpy/core/include -I/usr/include/python2.7 -I/home/userxx/temporary/alpsbuilt/src -I/home/userxx/temporary/alps/src -I/home/userxx/temporary/alps/applications/qmc/looper -o CMakeFiles/loop.dir/loop_custom.C.o -c /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C In file included from /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:29:0, from /home/userxx/temporary/alps/applications/qmc/looper/loop_config.h:38, from /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C:26: /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:182:72: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:182:72: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:418:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:418:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:422:13: error: expected unqualified-id before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:483:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:483:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:490:13: error: expected unqualified-id before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:491:49: error: type/value mismatch at argument 3 in template parameter list for ‘template<class MEASUREMENT1, class MEASUREMENT2> template<class MC, class LAT, int<anonymous> > struct looper::composite_measurement<M1, M2>::estimator’ /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:491:49: error: expected a constant of type ‘int’, got ‘time_t’ In file included from /home/userxx/temporary/alps/applications/qmc/looper/loop_config.h:38:0, from /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C:26: /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:37:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:37:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:41:13: error: expected unqualified-id before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:136:60: error: ‘"16:54:59"’ is not a valid template argument for type ‘int’ because string literals can never be used in this context /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:136:61: error: ‘<declaration error>’ is not a template /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:139:60: error: ‘"16:54:59"’ is not a valid template argument for type ‘int’ because string literals can never be used in this context /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:139:61: error: ‘<declaration error>’ is not a template In file included from /home/userxx/temporary/alps/applications/qmc/looper/loop_config.h:39:0, from /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C:26: /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:63:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:63:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:127:60: error: ‘"16:54:59"’ is not a valid template argument for type ‘int’ because string literals can never be used in this context /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:127:61: error: ‘<declaration error>’ is not a template /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:130:60: error: ‘"16:54:59"’ is not a valid template argument for type ‘int’ because string literals can never be used in this context /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:130:61: error: ‘<declaration error>’ is not a template In file included from /home/userxx/temporary/alps/applications/qmc/looper/loop_config.h:40:0, from /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C:26: /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:40:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:40:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:45:13: error: expected unqualified-id before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:46:49: error: type/value mismatch at argument 3 in template parameter list for ‘template<unsigned int MAX_DIM> template<class MC, class LAT, int <anonymous> > struct looper::stiffness<MAX_DIM>::estimator’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:46:49: error: expected a constant of type ‘int’, got ‘time_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h: In member function ‘void looper::stiffness<MAX_DIM>::estimator<MC, LAT, <anonymous> >::estimate::begin_bs(const looper::stiffness::estimator::estimator_t&, const lattice_t&, double, int, int, int)’: /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:98:15: error: request for member ‘bond_vector_relative’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:98:40: error: request for member ‘real_bond’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:99:33: error: request for member ‘dim’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h: In member function ‘void looper::stiffness<MAX_DIM>::estimator<MC, LAT, <anonymous> >::estimate::end_bs(const looper::stiffness::estimator::estimator_t&, const lattice_t&, double, int, int, int)’: /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:105:15: error: request for member ‘bond_vector_relative’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:105:40: error: request for member ‘real_bond’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:106:33: error: request for member ‘dim’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ In file included from /home/userxx/temporary/alps/applications/qmc/looper/loop_config.h:41:0, from /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C:26: /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h: At global scope: /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:37:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:37:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:41:13: error: expected unqualified-id before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:42:49: error: type/value mismatch at argument 3 in template parameter list for ‘template<class MC, class LAT, int<anonymous> > struct looper::susceptibility::estimator’ /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:42:49: error: expected a constant of type ‘int’, got ‘time_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h: In member function ‘void looper::susceptibility::estimator<MC, LAT, <anonymous> >::estimate::end_s(const looper::susceptibility::estimator::estimator_t&, const lattice_t&, double, int, int)’: /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:128:25: error: request for member ‘gauge’ in ‘emt’, which is of non-class type ‘const looper::susceptibility::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h: In member function ‘void looper::susceptibility::estimator<MC, LAT, <anonymous> >::estimate::start_bottom(const looper::susceptibility::estimator::estimator_t&, const lattice_t&, double, int, int)’: /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:140:25: error: request for member ‘gauge’ in ‘emt’, which is of non-class type ‘const looper::susceptibility::estimator::estimator_t’ make[2]: *** [applications/qmc/looper/CMakeFiles/loop.dir/loop_custom.C.o] Error 1 make[2]: Leaving directory `/home/userxx/temporary/alpsbuilt' make[1]: *** [applications/qmc/looper/CMakeFiles/loop.dir/all] Error 2 make[1]: Leaving directory `/home/userxx/temporary/alpsbuilt' make: *** [all] Error 2
-- __________________________________________________________ Univ. Prof. Dr. Wolfram Brenig Institute for Theoretical Physics Technical University Braunschweig and NTH Lower Saxony Mendelssohnstr. 3 38106 Braunschweig GERMANY
Tel: +49 531 391 5180/81 FAX: +49 531 391 5833 Mobile: upon request Email: w.brenig@tu-bs.de WWW: http://www.fkt.tu-bs.de PGPkey: http://www.fkt.tu-bs.de/brenig/wbpubkey.shtml
<alps-r5531-5532.diff>
Done in [5534].
Synge
On 2011/04/20, at 17:48, Matthias Troyer wrote:
Synge, can you please also apply it to the 2.0.1 branch?
Matthias
On Apr 20, 2011, at 10:06 AM, Synge Todo wrote:
Dear Wolfram,
Thank you for your report. I've just applied the attached fix on the trunk, which will be reflected to the next nightly snapshot of ALPS.
Best regards, Synge
On 2011/04/19, at 22:46, Wolfram Brenig wrote:
Hi Synge,
I checked with
CMAKE_VERBOSE_MAKEFILE ON
for the include files of loop_custom.C and then with
find include_dirs -name '*' -exec grep -l ' TIME ' '{}' ;
on the relevant directories which might be the 'sinner'. And I found it. It is
pyconfig.h
The final few lines of my systems pyconfig.h are:
#endif /*Py_PYCONFIG_H*/
#define COMPILER "[GCC]" #define DATE "Aug 07 2010" #define TIME "16:54:59" <----- Here we go
If I comment away this #define TIME, then ALPS compiles with the original typename TIME in the looper headers.
I have no idea if these #defines are SuSE specific or not? Most pyconfig.h's I've seen end with #endif /*Py_PYCONFIG_H*/
Moreover I have no idea if one is actually allowed to comment these #defines away on a given vendors distribution.
Best, Wolfram
On 04/19/2011 10:38 AM, Synge Todo wrote:
Dear Wolfram,
Thank you for your report. I suspect that a harmful macro TIME is defined on SUSE.
Could you try to insert the following lines
#ifdef TIME # undef TIME #endif
in the header files and see if the error is fixed?
Best, Synge
On 2011/04/18, at 21:15, Wolfram Brenig wrote:
Hi,
compiling ALPS on SuSE 11.4 crashes with errors as listed at the end of this mail. [gcc version 4.5.1 20101208 [gcc-4_5-branch revision 167585] (SUSE Linux), kernel 2.6.37.1-1.2-desktop]
The err msgs seem to point to the 'TIME' typename in a bunch of header files in alps_whatever/applications/qmc/looper/looper, namely in
correlation.h susceptibility.h measurement.h custom.h operator.h stiffness.h
Indeed, simply changing 'TIME' in these headers into something else, say 'MyTIME', does away with the compile error. However if this fix will induce other errors at run-time, I don't know?
Does anybody have a clue on this?
Wolfram Brenig
PS.: Actually, there seems to be a somehow similar issue with VTK, over which I stumbled while compiling it prior to vistrails, and which seems to have bugged also others: http://comments.gmane.org/gmane.comp.lib.vtk.user/55300
compile errs:--------------------------------------------
[ 49%] Building CXX object applications/qmc/looper/CMakeFiles/loop.dir/loop_custom.C.o cd /home/userxx/temporary/alpsbuilt/applications/qmc/looper&& /usr/bin/c++ -O3 -march=core2 -DNDEBUG -I/usr/local/include -I/usr/lib64/python2.7/site-packages/numpy/core/include -I/usr/include/python2.7 -I/home/userxx/temporary/alpsbuilt/src -I/home/userxx/temporary/alps/src -I/home/userxx/temporary/alps/applications/qmc/looper -o CMakeFiles/loop.dir/loop_custom.C.o -c /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C In file included from /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:29:0, from /home/userxx/temporary/alps/applications/qmc/looper/loop_config.h:38, from /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C:26: /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:182:72: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:182:72: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:418:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:418:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:422:13: error: expected unqualified-id before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:483:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:483:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:490:13: error: expected unqualified-id before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:491:49: error: type/value mismatch at argument 3 in template parameter list for ‘template<class MEASUREMENT1, class MEASUREMENT2> template<class MC, class LAT, int<anonymous> > struct looper::composite_measurement<M1, M2>::estimator’ /home/userxx/temporary/alps/applications/qmc/looper/looper/measurement.h:491:49: error: expected a constant of type ‘int’, got ‘time_t’ In file included from /home/userxx/temporary/alps/applications/qmc/looper/loop_config.h:38:0, from /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C:26: /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:37:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:37:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:41:13: error: expected unqualified-id before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:136:60: error: ‘"16:54:59"’ is not a valid template argument for type ‘int’ because string literals can never be used in this context /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:136:61: error: ‘<declaration error>’ is not a template /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:139:60: error: ‘"16:54:59"’ is not a valid template argument for type ‘int’ because string literals can never be used in this context /home/userxx/temporary/alps/applications/qmc/looper/looper/correlation.h:139:61: error: ‘<declaration error>’ is not a template In file included from /home/userxx/temporary/alps/applications/qmc/looper/loop_config.h:39:0, from /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C:26: /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:63:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:63:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:127:60: error: ‘"16:54:59"’ is not a valid template argument for type ‘int’ because string literals can never be used in this context /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:127:61: error: ‘<declaration error>’ is not a template /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:130:60: error: ‘"16:54:59"’ is not a valid template argument for type ‘int’ because string literals can never be used in this context /home/userxx/temporary/alps/applications/qmc/looper/looper/custom.h:130:61: error: ‘<declaration error>’ is not a template In file included from /home/userxx/temporary/alps/applications/qmc/looper/loop_config.h:40:0, from /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C:26: /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:40:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:40:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:45:13: error: expected unqualified-id before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:46:49: error: type/value mismatch at argument 3 in template parameter list for ‘template<unsigned int MAX_DIM> template<class MC, class LAT, int <anonymous> > struct looper::stiffness<MAX_DIM>::estimator’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:46:49: error: expected a constant of type ‘int’, got ‘time_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h: In member function ‘void looper::stiffness<MAX_DIM>::estimator<MC, LAT, <anonymous> >::estimate::begin_bs(const looper::stiffness::estimator::estimator_t&, const lattice_t&, double, int, int, int)’: /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:98:15: error: request for member ‘bond_vector_relative’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:98:40: error: request for member ‘real_bond’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:99:33: error: request for member ‘dim’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h: In member function ‘void looper::stiffness<MAX_DIM>::estimator<MC, LAT, <anonymous> >::estimate::end_bs(const looper::stiffness::estimator::estimator_t&, const lattice_t&, double, int, int, int)’: /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:105:15: error: request for member ‘bond_vector_relative’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:105:40: error: request for member ‘real_bond’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/stiffness.h:106:33: error: request for member ‘dim’ in ‘emt’, which is of non-class type ‘const looper::stiffness::estimator::estimator_t’ In file included from /home/userxx/temporary/alps/applications/qmc/looper/loop_config.h:41:0, from /home/userxx/temporary/alps/applications/qmc/looper/loop_custom.C:26: /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h: At global scope: /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:37:48: error: expected nested-name-specifier before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:37:48: error: expected ‘>’ before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:41:13: error: expected unqualified-id before string constant /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:42:49: error: type/value mismatch at argument 3 in template parameter list for ‘template<class MC, class LAT, int<anonymous> > struct looper::susceptibility::estimator’ /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:42:49: error: expected a constant of type ‘int’, got ‘time_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h: In member function ‘void looper::susceptibility::estimator<MC, LAT, <anonymous> >::estimate::end_s(const looper::susceptibility::estimator::estimator_t&, const lattice_t&, double, int, int)’: /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:128:25: error: request for member ‘gauge’ in ‘emt’, which is of non-class type ‘const looper::susceptibility::estimator::estimator_t’ /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h: In member function ‘void looper::susceptibility::estimator<MC, LAT, <anonymous> >::estimate::start_bottom(const looper::susceptibility::estimator::estimator_t&, const lattice_t&, double, int, int)’: /home/userxx/temporary/alps/applications/qmc/looper/looper/susceptibility.h:140:25: error: request for member ‘gauge’ in ‘emt’, which is of non-class type ‘const looper::susceptibility::estimator::estimator_t’ make[2]: *** [applications/qmc/looper/CMakeFiles/loop.dir/loop_custom.C.o] Error 1 make[2]: Leaving directory `/home/userxx/temporary/alpsbuilt' make[1]: *** [applications/qmc/looper/CMakeFiles/loop.dir/all] Error 2 make[1]: Leaving directory `/home/userxx/temporary/alpsbuilt' make: *** [all] Error 2
-- __________________________________________________________ Univ. Prof. Dr. Wolfram Brenig Institute for Theoretical Physics Technical University Braunschweig and NTH Lower Saxony Mendelssohnstr. 3 38106 Braunschweig GERMANY
Tel: +49 531 391 5180/81 FAX: +49 531 391 5833 Mobile: upon request Email: w.brenig@tu-bs.de WWW: http://www.fkt.tu-bs.de PGPkey: http://www.fkt.tu-bs.de/brenig/wbpubkey.shtml
<alps-r5531-5532.diff>
comp-phys-alps-users@lists.phys.ethz.ch