Page 1 of 1

Compiling on Arch Linux

PostPosted: Sun Jul 20, 2014 7:00 pm
by michaelrculver
Hello all,

I've been trying to get GMAT to compile on my system - I've tried to build it using the "trunk" source, and then more recently with the "R2013b" source.

Both times the process has stopped around 65% and gives me this output:

Code: Select all
[ 65%] Building CXX object /home/michael/Development/GMAT/gmat-code/branches/R2013b/build/src/base/CMakeFiles/GmatBase.dir/util/FileUtil.cpp.o
/home/michael/Development/GMAT/gmat-code/branches/R2013b/src/base/util/FileUtil.cpp: In function ‘std::string GmatFileUtil::GetApplicationPath()’:
/home/michael/Development/GMAT/gmat-code/branches/R2013b/src/base/util/FileUtil.cpp:178:46: error: no matching function for call to ‘min(ssize_t, int)’
                    GmatFile::MAX_PATH_LEN - 1);
                                              ^
/home/michael/Development/GMAT/gmat-code/branches/R2013b/src/base/util/FileUtil.cpp:178:46: note: candidates are:
In file included from /usr/include/c++/4.9.0/bits/char_traits.h:39:0,
                 from /usr/include/c++/4.9.0/string:40,
                 from /home/michael/Development/GMAT/gmat-code/branches/R2013b/src/base/./include/gmatdefs.hpp:30,
                 from /home/michael/Development/GMAT/gmat-code/branches/R2013b/src/base/util/FileUtil.hpp:25,
                 from /home/michael/Development/GMAT/gmat-code/branches/R2013b/src/base/util/FileUtil.cpp:23:
/usr/include/c++/4.9.0/bits/stl_algobase.h:194:5: note: template<class _Tp> const _Tp& std::min(const _Tp&, const _Tp&)
     min(const _Tp& __a, const _Tp& __b)
     ^
/usr/include/c++/4.9.0/bits/stl_algobase.h:194:5: note:   template argument deduction/substitution failed:
/home/michael/Development/GMAT/gmat-code/branches/R2013b/src/base/util/FileUtil.cpp:178:46: note:   deduced conflicting types for parameter ‘const _Tp’ (‘long int’ and ‘int’)
                    GmatFile::MAX_PATH_LEN - 1);
                                              ^
In file included from /usr/include/c++/4.9.0/bits/char_traits.h:39:0,
                 from /usr/include/c++/4.9.0/string:40,
                 from /home/michael/Development/GMAT/gmat-code/branches/R2013b/src/base/./include/gmatdefs.hpp:30,
                 from /home/michael/Development/GMAT/gmat-code/branches/R2013b/src/base/util/FileUtil.hpp:25,
                 from /home/michael/Development/GMAT/gmat-code/branches/R2013b/src/base/util/FileUtil.cpp:23:
/usr/include/c++/4.9.0/bits/stl_algobase.h:240:5: note: template<class _Tp, class _Compare> const _Tp& std::min(const _Tp&, const _Tp&, _Compare)
     min(const _Tp& __a, const _Tp& __b, _Compare __comp)
     ^
/usr/include/c++/4.9.0/bits/stl_algobase.h:240:5: note:   template argument deduction/substitution failed:
/home/michael/Development/GMAT/gmat-code/branches/R2013b/src/base/util/FileUtil.cpp:178:46: note:   deduced conflicting types for parameter ‘const _Tp’ (‘long int’ and ‘int’)
                    GmatFile::MAX_PATH_LEN - 1);
                                              ^
/home/michael/Development/GMAT/gmat-code/branches/R2013b/build/src/base/CMakeFiles/GmatBase.dir/build.make:8127: recipe for target '/home/michael/Development/GMAT/gmat-code/branches/R2013b/build/src/base/CMakeFiles/GmatBase.dir/util/FileUtil.cpp.o' failed
make[2]: *** [/home/michael/Development/GMAT/gmat-code/branches/R2013b/build/src/base/CMakeFiles/GmatBase.dir/util/FileUtil.cpp.o] Error 1
CMakeFiles/Makefile2:75: recipe for target '/home/michael/Development/GMAT/gmat-code/branches/R2013b/build/src/base/CMakeFiles/GmatBase.dir/all' failed
make[1]: *** [/home/michael/Development/GMAT/gmat-code/branches/R2013b/build/src/base/CMakeFiles/GmatBase.dir/all] Error 2
Makefile:76: recipe for target 'all' failed
make: *** [all] Error 2


Any help would be greatly appreciated.

Best,

Michael

Re: Compiling on Arch Linux

PostPosted: Mon Jul 21, 2014 6:52 am
by ryan88
This looks like a bug I reported over a year ago: http://li64-187.members.linode.com:8080/browse/GMT-3953

Re: Compiling on Arch Linux

PostPosted: Mon Jul 21, 2014 3:49 pm
by jjkparker
Hi, thanks for the report.

Please note that our CMake-based build system is experimental. See here for (admittedly rough) instructions for how we usually build on Linux.

Re: Compiling on Arch Linux

PostPosted: Mon Apr 23, 2018 4:55 pm
by GeorgeErvin
I’m glad that finally you updated about the bug, I’ve literally been searching online for the solution. I have started a project in Linux and when I started the bug started affecting the software, I read about the bug in edubirdie.com aussiewritingreviews writing services and I was stated that it should be reported to the technical center and now you got with a solution.