Skip to content

Threads::Threads errors when building a project based on BT.CPP #492

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

Closed
robertokcanale opened this issue Jan 6, 2023 · 9 comments
Closed
Assignees
Labels
bug Something isn't working

Comments

@robertokcanale
Copy link

Hello, I am trying to run a simple project while following the documentation.

@robertokcanale
Copy link
Author

I get tht following code after running
cmake .. inside the build folder

-- Configuring done
CMake Error at CMakeLists.txt:8 (add_executable):
  Target "BT_tutorials" links to target "Threads::Threads" but the target was
  not found.  Perhaps a find_package() call is missing for an IMPORTED
  target, or an ALIAS target is missing?


CMake Error at CMakeLists.txt:8 (add_executable):
  Target "BT_tutorials" links to target "Threads::Threads" but the target was
  not found.  Perhaps a find_package() call is missing for an IMPORTED
  target, or an ALIAS target is missing?


-- Generating done
CMake Generate step failed.  Build files cannot be regenerated correctly.

@yendiDev
Copy link

yendiDev commented Jan 6, 2023

I get tht following code after running cmake .. inside the build folder

-- Configuring done
CMake Error at CMakeLists.txt:8 (add_executable):
  Target "BT_tutorials" links to target "Threads::Threads" but the target was
  not found.  Perhaps a find_package() call is missing for an IMPORTED
  target, or an ALIAS target is missing?


CMake Error at CMakeLists.txt:8 (add_executable):
  Target "BT_tutorials" links to target "Threads::Threads" but the target was
  not found.  Perhaps a find_package() call is missing for an IMPORTED
  target, or an ALIAS target is missing?


-- Generating done
CMake Generate step failed.  Build files cannot be regenerated correctly.

Same error

@facontidavide
Copy link
Collaborator

Is this main branch? I will have a look

@facontidavide facontidavide self-assigned this Feb 3, 2023
@facontidavide facontidavide added the bug Something isn't working label Feb 3, 2023
@facontidavide
Copy link
Collaborator

Can your confirm your build system? catkin/ colcon/ vanilla cmake ?

@facontidavide
Copy link
Collaborator

hello?

@yendiDev
Copy link

yendiDev commented Mar 3, 2023

Hi,
I have not worked on this in a while.
I will boot up the project and communicate over the weekend

@mnumanuyar
Copy link

mnumanuyar commented Mar 7, 2023

I have the same error. this might be relevant : https://stackoverflow.com/a/60480361/2113878

@mnumanuyar
Copy link

mnumanuyar commented Mar 7, 2023

to be precise i get this error not during cmake of BT but during cmake of a dummy project that uses BT. error is :

-- Configuring done
CMake Error at /usr/local/lib/cmake/behaviortree_cpp/behaviortree_cppTargets.cmake:61 (set_target_properties):
  The link interface of target "BT::behaviortree_cpp" contains:

    Threads::Threads

  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/behaviortree_cpp/behaviortree_cppConfig.cmake:27 (include)
  CMakeLists.txt:6 (find_package)


-- Generating done
CMake Generate step failed.  Build files cannot be regenerated correctly.

facontidavide added a commit that referenced this issue Mar 7, 2023
@facontidavide
Copy link
Collaborator

Pushed a solution

@facontidavide facontidavide changed the title When I build the System, I encounter the following erro Threads::Threads errors when building a project based on BT.CPP Mar 18, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants