Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build error on Rhea #826

Closed
keichi opened this issue Aug 28, 2018 · 2 comments
Closed

Build error on Rhea #826

keichi opened this issue Aug 28, 2018 · 2 comments

Comments

@keichi
Copy link
Contributor

keichi commented Aug 28, 2018

I'm getting link errors when trying to build ADIOS2 on Rhea.

Error message:

[ 63%] Linking C executable ../../../bin/hello_bpWriter_c
../../../lib/libadios2.so.2.2.0: undefined reference to `std::this_thread::__sleep_for(std::chrono::duration<long, std::ratio<1l, 1l> >, std::chrono::duration<long, std::ratio<1l, 1000000000l> >)@GLIBCXX_3.4.18'
../../../lib/libadios2.so.2.2.0: undefined reference to `std::__future_base::_Result_base::_Result_base()@GLIBCXX_3.4.15'
../../../lib/libadios2.so.2.2.0: undefined reference to `typeinfo for std::__future_base::_State_base@GLIBCXX_3.4.15'
../../../lib/libadios2.so.2.2.0: undefined reference to `std::__detail::_Prime_rehash_policy::_M_need_rehash(unsigned long, unsigned long, unsigned long) const@GLIBCXX_3.4.18'
../../../lib/libadios2.so.2.2.0: undefined reference to `vtable for std::nested_exception@CXXABI_1.3.5'
../../../lib/libadios2.so.2.2.0: undefined reference to `vtable for std::__future_base::_State_base@GLIBCXX_3.4.15'
../../../lib/libadios2.so.2.2.0: undefined reference to `std::__future_base::_State_base::~_State_base()@GLIBCXX_3.4.15'
../../../lib/libadios2.so.2.2.0: undefined reference to `std::__detail::_Prime_rehash_policy::_M_next_bkt(unsigned long) const@GLIBCXX_3.4.18'
../../../lib/libadios2.so.2.2.0: undefined reference to `typeinfo for std::nested_exception@CXXABI_1.3.5'
../../../lib/libadios2.so.2.2.0: undefined reference to `typeinfo for std::__future_base::_Result_base@GLIBCXX_3.4.15'
../../../lib/libadios2.so.2.2.0: undefined reference to `std::__future_base::_Result_base::~_Result_base()@GLIBCXX_3.4.15'
../../../lib/libadios2.so.2.2.0: undefined reference to `std::invalid_argument::~invalid_argument()@GLIBCXX_3.4.15'
../../../lib/libadios2.so.2.2.0: undefined reference to `std::chrono::_V2::system_clock::now()@GLIBCXX_3.4.19'
../../../lib/libadios2.so.2.2.0: undefined reference to `std::__throw_future_error(int)@GLIBCXX_3.4.14'
../../../lib/libadios2.so.2.2.0: undefined reference to `std::nested_exception::~nested_exception()@CXXABI_1.3.5'
../../../lib/libadios2.so.2.2.0: undefined reference to `std::_Hash_bytes(void const*, unsigned long, unsigned long)@CXXABI_1.3.5'
../../../lib/libadios2.so.2.2.0: undefined reference to `std::__throw_bad_function_call()@GLIBCXX_3.4.14'
collect2: error: ld returned 1 exit status

CMake command:

CC=`which gcc` CXX=`which g++` cmake -DADIOS2_USE_Fortran=OFF -DCMAKE_INSTALL_PREFIX=/lustre/atlas/proj-shared/csc143/keichi/rhea ..

(CC and CXX are set because module load PE-gnu does not update these variables on Rhea)

CMake output:

ADIOS2 build configuration:
  ADIOS Version: 2.2.0
  C++ Compiler : GNU 4.8.2
    /ccs/compilers/gcc/rhel6-x86_64/4.8.2/bin/g++

  Installation prefix: /lustre/atlas/proj-shared/csc143/keichi/rhea
        bin: bin
        lib: lib
    include: include
      cmake: lib/cmake/adios2

  Features:
    Library Type: shared
    Build Type:   Release
    Testing: ON
    Build Options:
      BZip2    : ON
      ZFP      : OFF
      SZ       : OFF
      MPI      : ON
      DataMan  : ON
      SST      : ON
      ZeroMQ   : OFF
      HDF5     : OFF
      ADIOS1   : OFF
      Python   : OFF
      Fortran  : OFF
      SysVShMem: ON

Loaded modules:

  1) lustredu/1.4         4) bbcp/15.02.03.00.1   7) openmpi/1.8.4
  2) xalt/0.5.3           5) DefApps              8) PE-gnu/4.8.2-1.8.4
  3) hsi/5.0.2.p1         6) gcc/4.8.2            9) cmake/3.6.1
@williamfgc
Copy link
Contributor

@keichi Looks like is linking against the wrong libstdc++ (or stdc++) for the adios2 dependency. Try using -DBUILD_SHARED_LIBS=OFF for static linking, which is the preferred method anyways.

@keichi
Copy link
Contributor Author

keichi commented Aug 28, 2018

@williamfgc Problem solved once I have added -DBUILD_SHARED_LIBS=OFF. Thanks!

@keichi keichi closed this as completed Aug 28, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants