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

FindHPX.cmake problems #487

maciekab opened this issue Aug 8, 2012 · 3 comments


None yet
3 participants
Copy link

commented Aug 8, 2012

When building external applications, the behavior of installed FindHPX.cmake is inconsistent with the HPX documentation:

  1. After configuration using cmake script from the documentation, the compilation gets aborted due to inability to find HPX headers. Adding include_directories(${HPX_INCLUDE_DIR}) to cmake script fixes the issue, but the correct setup of include paths is supposed to be done automatically by add_hpx_executable().
  2. Linking breaks due to missing library search path(s). Again, adding link_directories(${HPX_LIBRARY_DIR}) fixes it, but it really should be done by add_hpx_executable().
  3. It seems that gets installed by default, yet it is not added to the list of default libraries to link with.

@ghost ghost assigned brycelelbach Aug 8, 2012


This comment has been minimized.

Copy link

commented Aug 9, 2012

Here is an example CMake file (send by Maciej) showing a corrected version for hello_world

cmake_minimum_required(VERSION 2.8 FATAL_ERROR)

set(HPX_INSTALL_DIR "/home/maciek/packages/hpx")


  add_hpx_executable(hello_world ESSENTIAL SOURCES hello_world.cpp COMPONENT_DEPENDENCIES iostreams)
  message(FATAL_ERROR "could not find HPX")

This comment has been minimized.

Copy link

commented Aug 9, 2012

3.) doesn't make any sense. If you want to use a component, you must link against it.


This comment has been minimized.

Copy link

commented Aug 20, 2012

The need for include_directories and link_directories has been documented as of 869e130. Closing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.