[Dune] How to force -std=c++0x in a dune project?
Markus Blatt
markus at dr-blatt.de
Sat Feb 16 11:47:15 CET 2013
On Fri, Feb 15, 2013 at 10:16:55PM +0100, Arya Fallahi wrote:
> ../cyrus/signal.hh: In member function 'void
> Cyrus3d::SignalDataBase::showAll()':
> ../cyrus/signal.hh:640: error: using 'typename' outside of template
> ../cyrus/signal.hh:644: error: using 'typename' outside of template
> ../cyrus/signal.hh:648: error: using 'typename' outside of template
> ../cyrus/signal.hh:652: error: using 'typename' outside of template
> ../cyrus/signal.hh:656: error: using 'typename' outside of template
This is an error that you should fix. Presumably you have to strip
"typename" here. Some compilers are just more strict than others.
> This seems to be due to the incorrect standard chosen for this machine. In
> the first line "g++" should be "g++ -std=c++0x" as in machine 1. I googled
> and searched throughout the Dune Build howto to find the way to set this in
> the opts file. However, I could not find any thing. My opt file is pretty
> simple:
>
> CONFIGURE_FLAGS=" MPICC='/tools/openmpi-1.6.3/bin/mpicc'
> CXXFLAGS='-O3 -g0
> --no-strict-aliasing'
> CPPFLAGS='-O3 -g0
> --no-strict-aliasing'
> --enable-parallel
> --prefix='/tools/cyrus'
> --with-metis='/tools/metis-5.0.2'
>
> --with-alugrid='/tools/ALUGrid-1.52' "
>
I think Cristoph is right, you are probably using the default gcc
version on your system. Please specify the compiler using CC and
CXX.
If that does not help: Instead setting MPICC, you might specify the output of
./dune-common/bin/mpi-config --mpicc=/tools/openmpi-1.6.3/bin/mpicc --cflags
and
./dune-common/bin/mpi-config --mpicc=/tools/openmpi-1.6.3/bin/mpicc --libs
in CPPFLAGS/CFLAGS and LDFLAGS, respectively.
Markus
--
Do you need more support with DUNE or HPC in general?
Dr. Markus Blatt - HPC-Simulation-Software & Services http://www.dr-blatt.de
Hans-Bunte-Str. 8-10, 69123 Heidelberg, Germany
Tel.: +49 (0) 160 97590858 Fax: +49 (0)322 1108991658
More information about the Dune
mailing list