Skip to content
This repository has been archived by the owner on Dec 14, 2020. It is now read-only.

Couenne fails to build with gcc 6.2.1 #27

Open
mlubin opened this issue Jan 30, 2017 · 10 comments
Open

Couenne fails to build with gcc 6.2.1 #27

mlubin opened this issue Jan 30, 2017 · 10 comments

Comments

@mlubin
Copy link
Member

mlubin commented Jan 30, 2017

I know this is an upstream issue (maybe even fixed already), but opening this to keep track on the julia side. On ArchLinux with gcc 6.2.1, I get the following error:

In file included from /usr/include/c++/6.2.1/string:52:0,
                 from /home/mlubin/.julia/v0.5/Cbc/deps/usr/include/coin/CoinError.hpp:9,
                 from /home/mlubin/.julia/v0.5/Cbc/deps/usr/include/coin/CoinHelperFunctions.hpp:25,
                 from ../../../../Couenne/src/problem/../readnl/readnl.cpp:17:
/usr/include/c++/6.2.1/bits/basic_string.h: In function 'double std::__cxx11::stod(const string&, std::size_t*)':
/usr/include/c++/6.2.1/bits/basic_string.h:5443:31: error: 'strtod_ASL' is not a member of 'std'
   { return __gnu_cxx::__stoa(&std::strtod, "stod", __str.c_str(), __idx); }
                               ^~~
/usr/include/c++/6.2.1/bits/basic_string.h:5443:31: note: suggested alternative:
In file included from ../../../../Couenne/src/problem/../readnl/readnl.cpp:11:0:
/home/mlubin/.julia/v0.5/Ipopt/deps/usr/include/coin/ThirdParty/asl.h:1107:16: note:   'strtod_ASL'
  extern double strtod_ASL(Const char*, char**);
                ^~~~~~~~~~
make[2]: *** [Makefile:503: readnl.lo] Error 1
make[2]: Leaving directory '/home/mlubin/.julia/v0.5/CoinOptServices/deps/src/OS-2.9.2/build/Couenne/src/problem'
make[1]: *** [Makefile:476: all-recursive] Error 1
make[1]: Leaving directory '/home/mlubin/.julia/v0.5/CoinOptServices/deps/src/OS-2.9.2/build/Couenne'
make: *** [Makefile:310: all-recursive] Error 1

CC @chriscoey

@tkelman
Copy link
Contributor

tkelman commented Apr 2, 2017

maybe even fixed already

Highly doubt it. From the relevant mailing lists I don't think it's been reported.

@tkelman
Copy link
Contributor

tkelman commented Apr 2, 2017

@mlubin
Copy link
Member Author

mlubin commented Apr 2, 2017

I'm trying to compile OS trunk. Ran into the same issue and your fix worked, now there's a new error:

OSMatrix.cpp: In member function 'ExpandedMatrixBlocks* MatrixType::getBlocks(int*, int, int*, int, OSMatrix**, bool, bool, ENUM_MATRIX_TYPE, ENUM_MATRIX_SYMMETRY)':
OSMatrix.cpp:2118:15: error: cannot convert 'bool' to 'ExpandedMatrixBlocks*' in return
        return false;

Changed false to NULL and proceeded to get a bunch more identical errors in different places.

@tkelman
Copy link
Contributor

tkelman commented Apr 2, 2017

-std=gnu++98 ?

@mlubin
Copy link
Member Author

mlubin commented Apr 2, 2017

where would I put that?

@tkelman
Copy link
Contributor

tkelman commented Apr 2, 2017

ADD_CXXFLAGS="-std=gnu++98" in the configure call, maybe

@mlubin
Copy link
Member Author

mlubin commented Apr 2, 2017

In file included from /usr/include/c++/6.3.1/cstdint:35:0,
                 from CoinTypes.hpp:15,
                 from CoinHelperFunctions.hpp:24,
                 from CoinPostsolveMatrix.cpp:11:
/usr/include/c++/6.3.1/bits/c++0x_warning.h:32:2: error: #error This file requires compiler and library support for the ISO C++ 2011 standard. This support must be enabled with the -std=c++11 or -std=gnu++11 compiler options.
 #error This file requires compiler and library support \

@tkelman
Copy link
Contributor

tkelman commented Apr 2, 2017

Guess the whole stack would need to be re-configured then, ref https://github.com/coin-or/CoinUtils/blob/releases/2.10.7/CoinUtils/src/CoinTypes.hpp

@mlubin
Copy link
Member Author

mlubin commented Apr 2, 2017

I did reconfigure the whole stack. There are nice warnings like

configure: WARNING: cstdint: present but cannot be compiled
configure: WARNING: cstdint:     check for missing prerequisite headers?
configure: WARNING: cstdint: see the Autoconf documentation
configure: WARNING: cstdint:     section "Present But Cannot Be Compiled"
configure: WARNING: cstdint: proceeding with the preprocessor's result
configure: WARNING: cstdint: in the future, the compiler will take precedence
configure: WARNING:     ## ---------------------------------------------------- ##
configure: WARNING:     ## Report this to http://projects.coin-or.org/CoinUtils ##
configure: WARNING:     ## ---------------------------------------------------- ##

@tkelman
Copy link
Contributor

tkelman commented Apr 2, 2017

config.log might have more info there, but at this point probably better to let Ted and Gus know.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants