Skip to content

Commit 7790b55

Browse files
committed
CMake: cleanups, add dummy initialization function
1 parent 7f96b43 commit 7790b55

File tree

1 file changed

+9
-3
lines changed

1 file changed

+9
-3
lines changed

cmake/LSLCMake.cmake

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
# Common functions and settings for LSL
22

3+
# Dummy function that should be called after find_package(LSL)
4+
# Does nothing at the moment, but the entire code below should be within this
5+
# function so it's not executed by accident
6+
macro(LSLAPP_Setup_Boilerplate)
7+
endmacro()
8+
39
message(STATUS "Included LSL CMake helpers, rev. 12, ${CMAKE_CURRENT_LIST_DIR}")
410
option(LSL_DEPLOYAPPLIBS "Copy library dependencies (at the moment Qt + liblsl) to the installation dir" ON)
511

@@ -276,7 +282,7 @@ macro(LSLGenerateCPackConfig)
276282
# CPack configuration
277283
string(TOUPPER "${PROJECT_NAME}" PROJECT_NAME_UPPER)
278284
if(NOT PROJECT_DESCRIPTION)
279-
set(PROJECT_DESCRIPTION "${PROJECT_NAME} ${PROJECT_VERSION_MAJOR}.${PROJECT_VERSION_MINOR}.${PROJECT_VERSION_PATCH}")
285+
set(PROJECT_DESCRIPTION "${PROJECT_NAME} ${PROJECT_VERSION}")
280286
endif()
281287
set("CPACK_COMPONENT_${PROJECT_NAME_UPPER}_DESCRIPTION" "${PROJECT_DESCRIPTION}" CACHE INTERNAL "CPack Description")
282288

@@ -309,7 +315,7 @@ macro(LSLGenerateCPackConfig)
309315
set(CPACK_SET_DESTDIR 1)
310316
set(CPACK_INSTALL_PREFIX "/usr")
311317
set(CPACK_DEBIAN_PACKAGE_MAINTAINER "Tristan Stenner <[email protected]>")
312-
set(CPACK_DEBIAN_ENABLE_COMPONENT_DEPENDS 1)
318+
set(CPACK_DEBIAN_ENABLE_COMPONENT_DEPENDS ON)
313319
set(CPACK_DEB_COMPONENT_INSTALL ON)
314320
set(CPACK_DEBIAN_PACKAGE_PRIORITY optional)
315321
set(CPACK_DEBIAN_LIBLSL_PACKAGE_SHLIBDEPS ON)
@@ -331,7 +337,7 @@ macro(LSLGenerateCPackConfig)
331337
get_cmake_property(CPACK_COMPONENTS_ALL COMPONENTS)
332338
foreach(component ${CPACK_COMPONENTS_ALL})
333339
string(TOUPPER ${component} COMPONENT)
334-
set(LSL_CPACK_FILENAME "${component}-${PROJECT_VERSION_MAJOR}.${PROJECT_VERSION_MINOR}.${PROJECT_VERSION_PATCH}-${LSL_OS}")
340+
set(LSL_CPACK_FILENAME "${component}-${PROJECT_VERSION}-${LSL_OS}")
335341
get_property(LSLDEPENDS GLOBAL PROPERTY "LSLDEPENDS_${component}")
336342
if(LSLDEPENDS)
337343
list(REMOVE_DUPLICATES LSLDEPENDS)

0 commit comments

Comments
 (0)