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

CMake error about boost #1

Open
ze-n-g opened this issue Mar 22, 2023 · 0 comments
Open

CMake error about boost #1

ze-n-g opened this issue Mar 22, 2023 · 0 comments

Comments

@ze-n-g
Copy link

ze-n-g commented Mar 22, 2023

After installed, an error occurs:

CMake Error at /usr/local/lib/cmake/iipl/iiplTargets.cmake:61 (set_target_properties):
  The link interface of target "iipl" contains:

    Boost::filesystem

  but the target was not found.  Possible reasons include:

    * There is a typo in the target name.
    * A find_package call is missing for an IMPORTED target.
    * An ALIAS target is missing.

Call Stack (most recent call first):
  /usr/local/lib/cmake/iipl/iiplConfig.cmake:27 (include)
  CMakeLists.txt:26 (find_package)

A naive solution: add boost in CMakeList.txt before find_package(iipl REQUIRED)

find_package(Boost COMPONENTS filesystem)
# reference: https://stackoverflow.com/questions/53647596/building-boost-from-sources-on-linux
if(Boost_FOUND)
    message(STATUS "Boost found")
    include_directories(${BOOST_INCLUDE_DIRS})
else()
    message(STATUS "Boost not found")
endif()
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

1 participant