hpx: Can't link HPX when APEX enabled

Expected Behavior

HPX used to build fine with -DHPX_WITH_APEX=TRUE, but for many weeks that has been unstable because of CMake configuration changes. It hasn’t built correctly for weeks.

Likely, a change needs to be made to how the hpx_apex library is built, but I can’t figure out how to make it work with the HPX cmake macros. Could some configuration expert please see what’s wrong with the way the APEX library is included by CMake? See: https://github.com/khuck/xpress-apex/blob/d03e7c0b8ddfc7362fdd9d3993a2e345c1313ea6/src/apex/CMakeLists.hpx#L375-L382 - is this correct?

Actual Behavior

[ 84%] Linking CXX shared library ../lib/libhpx.so
/usr/bin/ld: cannot find -lhpx_algorithms
/usr/bin/ld: cannot find -lhpx_assertion
/usr/bin/ld: cannot find -lhpx_format
/usr/bin/ld: cannot find -lhpx_hardware
collect2: error: ld returned 1 exit status
make[3]: *** [lib/libhpx.so.1.4.0] Error 1
make[2]: *** [src/CMakeFiles/hpx.dir/all] Error 2
make[1]: *** [CMakeFiles/core.dir/rule] Error 2
make: *** [core] Error 2

Steps to Reproduce the Problem

… Please be as specific as possible while describing how to reproduce your problem.

  1. Checkout current “stable” tag
  2. Configure with -DHPX_WITH_APEX=TRUE -DHPX_WITH_APEX_TAG=develop
  3. Make

Specifications

… Please describe your environment

  • HPX Version: current “stable” tag
  • Platform (compiler, OS): all

About this issue

  • Original URL
  • State: closed
  • Created 5 years ago
  • Comments: 20 (20 by maintainers)

Most upvoted comments

@aurianer I was able to get it to build with this mess (I added every library) - is it correct?

add_hpx_library(apex
  STATIC NOLIBS EXCLUDE_FROM_ALL
  NOEXPORT
  SOURCES ${apex_sources}
  HEADERS ${apex_headers}
  DEPENDENCIES hpx_algorithms hpx_allocator_support hpx_assertion hpx_cache
  hpx_collectives hpx_concepts hpx_config hpx_datastructures hpx_format
  hpx_hardware hpx_hashing hpx_iterator_support hpx_logging hpx_preprocessor
  hpx_statistics hpx_testing hpx_thread_support hpx_timing hpx_type_support hpx_util
  FOLDER "Core/Dependencies")