Xyce make fails

194 views
Skip to first unread message

Tyler C

unread,
Feb 15, 2018, 11:06:26 AM2/15/18
to xyce-users
I'm trying to build xyce 6.8 serial and I am receiving the following errors during make:

(snipped from xyceMakeOutput.txt):
  • /home/dragontamer/builds/xyce/Xyce-6.8/src/AnalysisPKG/N_ANP_MOR.C:1700:124: error: no matching function for call to ‘Teuchos::LAPACK<int, std::complex<double> >::GECON(const char&, int, std::complex<double>*, int, Teuchos::ScalarTraits<std::complex<double> >::magnitudeType, double*, __gnu_cxx::__alloc_traits<std::allocator<std::complex<double> > >::value_type*, __gnu_cxx::__alloc_traits<std::allocator<double> >::value_type*, int*)’
  • /home/dragontamer/XyceLibs/include/Teuchos_SerialDenseMatrix.hpp:789:15: error: no match for ‘operator>’ (operand types are ‘Teuchos::ScalarTraits<std::complex<double> >::magnitudeType {aka std::complex<double>}’ and ‘Teuchos::ScalarTraits<std::complex<double> >::magnitudeType {aka std::complex<double>}’)
  • /home/dragontamer/XyceLibs/include/Teuchos_LAPACK.hpp:92:86: error: ‘LAPACK_routine_not_defined_for_this_type’ is not a member of ‘std::complex<double>’
  • /home/dragontamer/XyceLibs/include/Teuchos_ScalarTraitsDecl.hpp:59:81: error: ‘this_type_is_missing_a_specialization’ is not a member of ‘std::complex<double>’
Make end with:
Makefile:522: recipe for target 'N_ANP_MOR.lo' failed
make[3]: *** [N_ANP_MOR.lo] Error 1
make[3]: Leaving directory '/home/dragontamer/builds/xyce/build/src/AnalysisPKG'
Makefile:872: recipe for target 'all-recursive' failed
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory '/home/dragontamer/builds/xyce/build/src'
Makefile:648: recipe for target 'all' failed
make[1]: *** [all] Error 2
make[1]: Leaving directory '/home/dragontamer/builds/xyce/build/src'
Makefile:521: recipe for target 'all-recursive' failed
make: *** [all-recursive] Error 1


I have included the full make output above, in xyceMakeOutput.txt.

Thank you in advance for your help with this,
-Tyler Cooper
xyceReconfigure
trilinosReconfigure
xyceMakeOutput.txt

xyce-users

unread,
Feb 15, 2018, 11:15:02 AM2/15/18
to xyce-users
Your trilinos reconfigure is missing a line:
   -DTeuchos_ENABLE_COMPLEX=ON \
Check your Trilinos cmake invocation against the recommended Trilinos cmake line in the building guide, https://xyce.sandia.gov/documentation/BuildingGuide.html#serialTrilinosCMake.

In older trilinos releases this wasn't necessary, and you may be working of an older building guide or old reconfigure (since I see you have been using Xyce for a few years).

xyce-users

unread,
Feb 15, 2018, 5:03:10 PM2/15/18
to xyce-users
As a result of your query, we've added a configure-time check to verify that Trilinos was built with this option, so in the next release of Xyce users will be informed of the problem early and told how to fix it, instead of having the compilation simply fail late in the game with incomprehensible error messages.  Configure was simply assuming that Trilinos had been built with the Teuchos_ENABLE_COMPLEX=ON option, as was the code that used these features of Teuchos.

Thank you for bringing it to our attention.

Tyler C

unread,
Feb 15, 2018, 6:18:32 PM2/15/18
to xyce-users
You're welcome, I'm glad I could help inspire an improvement to the software.

However, I could still use assistance, as make now fails much later into the compilation.  I copy and pasted the example Trilinos configuration script you linked to into my Trilinos reconfigure script, the new version of this file has been uploaded under the name trilinosReconfigure.  The Xyce reconfigure script was changed to the new location of Trilinos's files (/home/dragontamer/XyceLibs/Serial instead of /home/dragontamer/XyceLibs).  I then reran the reconfigure files and make, make install commands for Trilinos, and I ran the reconfigure file or Xyce and make, however, make now breaks here:

(Snipped from the end of xyceMakeOutput.txt):

  CXX      Xyce.o
  CXXLD    Xyce
/home/dragontamer/XyceLibs/Serial/lib/libtrilinoscouplings.a(EpetraExt_AmesosBTF_CrsGraph.cpp.o): In function `EpetraExt::AmesosBTF_CrsGraph::operator()(Epetra_CrsGraph&)':
EpetraExt_AmesosBTF_CrsGraph.cpp:(.text+0x914): undefined reference to `trilinos_btf_order'
/home/dragontamer/XyceLibs/Serial/lib/libifpack.a(Ifpack_AMDReordering.cpp.o): In function `Ifpack_AMDReordering::Compute(Ifpack_Graph const&)':
Ifpack_AMDReordering.cpp:(.text+0xef0): undefined reference to `trilinos_amd_order'
/home/dragontamer/XyceLibs/Serial/lib/libamesos.a(Amesos_Klu.cpp.o): In function `Amesos_Klu::PerformSymbolicFactorization()':
Amesos_Klu.cpp:(.text+0x4073): undefined reference to `trilinos_klu_defaults'
Amesos_Klu.cpp:(.text+0x40a5): undefined reference to `trilinos_klu_free_symbolic'
Amesos_Klu.cpp:(.text+0x40c3): undefined reference to `trilinos_klu_analyze'
/home/dragontamer/XyceLibs/Serial/lib/libamesos.a(Amesos_Klu.cpp.o): In function `Amesos_Klu::PerformNumericFactorization()':
Amesos_Klu.cpp:(.text+0x4615): undefined reference to `trilinos_klu_free_numeric'
Amesos_Klu.cpp:(.text+0x461f): undefined reference to `trilinos_klu_factor'
Amesos_Klu.cpp:(.text+0x4a6f): undefined reference to `trilinos_klu_refactor'
Amesos_Klu.cpp:(.text+0x4bdb): undefined reference to `trilinos_klu_rcond'
/home/dragontamer/XyceLibs/Serial/lib/libamesos.a(Amesos_Klu.cpp.o): In function `Amesos_Klu::Solve()':
Amesos_Klu.cpp:(.text+0x5602): undefined reference to `trilinos_klu_solve'
Amesos_Klu.cpp:(.text+0x5971): undefined reference to `trilinos_klu_tsolve'
collect2: error: ld returned 1 exit status
Makefile:785: recipe for target 'Xyce' failed
make[3]: *** [Xyce] Error 1
make[3]: Leaving directory '/home/dragontamer/builds/xyce/build/src'
Makefile:872: recipe for target 'all-recursive' failed
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory '/home/dragontamer/builds/xyce/build/src'
Makefile:648: recipe for target 'all' failed
make[1]: *** [all] Error 2
make[1]: Leaving directory '/home/dragontamer/builds/xyce/build/src'
Makefile:521: recipe for target 'all-recursive' failed
make: *** [all-recursive] Error 1

I appreciate you taking the time to help me, and I hope you can provide assistance on this error.
-Tyler
xyceMakeOutput.txt
xyceReconfigure
trilinosReconfigure

xyce-users

unread,
Feb 15, 2018, 7:03:04 PM2/15/18
to xyce-users
It appears that Trilinos dependencies are not properly being pulled in by the configure script you're using for Xyce.  This may be because you're using an old form of the Xyce configure line that was recommended briefly in the very early days of the open source release, but is no longer recommended (because it can lead to problems like this).  The problem is that Trilinos libraries can be built in a variety of ways, and we can't possibly probe for all the various permutations of how they might be built (though we can check certain things).  So we rely on some features of the Trilinos build system to *tell* us what to link in.

By specifying the Trilinos location via LDFLAGS and CPPFLAGS, you're bypassing the check that the Xyce configure script does to assure that all the trilinos dependencies are properly accounted for. 

We no longer recommend using LDFLAGS and CPPFLAGS to point Xyce at Trilnos libraries and headers, and recommend instead that you use the ARCHDIR mechanism, as described in the building guide.  By following this guidance, Xyce's configure is able to find some files that Trilinos creates and dumps into its include directory, and pull in extra dependencies they mark as needed.  If you look through the system-specific guidance we have in the building guide, you'll see that they all use this technique.

There is another issue in your reconfigure script that is unrelated to this error:  you left off the trailing "\" on the F77 line, which means that the CXXFLAGS and CFLAGS you specified will be ignored (you'll get an unoptimized build).

Please try the attached reconfigure script instead, and see if it clears up your problem.
TylerC_xyceReconfigure

Tyler C

unread,
Feb 16, 2018, 3:32:58 AM2/16/18
to xyce-users
Thank you for the reconfigure script, with it Xyce compiled successfully.  I thank you for your time and assistance, it was greatly appreciated.  I have not run the Xyce_Regression-6.8 test suite yet, I'll have to do that in the morning.

Once again thank you for you help,
-Tyler Cooper
Reply all
Reply to author
Forward
0 new messages