Compilation error during execution
Posted: 18 Jul 2019, 17:10
Hello,
I am trying to build the minimal version of Polymake from source and install it locally. I am using Ubuntu 18.04, GCC 7.4, and Perl 5.26. After installing all dependencies, I managed to run the following without errors:
However, when I try to execute the polymake binary, I get the following:
If it helps, I also get the following warnings during compilation:
I didn't find a way to add these flags, there are recognized neither by make nor by the configure script.
Any ideas on how to fix the problem?
I am trying to build the minimal version of Polymake from source and install it locally. I am using Ubuntu 18.04, GCC 7.4, and Perl 5.26. After installing all dependencies, I managed to run the following without errors:
Code: Select all
configure -prefix=/my/installation/path
make
make install
Code: Select all
bzfblanc-> ../polymake-installed/bin/polymake
polymake: WARNING: Recompiling in /nfs/optimi/kombadon/bzfblanc/misc/polymake/unimodularity-library-Polymake-1.1/build/Opt, please be patient...
Compilation failed; see the error log below
ninja: Entering directory `/nfs/optimi/kombadon/bzfblanc/misc/polymake/unimodularity-library-Polymake-1.1/build/Opt'
[1/3] COMPILE /nfs/optimi/kombadon/bzfblanc/misc/polymake/unimodularity-library-Polymake-1.1/build/Opt/apps/matroid/unimodularity-test.o
FAILED: /nfs/optimi/kombadon/bzfblanc/misc/polymake/unimodularity-library-Polymake-1.1/build/Opt/apps/matroid/unimodularity-test.o
g++ -c -o /nfs/optimi/kombadon/bzfblanc/misc/polymake/unimodularity-library-Polymake-1.1/build/Opt/apps/matroid/unimodularity-test.o -MMD -MT /nfs/optimi/kombadon/bzfblanc/misc/polymake/unimodularity-library-Polymake-1.1/build/Opt/apps/matroid/unimodularity-test.o -MF /nfs/optimi/kombadon/bzfblanc/misc/polymake/unimodularity-library-Polymake-1.1/build/Opt/apps/matroid/unimodularity-test.o.d -fPIC -pipe -std=c++14 -march=native -ftemplate-depth-200 -fno-strict-aliasing -Wno-parentheses -Wshadow -fopenmp -Wno-error=unused-function -DPOLYMAKE_DEBUG=0 -DNDEBUG -O3 -DPOLYMAKE_APPNAME=matroid -DPOLYMAKE_DEFINITION_SOURCE_FILE="unimodularity-test.cpp" -I/nfs/optimi/kombadon/bzfblanc/misc/polymake/unimodularity-library-Polymake-1.1/include/app-wrappers -I/nfs/optimi/kombadon/bzfblanc/misc/polymake/unimodularity-library-Polymake-1.1/include/apps -I/local/bzfblanc/polymake-installed/include/polymake/external -I/local/bzfblanc/polymake-installed/include /nfs/optimi/kombadon/bzfblanc/misc/polymake/unimodularity-library-Polymake-1.1/apps/matroid/src/unimodularity-test.cpp && : 'COMPILER_USED=7.4.0'
/nfs/optimi/kombadon/bzfblanc/misc/polymake/unimodularity-library-Polymake-1.1/apps/matroid/src/unimodularity-test.cpp: In function 'pm::perl::Object polymake::matroid::construct_decomposition_tree(unimod::decomposed_matroid*)':
/nfs/optimi/kombadon/bzfblanc/misc/polymake/unimodularity-library-Polymake-1.1/apps/matroid/src/unimodularity-test.cpp:47:103: error: no matching function for call to 'pm::perl::Object::Object(const char*)'
perl::Object result(leaf != NULL ? "MatroidDecompositionLeaf" : "MatroidDecompositionSeparation");
^
In file included from /local/bzfblanc/polymake-installed/include/polymake/client.h:26:0,
from /nfs/optimi/kombadon/bzfblanc/misc/polymake/unimodularity-library-Polymake-1.1/apps/matroid/src/unimodularity-test.cpp:3:
/local/bzfblanc/polymake-installed/include/polymake/perl/Object.h:184:4: note: candidate: pm::perl::Object::Object(pm::perl::Object&&)
Object(Object&& o) noexcept
^~~~~~
/local/bzfblanc/polymake-installed/include/polymake/perl/Object.h:184:4: note: no known conversion for argument 1 from 'const char*' to 'pm::perl::Object&&'
/local/bzfblanc/polymake-installed/include/polymake/perl/Object.h:182:4: note: candidate: pm::perl::Object::Object(const pm::perl::Object&)
Object(const Object& o);
^~~~~~
/local/bzfblanc/polymake-installed/include/polymake/perl/Object.h:182:4: note: no known conversion for argument 1 from 'const char*' to 'const pm::perl::Object&'
/local/bzfblanc/polymake-installed/include/polymake/perl/Object.h:175:4: note: candidate: template<class ... Params> pm::perl::Object::Object(const polymake::AnyString&, polymake::mlist<T ...>, const pm::perl::Object&)
Object(const AnyString& type_name, mlist<Params...> params, const Object& src)
^~~~~~
/local/bzfblanc/polymake-installed/include/polymake/perl/Object.h:175:4: note: template argument deduction/substitution failed:
/nfs/optimi/kombadon/bzfblanc/misc/polymake/unimodularity-library-Polymake-1.1/apps/matroid/src/unimodularity-test.cpp:47:103: note: candidate expects 3 arguments, 1 provided
perl::Object result(leaf != NULL ? "MatroidDecompositionLeaf" : "MatroidDecompositionSeparation");
^
In file included from /local/bzfblanc/polymake-installed/include/polymake/client.h:26:0,
from /nfs/optimi/kombadon/bzfblanc/misc/polymake/unimodularity-library-Polymake-1.1/apps/matroid/src/unimodularity-test.cpp:3:
/local/bzfblanc/polymake-installed/include/polymake/perl/Object.h:171:4: note: candidate: pm::perl::Object::Object(const polymake::AnyString&, const pm::perl::Object&)
Object(const AnyString& type_name, const Object& src)
^~~~~~
/local/bzfblanc/polymake-installed/include/polymake/perl/Object.h:171:4: note: candidate expects 2 arguments, 1 provided
/local/bzfblanc/polymake-installed/include/polymake/perl/Object.h:169:4: note: candidate: pm::perl::Object::Object(const pm::perl::ObjectType&, const pm::perl::Object&)
Object(const ObjectType& type, const Object& src);
^~~~~~
/local/bzfblanc/polymake-installed/include/polymake/perl/Object.h:169:4: note: candidate expects 2 arguments, 1 provided
/local/bzfblanc/polymake-installed/include/polymake/perl/Object.h:165:4: note: candidate: template<class ... Params> pm::perl::Object::Object(const polymake::AnyString&, polymake::mlist<T ...>, const polymake::AnyString&)
Object(const AnyString& type_name, mlist<Params...> params, const AnyString& name=AnyString())
^~~~~~
/local/bzfblanc/polymake-installed/include/polymake/perl/Object.h:165:4: note: template argument deduction/substitution failed:
/nfs/optimi/kombadon/bzfblanc/misc/polymake/unimodularity-library-Polymake-1.1/apps/matroid/src/unimodularity-test.cpp:47:103: note: candidate expects 3 arguments, 1 provided
perl::Object result(leaf != NULL ? "MatroidDecompositionLeaf" : "MatroidDecompositionSeparation");
^
In file included from /local/bzfblanc/polymake-installed/include/polymake/client.h:26:0,
from /nfs/optimi/kombadon/bzfblanc/misc/polymake/unimodularity-library-Polymake-1.1/apps/matroid/src/unimodularity-test.cpp:3:
/local/bzfblanc/polymake-installed/include/polymake/perl/Object.h:160:13: note: candidate: pm::perl::Object::Object(const polymake::AnyString&, const polymake::AnyString&)
explicit Object(const AnyString& type_name, const AnyString& name=AnyString())
^~~~~~
/local/bzfblanc/polymake-installed/include/polymake/perl/Object.h:160:13: note: no known conversion for argument 1 from 'const char*' to 'const polymake::AnyString&'
/local/bzfblanc/polymake-installed/include/polymake/perl/Object.h:157:13: note: candidate: pm::perl::Object::Object(const pm::perl::ObjectType&, const polymake::AnyString&)
explicit Object(const ObjectType& type, const AnyString& name=AnyString());
^~~~~~
/local/bzfblanc/polymake-installed/include/polymake/perl/Object.h:157:13: note: no known conversion for argument 1 from 'const char*' to 'const pm::perl::ObjectType&'
/local/bzfblanc/polymake-installed/include/polymake/perl/Object.h:154:4: note: candidate: pm::perl::Object::Object()
Object() : obj_ref(nullptr) {}
^~~~~~
/local/bzfblanc/polymake-installed/include/polymake/perl/Object.h:154:4: note: candidate expects 0 arguments, 1 provided
/local/bzfblanc/polymake-installed/include/polymake/perl/Object.h:147:13: note: candidate: pm::perl::Object::Object(sv*)
explicit Object(SV* ref_arg)
^~~~~~
/local/bzfblanc/polymake-installed/include/polymake/perl/Object.h:147:13: note: no known conversion for argument 1 from 'const char*' to 'sv*'
/nfs/optimi/kombadon/bzfblanc/misc/polymake/unimodularity-library-Polymake-1.1/apps/matroid/src/unimodularity-test.cpp: In function 'pm::perl::ListReturn polymake::matroid::is_totally_unimodular(const pm::Matrix<pm::Integer>&, pm::perl::OptionSet)':
/nfs/optimi/kombadon/bzfblanc/misc/polymake/unimodularity-library-Polymake-1.1/apps/matroid/src/unimodularity-test.cpp:82:45: error: 'const class pm::Integer' has no member named 'to_int'
input_matrix(r, c) = matrix(r, c).to_int();
^~~~~~
/nfs/optimi/kombadon/bzfblanc/misc/polymake/unimodularity-library-Polymake-1.1/apps/matroid/src/unimodularity-test.cpp: In function 'bool polymake::matroid::is_unimodular_plain(const pm::Matrix<pm::Integer>&)':
/nfs/optimi/kombadon/bzfblanc/misc/polymake/unimodularity-library-Polymake-1.1/apps/matroid/src/unimodularity-test.cpp:139:45: error: 'const class pm::Integer' has no member named 'to_int'
input_matrix(r, c) = matrix(r, c).to_int();
^~~~~~
/nfs/optimi/kombadon/bzfblanc/misc/polymake/unimodularity-library-Polymake-1.1/apps/matroid/src/unimodularity-test.cpp: In function 'bool polymake::matroid::is_strongly_unimodular_plain(const pm::Matrix<pm::Integer>&)':
/nfs/optimi/kombadon/bzfblanc/misc/polymake/unimodularity-library-Polymake-1.1/apps/matroid/src/unimodularity-test.cpp:154:45: error: 'const class pm::Integer' has no member named 'to_int'
input_matrix(r, c) = matrix(r, c).to_int();
^~~~~~
/nfs/optimi/kombadon/bzfblanc/misc/polymake/unimodularity-library-Polymake-1.1/apps/matroid/src/unimodularity-test.cpp: In function 'pm::perl::ListReturn polymake::matroid::is_k_modular_compute(const pm::Matrix<pm::Integer>&)':
/nfs/optimi/kombadon/bzfblanc/misc/polymake/unimodularity-library-Polymake-1.1/apps/matroid/src/unimodularity-test.cpp:170:45: error: 'const class pm::Integer' has no member named 'to_int'
input_matrix(r, c) = matrix(r, c).to_int();
^~~~~~
/nfs/optimi/kombadon/bzfblanc/misc/polymake/unimodularity-library-Polymake-1.1/apps/matroid/src/unimodularity-test.cpp: In function 'pm::perl::ListReturn polymake::matroid::is_strongly_k_modular_compute(const pm::Matrix<pm::Integer>&)':
/nfs/optimi/kombadon/bzfblanc/misc/polymake/unimodularity-library-Polymake-1.1/apps/matroid/src/unimodularity-test.cpp:189:45: error: 'const class pm::Integer' has no member named 'to_int'
input_matrix(r, c) = matrix(r, c).to_int();
^~~~~~
ninja: build stopped: subcommand failed.
Code: Select all
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
Any ideas on how to fix the problem?