File tree Expand file tree Collapse file tree 5 files changed +31
-30
lines changed Expand file tree Collapse file tree 5 files changed +31
-30
lines changed Original file line number Diff line number Diff line change 23
23
- uses : actions/checkout@v3
24
24
- run : ./tools/ci/markdown-link-verificator.sh
25
25
26
+ cmake-lint-check :
27
+ runs-on : ubuntu-20.04
28
+ steps :
29
+ - uses : actions/checkout@v3
30
+ - run : ./tools/ci/cmake-linter.sh
31
+
26
32
build-test-ubuntu :
27
33
runs-on : ubuntu-20.04
28
34
needs : pre-flight-check
Original file line number Diff line number Diff line change @@ -31,20 +31,7 @@ if(CMAKE_SYSTEM_NAME MATCHES Linux OR CMAKE_SYSTEM_NAME MATCHES Darwin)
31
31
option (BUILD_SHARED_LIBS "Create shared libraries by default" ON )
32
32
endif ()
33
33
34
- option (MAKE_UNIQUE_INCLUDEDIR
35
- "When ON headers are installed to a path ending with folders called \
36
- iceoryx/vX.Y.Z/ . This avoids include directory search order issues when \
37
- overriding this package from a merged catkin, ament, or colcon workspace."
38
- ON )
39
-
40
- if (MAKE_UNIQUE_INCLUDEDIR )
41
- set (_unique_dir "iceoryx/v${IOX_VERSION_STRING} " )
42
- if (PREFIX STREQUAL "" )
43
- set (PREFIX "${_unique_dir} " )
44
- else ()
45
- set (PREFIX "${PREFIX} /${_unique_dir} " )
46
- endif ()
47
- endif ()
34
+ iox_make_unique_includedir ()
48
35
49
36
#
50
37
########## build building-block library ##########
Original file line number Diff line number Diff line change @@ -28,21 +28,7 @@ if(CMAKE_SYSTEM_NAME MATCHES Linux OR CMAKE_SYSTEM_NAME MATCHES Darwin)
28
28
option (BUILD_SHARED_LIBS "Create shared libraries by default" ON )
29
29
endif ()
30
30
31
- option (MAKE_UNIQUE_INCLUDEDIR
32
- "When ON headers are installed to a path ending with folders called \
33
- iceoryx/vX.Y.Z/ . This avoids include directory search order issues when \
34
- overriding this package from a merged catkin, ament, or colcon workspace."
35
- ON )
36
-
37
- if (MAKE_UNIQUE_INCLUDEDIR )
38
- set (_unique_dir "iceoryx/v${IOX_VERSION_STRING} " )
39
- if (PREFIX STREQUAL "" )
40
- set (PREFIX "${_unique_dir} " )
41
- else ()
42
- set (PREFIX "${PREFIX} /${_unique_dir} " )
43
- endif ()
44
- endif ()
45
-
31
+ iox_make_unique_includedir ()
46
32
add_subdirectory (platform )
47
33
48
34
#
Original file line number Diff line number Diff line change @@ -112,6 +112,23 @@ Macro(install_package_files_and_export)
112
112
)
113
113
endMacro ()
114
114
115
+ Macro (iox_make_unique_includedir )
116
+ option (MAKE_UNIQUE_INCLUDEDIR
117
+ "When ON headers are installed to a path ending with folders called \
118
+ iceoryx/vX.Y.Z/ . This avoids include directory search order issues when \
119
+ overriding this package from a merged catkin, ament, or colcon workspace."
120
+ ON )
121
+
122
+ if (MAKE_UNIQUE_INCLUDEDIR )
123
+ set (_unique_dir "iceoryx/v${IOX_VERSION_STRING} " )
124
+ if (PREFIX STREQUAL "" )
125
+ set (PREFIX "${_unique_dir} " )
126
+ else ()
127
+ set (PREFIX "${PREFIX} /${_unique_dir} " )
128
+ endif ()
129
+ endif ()
130
+ endMacro ()
131
+
115
132
Macro (iox_set_rpath )
116
133
set (arguments TARGET RPATH )
117
134
cmake_parse_arguments (IOX "" "" "${arguments} " ${ARGN} )
@@ -211,7 +228,6 @@ Macro(iox_add_library)
211
228
cmake_parse_arguments (IOX "${switches} " "${arguments} " "${multiArguments} " ${ARGN} )
212
229
213
230
if ( NOT IOX_NO_PACKAGE_SETUP )
214
- message ("setup ${IOX_TARGET} " )
215
231
setup_package_name_and_create_files (
216
232
NAME ${IOX_TARGET}
217
233
NAMESPACE ${IOX_NAMESPACE}
Original file line number Diff line number Diff line change @@ -40,6 +40,12 @@ performCmakeLinting()
40
40
echo " please do not use the cmake command \" add_executable\" , use \" iox_add_executable\" instead"
41
41
EXIT_CODE=1
42
42
fi
43
+
44
+ if ! [[ $( cat $FILE | grep " MAKE_UNIQUE_INCLUDEDIR" | wc -l) == " 0" ]]
45
+ then
46
+ echo " please do not access MAKE_UNIQUE_INCLUDEDIR directly, use \" iox_make_unique_includedir()\" and access it via the variable \" PREFIX\" "
47
+ EXIT_CODE=1
48
+ fi
43
49
done
44
50
}
45
51
You can’t perform that action at this time.
0 commit comments