This file is indexed.

/usr/share/mrpt/MRPTConfig.cmake is in libmrpt-dev 1:1.5.5-1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
# =========================================================================
#  The Mobile Robot Programming Toolkit (MRPT) CMake configuration file
#
#             ** File generated automatically, do not modify **
#
#  Usage from an external project:
#   In your CMakeLists.txt, add these lines:
#
#    FIND_PACKAGE( MRPT REQUIRED )  # Default: Use mrpt-slam & mrpt-topography
#     or
#    FIND_PACKAGE( MRPT REQUIRED base vision hwdrivers ... )
#
#    TARGET_LINK_LIBRARIES(MY_TARGET_NAME ${MRPT_LIBRARIES})
#
#
#   The libraries or "modules" which can be included are
#   (see the full list and description in: http://www.mrpt.org/Libraries )
#     - base           --> libmrpt-base
#     - opengl         --> libmrpt-opengl
#     - hwdrivers      --> libmrpt-hwdrivers
#     - reactivenav    --> libmrpt-reactivenav
#     - hmtslam        --> libmrpt-hmtslam
#
#   This file will define the following variables:
#    - MRPT_LIBRARIES        : The list of libraries to links against.
#    - MRPT_LIBS             : Like MRPT_LIBRARIES, for backward compat.
#    - MRPT_INCLUDE_DIRS     : The list of include directories
#    - MRPT_LINK_DIRECTORIES : The list of link directories
#    - MRPT_VERSION          : The MRPT version (e.g. "1.0.0").
#    - MRPT_VERSION_{MAJOR,MINOR,PATCH}: 3 variables for the version parts
#
#   Optional input variables:
#    - (Windows only) MRPT_DONT_USE_DBG_LIBS: If defined at input, before the
#         "FIND_PACKAGE(MRPT...)", and set to "1", will not search for `-dbg`
#         libraries when linking in "Debug" CMake builds.
#
# =========================================================================

# MRPT version numbers:
SET(MRPT_VERSION 1.5.5)
SET(MRPT_VERSION_MAJOR 1)
SET(MRPT_VERSION_MINOR 5)
SET(MRPT_VERSION_PATCH 5)


# Extract the directory where *this* file has been installed (determined at cmake run-time)
get_filename_component(THIS_MRPT_CONFIG_PATH "${CMAKE_CURRENT_LIST_FILE}" PATH)

# MRPT source dir
SET(MRPT_SOURCE_DIR "/usr")
SET(MRPT_LIBS_INCL_DIR "/usr/include/mrpt")

# MRPT binary dir
SET(MRPT_DIR "/usr")

# MRPT include directory for "config.h"
SET(MRPT_CONFIG_DIR "/usr/include/mrpt/mrpt-config/")

#MESSAGE(STATUS "MRPT_FIND_COMPONENTS: ${MRPT_FIND_COMPONENTS}")

# MRPT include directories
SET(MRPT_INCLUDE_DIRS "")

# MRPT library directories
SET(MRPT_LINK_DIRECTORIES "")

# ======================================================
# Include directories where Eigen3 headers are... if
#  they are not embedded under mrpt-base headers:
# ======================================================
IF (NOT 1 OR NOT 0)
	INCLUDE_DIRECTORIES("/usr/include/eigen3")
	LIST(APPEND MRPT_INCLUDE_DIRS "/usr/include/eigen3")
ENDIF ()

# If using GCC and -Wall, eigen3 headers raise some warnings: silent them:
IF(CMAKE_COMPILER_IS_GNUCXX)
	SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-long-long -Wno-variadic-macros")
ENDIF()

# ======================================================
# Include directories to add to the user project:
# ======================================================
INCLUDE_DIRECTORIES(${MRPT_CONFIG_DIR})
LIST(APPEND MRPT_INCLUDE_DIRS ${MRPT_CONFIG_DIR})

# OpenCV library:
IF(1)    # CMAKE_MRPT_HAS_OPENCV_SYSTEM
	# Using system opencv lib:
	# Users must link against OpenCV only if MRPT is not a dynamic library:
	IF (NOT 1)  # CMAKE_MRPT_BUILD_SHARED_LIB
		LINK_DIRECTORIES("")  # OPENCV_LIBDIR
		LIST(APPEND MRPT_LINK_DIRECTORIES "")
	ENDIF ()
ENDIF()

# Suitesparse lib (only if present as a system lib)
IF(1)    # CMAKE_MRPT_HAS_SUITESPARSE_SYSTEM
	INCLUDE_DIRECTORIES("/usr/include/suitesparse") # SuiteSparse_INCLUDE_DIRS
	LIST(APPEND MRPT_INCLUDE_DIRS "/usr/include/suitesparse")
ENDIF()



# ==========================================================
# Default "MRPT_FIND_COMPONENTS" -> "slam" + "topography",
#  for backward compatibility (< MRPT 0.9.0)
# ==========================================================
IF ("${MRPT_FIND_COMPONENTS}" STREQUAL "")
	SET(MRPT_FIND_COMPONENTS slam topography)
ENDIF ()

# ======================================================
# The list of MRPT libs/modules in this build
# ======================================================
SET(ALL_MRPT_LIBS "mrpt-base;mrpt-bayes;mrpt-detectors;mrpt-graphs;mrpt-graphslam;mrpt-gui;mrpt-hmtslam;mrpt-hwdrivers;mrpt-kinematics;mrpt-maps;mrpt-nav;mrpt-reactivenav;mrpt-obs;mrpt-opengl;mrpt-slam;mrpt-tfest;mrpt-scanmatching;mrpt-topography;mrpt-vision")
#  Start of DECLARE_LIBS_DEPS
 set_property(GLOBAL PROPERTY "mrpt-base_LIB_DEPS" "")
 set_property(GLOBAL PROPERTY "mrpt-bayes_LIB_DEPS" "mrpt-base")
 set_property(GLOBAL PROPERTY "mrpt-detectors_LIB_DEPS" "mrpt-vision;mrpt-maps;mrpt-gui;mrpt-slam;mrpt-base;mrpt-opengl;mrpt-obs;mrpt-graphs")
 set_property(GLOBAL PROPERTY "mrpt-graphs_LIB_DEPS" "mrpt-opengl;mrpt-base")
 set_property(GLOBAL PROPERTY "mrpt-graphslam_LIB_DEPS" "mrpt-base;mrpt-graphs;mrpt-gui;mrpt-maps;mrpt-obs;mrpt-opengl;mrpt-slam;mrpt-vision")
 set_property(GLOBAL PROPERTY "mrpt-gui_LIB_DEPS" "mrpt-opengl;mrpt-base")
 set_property(GLOBAL PROPERTY "mrpt-hmtslam_LIB_DEPS" "mrpt-slam;mrpt-graphslam;mrpt-graphs;mrpt-vision;mrpt-maps;mrpt-base;mrpt-obs;mrpt-opengl;mrpt-gui")
 set_property(GLOBAL PROPERTY "mrpt-hwdrivers_LIB_DEPS" "mrpt-base;mrpt-maps;mrpt-obs;mrpt-gui;mrpt-opengl;mrpt-maps;mrpt-vision;mrpt-graphs")
 set_property(GLOBAL PROPERTY "mrpt-kinematics_LIB_DEPS" "mrpt-opengl;mrpt-base")
 set_property(GLOBAL PROPERTY "mrpt-maps_LIB_DEPS" "mrpt-obs;mrpt-graphs;mrpt-opengl;mrpt-base")
 set_property(GLOBAL PROPERTY "mrpt-nav_LIB_DEPS" "mrpt-graphs;mrpt-maps;mrpt-kinematics;mrpt-graphs;mrpt-obs;mrpt-opengl;mrpt-base")
 set_property(GLOBAL PROPERTY "mrpt-reactivenav_LIB_DEPS" "mrpt-nav;mrpt-graphs;mrpt-maps;mrpt-obs;mrpt-opengl;mrpt-base")
 set_property(GLOBAL PROPERTY "mrpt-obs_LIB_DEPS" "mrpt-opengl;mrpt-base")
 set_property(GLOBAL PROPERTY "mrpt-opengl_LIB_DEPS" "mrpt-base")
 set_property(GLOBAL PROPERTY "mrpt-slam_LIB_DEPS" "mrpt-bayes;mrpt-graphs;mrpt-vision;mrpt-tfest;mrpt-maps;mrpt-obs;mrpt-opengl;mrpt-base")
 set_property(GLOBAL PROPERTY "mrpt-tfest_LIB_DEPS" "mrpt-base")
 set_property(GLOBAL PROPERTY "mrpt-scanmatching_LIB_DEPS" "mrpt-tfest;mrpt-base")
 set_property(GLOBAL PROPERTY "mrpt-topography_LIB_DEPS" "mrpt-base;mrpt-obs;mrpt-opengl;mrpt-tfest")
 set_property(GLOBAL PROPERTY "mrpt-vision_LIB_DEPS" "mrpt-obs;mrpt-opengl;mrpt-base;mrpt-opengl")

#  End of DECLARE_LIBS_DEPS

#  Start of DECLARE_LIBS_HDR_ONLY
 set_property(GLOBAL PROPERTY "mrpt-base_LIB_IS_HEADERS_ONLY" "0")
 set_property(GLOBAL PROPERTY "mrpt-bayes_LIB_IS_HEADERS_ONLY" "1")
 set_property(GLOBAL PROPERTY "mrpt-detectors_LIB_IS_HEADERS_ONLY" "0")
 set_property(GLOBAL PROPERTY "mrpt-graphs_LIB_IS_HEADERS_ONLY" "0")
 set_property(GLOBAL PROPERTY "mrpt-graphslam_LIB_IS_HEADERS_ONLY" "0")
 set_property(GLOBAL PROPERTY "mrpt-gui_LIB_IS_HEADERS_ONLY" "0")
 set_property(GLOBAL PROPERTY "mrpt-hmtslam_LIB_IS_HEADERS_ONLY" "0")
 set_property(GLOBAL PROPERTY "mrpt-hwdrivers_LIB_IS_HEADERS_ONLY" "0")
 set_property(GLOBAL PROPERTY "mrpt-kinematics_LIB_IS_HEADERS_ONLY" "0")
 set_property(GLOBAL PROPERTY "mrpt-maps_LIB_IS_HEADERS_ONLY" "0")
 set_property(GLOBAL PROPERTY "mrpt-nav_LIB_IS_HEADERS_ONLY" "0")
 set_property(GLOBAL PROPERTY "mrpt-reactivenav_LIB_IS_HEADERS_ONLY" "1")
 set_property(GLOBAL PROPERTY "mrpt-obs_LIB_IS_HEADERS_ONLY" "0")
 set_property(GLOBAL PROPERTY "mrpt-opengl_LIB_IS_HEADERS_ONLY" "0")
 set_property(GLOBAL PROPERTY "mrpt-slam_LIB_IS_HEADERS_ONLY" "0")
 set_property(GLOBAL PROPERTY "mrpt-tfest_LIB_IS_HEADERS_ONLY" "0")
 set_property(GLOBAL PROPERTY "mrpt-scanmatching_LIB_IS_HEADERS_ONLY" "1")
 set_property(GLOBAL PROPERTY "mrpt-topography_LIB_IS_HEADERS_ONLY" "0")
 set_property(GLOBAL PROPERTY "mrpt-vision_LIB_IS_HEADERS_ONLY" "0")

#  End of DECLARE_LIBS_HDR_ONLY

# Add hierarchical dependencies of MRPT libraries,
#  and replace "base"->"mrpt-base", etc.
# ================================================
SET(FINAL_LIST_COMPONENTS "")
FOREACH(_MOD ${MRPT_FIND_COMPONENTS})
	STRING(TOLOWER ${_MOD} _MOD)
	SET(_NAM "mrpt-${_MOD}")
	get_property(_LIB_DEP GLOBAL PROPERTY "${_NAM}_LIB_DEPS")

	# Add deps:
	IF (NOT "${_LIB_DEP}" STREQUAL "")
		#MESSAGE(STATUS "ADD: ${_LIB_DEP}")
		LIST(APPEND FINAL_LIST_COMPONENTS ${_LIB_DEP})
	ENDIF ()

	# Add lib itself:
	IF (NOT "${_NAM}" STREQUAL "mrpt-core")
		LIST(APPEND FINAL_LIST_COMPONENTS ${_NAM})
	ENDIF ()
ENDFOREACH()
SET(MRPT_FIND_COMPONENTS ${FINAL_LIST_COMPONENTS})
list(REMOVE_DUPLICATES MRPT_FIND_COMPONENTS)

# ======================================================
# Check:
#  All libraries must exist in the MRPT build.
#  Compare "MRPT_FIND_COMPONENTS" against "ALL_MRPT_LIBS":
# ======================================================
#MESSAGE(STATUS "LIBS: ${ALL_MRPT_LIBS}")
FOREACH(MRPTLIB ${MRPT_FIND_COMPONENTS})
	list(FIND ALL_MRPT_LIBS "${MRPTLIB}" _LIB_IDX)
	IF (_LIB_IDX EQUAL -1)
		MESSAGE(FATAL_ERROR "ERROR: MRPT_FIND_COMPONENTS contains '${MRPTLIB}', not built in mrpt (built ones: ${ALL_MRPT_LIBS})")
	ENDIF ()
ENDFOREACH()
#MESSAGE(STATUS "MRPT_FIND_COMPONENTS: ${MRPT_FIND_COMPONENTS}")


# ======================================================
#   MRPT list of libraries the user should link against:
# ======================================================
SET(MRPT_LIBRARIES "")

SET(MRPT_COMP_HWDRIVERS 0  INTERNAL)
# Process the list:
FOREACH(MRPTLIB ${MRPT_FIND_COMPONENTS})
	STRING(TOLOWER ${MRPTLIB} MRPTLIB)
	STRING(REGEX REPLACE "mrpt-(.*)" "\\1" MRPTLIB ${MRPTLIB})

	# The include dir:
	INCLUDE_DIRECTORIES("${MRPT_LIBS_INCL_DIR}/${MRPTLIB}/include")
	LIST(APPEND MRPT_INCLUDE_DIRS "${MRPT_LIBS_INCL_DIR}/${MRPTLIB}/include")

	# List of libs to link against:
	# If the required lib is header-only, don't add to the list of libs to link!
	get_property(_LIB_HDRONLY GLOBAL PROPERTY "mrpt-${MRPTLIB}_LIB_IS_HEADERS_ONLY")
	IF(NOT _LIB_HDRONLY)
		IF(WIN32 AND NOT MRPT_DONT_USE_DBG_LIBS)
			LIST(APPEND MRPT_LIBRARIES
				optimized mrpt-${MRPTLIB}
				debug     mrpt-${MRPTLIB})
		ELSE()
			LIST(APPEND MRPT_LIBRARIES  mrpt-${MRPTLIB})
		ENDIF()
	ENDIF()

	IF(MRPTLIB MATCHES "hwdrivers")
		SET(MRPT_COMP_HWDRIVERS 1)
	ENDIF()
ENDFOREACH()

# Handle special cases:
# libs for ffmpeg in win32 (only if building static libs)
IF(MRPT_COMP_HWDRIVERS AND NOT 1)
	IF( MATCHES "ON")  # MRPT_HAS_FFMPEG_WIN32
		FOREACH(FFMPGLIB ";avcodec;avformat;avutil;swscale")
			LIST(APPEND MRPT_LIBRARIES general "${FFMPGLIB}")
		ENDFOREACH()
	ENDIF()
ENDIF()

# ======================================================
# Support for wxWidgets: We only need wx libs at user
#  link time if MRPT libs are static.
# ======================================================
IF(1 AND NOT 1)  # CMAKE_MRPT_HAS_WXWIDGETS AND NOT CMAKE_MRPT_BUILD_SHARED_LIB_ONOFF
	SET(wxWidgets_USE_LIBS base core gl adv aui)

	IF(CMAKE_BUILD_TYPE MATCHES "Debug")
		SET(wxWidgets_USE_DEBUG "ON")
	ELSE()
		SET(wxWidgets_USE_REL_AND_DBG "ON")
	ENDIF()

	FIND_PACKAGE(wxWidgets)
	IF(wxWidgets_FOUND)
		# Include wxWidgets macros
		INCLUDE(${wxWidgets_USE_FILE})
		# ${wxWidgets_LIBRARIES}  will contain the libraries that should be added through TARGET_LINK_LIBRARIES(...)
		LINK_DIRECTORIES(${wxWidgets_LIBRARY_DIRS})
		LIST(APPEND MRPT_LINK_DIRECTORIES ${wxWidgets_LIBRARY_DIRS})

		IF(MSVC)
			ADD_DEFINITIONS(-DwxUSE_NO_MANIFEST=1)
		ENDIF()

		LIST(APPEND MRPT_LIBRARIES ${wxWidgets_LIBRARIES})
		IF(MSVC)
			ADD_DEFINITIONS(-D_CRT_SECURE_NO_WARNINGS)
		ENDIF()
	ELSE()
		MESSAGE("Warning: MRPT was compiled with wxWidgets, but CMake is not able to locate wxWidgets automatically. Please, set wxWidgets_ROOT_DIR to the lib directory manually.\n You can safely ignore this warning if you don't intend to use MRPT GUI classes or wxWidgets directly from your application.")
	ENDIF()
ENDIF()

# ======================================================
# Support for Bumblebee
# ======================================================
IF(WIN32 AND NOT 1)
	IF(0)   # CMAKE_MRPT_HAS_BUMBLEBEE
		LINK_DIRECTORIES("/lib")
		LINK_DIRECTORIES("/lib")
		LIST(APPEND MRPT_LINK_DIRECTORIES "/lib")
		LIST(APPEND MRPT_LINK_DIRECTORIES "/lib")
	ENDIF()
ENDIF()

# ======================================================
# Link directories to add to the user project:
# ======================================================
LINK_DIRECTORIES(${MRPT_DIR}/lib)
LIST(APPEND MRPT_LINK_DIRECTORIES ${MRPT_DIR}/lib)

SET(MRPT_LIBS ${MRPT_LIBRARIES}) # For backward compatible code