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

check and link against libatomic #172

Merged
merged 1 commit into from
Aug 30, 2019
Merged

check and link against libatomic #172

merged 1 commit into from
Aug 30, 2019

Conversation

christianrauch
Copy link
Contributor

Link against libatomic. Fixes #171 .

@christianrauch
Copy link
Contributor Author

christianrauch commented Jul 29, 2019

@clalancette @sloretz Can you have a look at this?
I would like to propose the same linking fix for a couple of other packages (and the dashing branch) where I encountered the same libatomic linking issue.

@nuclearsandwich nuclearsandwich added the in review Waiting for review (Kanban column) label Aug 1, 2019
Copy link
Contributor

@sloretz sloretz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR. Downstream packages will need atomic too. I think this can be done automatically by adding a call to ament_export_library_names() here.

if(HAVE_LIBATOMICS)
  ament_export_library_names(atomic)
endif()

Signed-off-by: Christian Rauch <Rauch.Christian@gmx.de>
@christianrauch
Copy link
Contributor Author

I got an error with ament_export_library_names(atomic), but ament_export_libraries(atomic) did work.

@sloretz
Copy link
Contributor

sloretz commented Aug 29, 2019

CI (building all, testing just rcutils)

  • Linux Build Status
  • Linux-aarch64 Build Status
  • macOS Build Status
  • Windows Build Status

@sloretz
Copy link
Contributor

sloretz commented Aug 30, 2019

Thanks for the PR @christianrauch !

@sloretz sloretz merged commit 67f064e into ros2:master Aug 30, 2019
@christianrauch christianrauch deleted the atomics branch August 30, 2019 00:25
@dirk-thomas
Copy link
Member

Every package using rcutils reports the following CMake warning for me locally:

CMake Warning at <ws>/install/rcutils/share/rcutils/cmake/ament_cmake_export_libraries-extras.cmake:116 (message):
  Package 'rcutils' exports library 'atomic' which couldn't be found
Call Stack (most recent call first):
  <ws>/install/rcutils/share/rcutils/cmake/rcutilsConfig.cmake:38 (include)
  CMakeLists.txt:34 (find_package)

@sloretz
Copy link
Contributor

sloretz commented Aug 30, 2019

Every package using rcutils reports the following CMake warning for me locally:

Looks like I forgot to include a repos URL in CI. Re-running to check if it affects the build farm too

EDIT:
I see the cmake warning in the nightly, reverting

https://ci.ros2.org/view/nightly/job/nightly_linux_debug/1298/consoleText

sloretz added a commit that referenced this pull request Aug 30, 2019
This reverts commit 67f064e.

Signed-off-by: Shane Loretz <sloretz@osrfoundation.org>
sloretz added a commit that referenced this pull request Aug 30, 2019
This reverts commit 67f064e.

Signed-off-by: Shane Loretz <sloretz@osrfoundation.org>
sloretz pushed a commit that referenced this pull request Aug 30, 2019
Signed-off-by: Christian Rauch <Rauch.Christian@gmx.de>

Signed-off-by: Shane Loretz <sloretz@osrfoundation.org>
sloretz pushed a commit that referenced this pull request Mar 8, 2020
Signed-off-by: Christian Rauch <Rauch.Christian@gmx.de>

Signed-off-by: Shane Loretz <sloretz@osrfoundation.org>
sloretz added a commit that referenced this pull request Mar 9, 2020
* check and link against libatomic (#172)

Signed-off-by: Christian Rauch <Rauch.Christian@gmx.de>

Signed-off-by: Shane Loretz <sloretz@osrfoundation.org>

* Export -latomic linker flag

Signed-off-by: Shane Loretz <sloretz@openrobotics.org>

Co-authored-by: Christian Rauch <Rauch.Christian@gmx.de>
sloretz added a commit that referenced this pull request Mar 13, 2020
* check and link against libatomic (#172)

Signed-off-by: Christian Rauch <Rauch.Christian@gmx.de>

Signed-off-by: Shane Loretz <sloretz@osrfoundation.org>

* Export -latomic linker flag

Signed-off-by: Shane Loretz <sloretz@openrobotics.org>

Co-authored-by: Christian Rauch <Rauch.Christian@gmx.de>
Signed-off-by: Shane Loretz <sloretz@osrfoundation.org>
sloretz added a commit that referenced this pull request Mar 13, 2020
* check and link against libatomic (#172)

Signed-off-by: Christian Rauch <Rauch.Christian@gmx.de>

Signed-off-by: Shane Loretz <sloretz@osrfoundation.org>

* Export -latomic linker flag

Signed-off-by: Shane Loretz <sloretz@openrobotics.org>

Co-authored-by: Christian Rauch <Rauch.Christian@gmx.de>
Signed-off-by: Shane Loretz <sloretz@osrfoundation.org>

Co-authored-by: Christian Rauch <Rauch.Christian@gmx.de>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in review Waiting for review (Kanban column)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Linking error (test_atomics_executable) on Raspbian/armv6l
4 participants