Skip to content

nautilus: cmake: set empty RPATH for some test executables#40619

Merged
yuriw merged 3 commits intoceph:nautilusfrom
smithfarm:wip-50164-nautilus
Apr 12, 2021
Merged

nautilus: cmake: set empty RPATH for some test executables#40619
yuriw merged 3 commits intoceph:nautilusfrom
smithfarm:wip-50164-nautilus

Conversation

@smithfarm
Copy link
Contributor

@smithfarm smithfarm commented Apr 6, 2021

tchaikov and others added 3 commits April 6, 2021 14:27
some executables like ceph_test_mon_memory_target does not link against
gtest or gmock, so no need to link agains them.

Signed-off-by: Kefu Chai <kchai@redhat.com>
(cherry picked from commit 45bab2c)
some executables like ceph_test_mon_memory_target do not link against
libraries built from source tree, like librados and libceph-common. so
cmake does not set RPATH for them. hence cmake complains like:

before this change, `CMAKE_INSTALL_RPATH` is set globally. so cmake is
asked to rewrite the RPATH for all installed targets. but this is not
needed. as some executables do not link against libceph-common. hence,
cmake complains when installing them, like:

CMake Error at src/test/mon/cmake_install.cmake:90 (file):
  file RPATH_CHANGE could not write new RPATH:
    /usr/lib64/ceph
   to the file:
    /home/abuild/rpmbuild/BUILDROOT/ceph-15.0.0-4347.g85a07b9.x86_64/usr/bin/ceph_test_log_rss_usage
   No valid ELF RPATH or RUNPATH entry exists in the file;

after this change, `SKIP_RPATH` is set for those executables which do
not link against any libraries created from ceph source tree. so we can
avoid setting the RPATH for these executables when `make install`.

the same applies to libceph-common.

Fixes: https://tracker.ceph.com/issues/41524
Signed-off-by: Kefu Chai <kchai@redhat.com>
(cherry picked from commit 6170815)
Fixes: https://tracker.ceph.com/issues/41524
Signed-off-by: Nathan Cutler <ncutler@suse.com>
(cherry picked from commit 51a1c62)
@smithfarm smithfarm added this to the nautilus milestone Apr 6, 2021
@smithfarm smithfarm requested a review from tchaikov April 6, 2021 12:28
@smithfarm
Copy link
Contributor Author

Addressing a build failure seen in OBS.

@smithfarm
Copy link
Contributor Author

The following tests FAILED:
	153 - unittest_osdscrub (Failed)

@smithfarm
Copy link
Contributor Author

jenkins test make check

Copy link
Member

@ideepika ideepika left a comment

Choose a reason for hiding this comment

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

@yuriw yuriw merged commit 57df519 into ceph:nautilus Apr 12, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants