Skip to content

Commit afd56d2

Browse files
authored
Use relative install paths in CMake (#1387)
This fixes an error when building https://github.com/gazebo-release/sdformat_vendor/ in the ROS buildfarm where `CMAKE_STAGING_PREFIX` is used Signed-off-by: Addisu Z. Taddese <[email protected]>
1 parent 33662e1 commit afd56d2

File tree

13 files changed

+20
-20
lines changed

13 files changed

+20
-20
lines changed

conf/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,4 +24,4 @@ configure_file(
2424

2525
# Install the yaml configuration files in an unversioned location.
2626
install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${PROJECT_NAME}.yaml
27-
DESTINATION ${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_DATAROOTDIR}/gz/)
27+
DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/gz/)

sdf/1.0/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,4 +27,4 @@ set (sdfs
2727
world.sdf
2828
)
2929

30-
install(FILES ${sdfs} DESTINATION ${CMAKE_INSTALL_FULL_DATAROOTDIR}/sdformat${PROJECT_VERSION_MAJOR}/1.0/)
30+
install(FILES ${sdfs} DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/sdformat${PROJECT_VERSION_MAJOR}/1.0/)

sdf/1.10/CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -84,5 +84,5 @@ add_custom_target(schema1_10 ALL DEPENDS ${SDF_SCHEMA})
8484

8585
set_source_files_properties(${SDF_SCHEMA} PROPERTIES GENERATED TRUE)
8686

87-
install(FILES 1_9.convert ${sdfs} DESTINATION ${CMAKE_INSTALL_FULL_DATAROOTDIR}/sdformat${PROJECT_VERSION_MAJOR}/1.10)
88-
install(FILES ${SDF_SCHEMA} DESTINATION ${CMAKE_INSTALL_FULL_DATAROOTDIR}/sdformat${PROJECT_VERSION_MAJOR}/1.10)
87+
install(FILES 1_9.convert ${sdfs} DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/sdformat${PROJECT_VERSION_MAJOR}/1.10)
88+
install(FILES ${SDF_SCHEMA} DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/sdformat${PROJECT_VERSION_MAJOR}/1.10)

sdf/1.11/CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -85,5 +85,5 @@ add_custom_target(schema1_11 ALL DEPENDS ${SDF_SCHEMA})
8585

8686
set_source_files_properties(${SDF_SCHEMA} PROPERTIES GENERATED TRUE)
8787

88-
install(FILES 1_10.convert ${sdfs} DESTINATION ${CMAKE_INSTALL_FULL_DATAROOTDIR}/sdformat${PROJECT_VERSION_MAJOR}/1.11)
89-
install(FILES ${SDF_SCHEMA} DESTINATION ${CMAKE_INSTALL_FULL_DATAROOTDIR}/sdformat${PROJECT_VERSION_MAJOR}/1.11)
88+
install(FILES 1_10.convert ${sdfs} DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/sdformat${PROJECT_VERSION_MAJOR}/1.11)
89+
install(FILES ${SDF_SCHEMA} DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/sdformat${PROJECT_VERSION_MAJOR}/1.11)

sdf/1.2/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,4 +28,4 @@ set (sdfs
2828
world.sdf
2929
)
3030

31-
install(FILES ${sdfs} DESTINATION ${CMAKE_INSTALL_FULL_DATAROOTDIR}/sdformat${PROJECT_VERSION_MAJOR}/1.2)
31+
install(FILES ${sdfs} DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/sdformat${PROJECT_VERSION_MAJOR}/1.2)

sdf/1.3/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,4 +29,4 @@ set (sdfs
2929
world.sdf
3030
)
3131

32-
install(FILES ${sdfs} DESTINATION ${CMAKE_INSTALL_FULL_DATAROOTDIR}/sdformat${PROJECT_VERSION_MAJOR}/1.3)
32+
install(FILES ${sdfs} DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/sdformat${PROJECT_VERSION_MAJOR}/1.3)

sdf/1.4/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,4 +44,4 @@ set (sdfs
4444
world.sdf
4545
)
4646

47-
install(FILES ${sdfs} DESTINATION ${CMAKE_INSTALL_FULL_DATAROOTDIR}/sdformat${PROJECT_VERSION_MAJOR}/1.4)
47+
install(FILES ${sdfs} DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/sdformat${PROJECT_VERSION_MAJOR}/1.4)

sdf/1.5/CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -78,5 +78,5 @@ add_custom_target(schema1_5 ALL DEPENDS ${SDF_SCHEMA})
7878

7979
set_source_files_properties(${SDF_SCHEMA} PROPERTIES GENERATED TRUE)
8080

81-
install(FILES 1_4.convert ${sdfs} DESTINATION ${CMAKE_INSTALL_FULL_DATAROOTDIR}/sdformat${PROJECT_VERSION_MAJOR}/1.5)
82-
install(FILES ${SDF_SCHEMA} DESTINATION ${CMAKE_INSTALL_FULL_DATAROOTDIR}/sdformat${PROJECT_VERSION_MAJOR}/1.5)
81+
install(FILES 1_4.convert ${sdfs} DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/sdformat${PROJECT_VERSION_MAJOR}/1.5)
82+
install(FILES ${SDF_SCHEMA} DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/sdformat${PROJECT_VERSION_MAJOR}/1.5)

sdf/1.6/CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -82,5 +82,5 @@ add_custom_target(schema1_6 ALL DEPENDS ${SDF_SCHEMA})
8282

8383
set_source_files_properties(${SDF_SCHEMA} PROPERTIES GENERATED TRUE)
8484

85-
install(FILES 1_5.convert ${sdfs} DESTINATION ${CMAKE_INSTALL_FULL_DATAROOTDIR}/sdformat${PROJECT_VERSION_MAJOR}/1.6)
86-
install(FILES ${SDF_SCHEMA} DESTINATION ${CMAKE_INSTALL_FULL_DATAROOTDIR}/sdformat${PROJECT_VERSION_MAJOR}/1.6)
85+
install(FILES 1_5.convert ${sdfs} DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/sdformat${PROJECT_VERSION_MAJOR}/1.6)
86+
install(FILES ${SDF_SCHEMA} DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/sdformat${PROJECT_VERSION_MAJOR}/1.6)

sdf/1.7/CMakeLists.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -83,5 +83,5 @@ add_custom_target(schema1_7 ALL DEPENDS ${SDF_SCHEMA})
8383

8484
set_source_files_properties(${SDF_SCHEMA} PROPERTIES GENERATED TRUE)
8585

86-
install(FILES 1_6.convert ${sdfs} DESTINATION ${CMAKE_INSTALL_FULL_DATAROOTDIR}/sdformat${PROJECT_VERSION_MAJOR}/1.7)
87-
install(FILES ${SDF_SCHEMA} DESTINATION ${CMAKE_INSTALL_FULL_DATAROOTDIR}/sdformat${PROJECT_VERSION_MAJOR}/1.7)
86+
install(FILES 1_6.convert ${sdfs} DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/sdformat${PROJECT_VERSION_MAJOR}/1.7)
87+
install(FILES ${SDF_SCHEMA} DESTINATION ${CMAKE_INSTALL_DATAROOTDIR}/sdformat${PROJECT_VERSION_MAJOR}/1.7)

0 commit comments

Comments
 (0)