From 4d2c1004e96faad1179591b4409a75965af43985 Mon Sep 17 00:00:00 2001 From: dundargoc <33953936+dundargoc@users.noreply.github.com> Date: Wed, 8 Feb 2023 11:00:16 +0100 Subject: build: prefer -D = over -D= (#22164) This makes it easier to see that -D is referring to the entire "=", rather than only . It also help syntax highlighters highlight built-in variables. --- cmake.deps/cmake/BuildMsgpack.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'cmake.deps/cmake/BuildMsgpack.cmake') diff --git a/cmake.deps/cmake/BuildMsgpack.cmake b/cmake.deps/cmake/BuildMsgpack.cmake index 431420fb62..b1a77ee835 100644 --- a/cmake.deps/cmake/BuildMsgpack.cmake +++ b/cmake.deps/cmake/BuildMsgpack.cmake @@ -7,8 +7,8 @@ ExternalProject_Add(msgpack DOWNLOAD_NO_PROGRESS TRUE DOWNLOAD_DIR ${DEPS_DOWNLOAD_DIR}/msgpack CMAKE_ARGS ${DEPS_CMAKE_ARGS} - -DMSGPACK_BUILD_TESTS=OFF - -DMSGPACK_BUILD_EXAMPLES=OFF + -D MSGPACK_BUILD_TESTS=OFF + -D MSGPACK_BUILD_EXAMPLES=OFF CMAKE_CACHE_ARGS ${DEPS_CMAKE_CACHE_ARGS}) list(APPEND THIRD_PARTY_DEPS msgpack) -- cgit From 5ffd3d035dfd3d7f6e66edbaa895b98792ba3de3 Mon Sep 17 00:00:00 2001 From: dundargoc <33953936+dundargoc@users.noreply.github.com> Date: Sun, 19 Feb 2023 21:11:27 +0100 Subject: build: build all dependencies in parallel (#22329) Previously, all targets were connected in one main target called third-party in order to remove any potentially conflicting shared library. We can make each dependency target independent of each other by only removing shared libraries from luajit and msgpack in their own targets, as only these has unwanted shared libraries. --- cmake.deps/cmake/BuildMsgpack.cmake | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'cmake.deps/cmake/BuildMsgpack.cmake') diff --git a/cmake.deps/cmake/BuildMsgpack.cmake b/cmake.deps/cmake/BuildMsgpack.cmake index b1a77ee835..ef7568ae0a 100644 --- a/cmake.deps/cmake/BuildMsgpack.cmake +++ b/cmake.deps/cmake/BuildMsgpack.cmake @@ -11,4 +11,10 @@ ExternalProject_Add(msgpack -D MSGPACK_BUILD_EXAMPLES=OFF CMAKE_CACHE_ARGS ${DEPS_CMAKE_CACHE_ARGS}) -list(APPEND THIRD_PARTY_DEPS msgpack) +if (NOT MSVC) + add_custom_target(clean_shared_libraries_msgpack ALL + COMMAND ${CMAKE_COMMAND} + -D REMOVE_FILE_GLOB=${DEPS_INSTALL_DIR}/lib/${CMAKE_SHARED_LIBRARY_PREFIX}*${CMAKE_SHARED_LIBRARY_SUFFIX}* + -P ${PROJECT_SOURCE_DIR}/cmake/RemoveFiles.cmake) + add_dependencies(clean_shared_libraries_msgpack msgpack) +endif() -- cgit From 0007aa50bd3d54259bb4ae717c114f5524ec59fa Mon Sep 17 00:00:00 2001 From: dundargoc <33953936+dundargoc@users.noreply.github.com> Date: Sat, 4 Mar 2023 00:30:07 +0100 Subject: build: unset variables ending with "URL" if USE_EXISTING_SRC_DIR is ON This will reduce required boilerplate, but more importantly it will automatically unset variables ending on URL. This will help people needing to avoid to unset the URL variable each time a new dependency is added. It is possible that this may remove a non-download variable ending on "URL" in the future, however, the risk of this is likely much lower than the risk of someone forgetting to unset the variable. --- cmake.deps/cmake/BuildMsgpack.cmake | 3 --- 1 file changed, 3 deletions(-) (limited to 'cmake.deps/cmake/BuildMsgpack.cmake') diff --git a/cmake.deps/cmake/BuildMsgpack.cmake b/cmake.deps/cmake/BuildMsgpack.cmake index ef7568ae0a..82993c265d 100644 --- a/cmake.deps/cmake/BuildMsgpack.cmake +++ b/cmake.deps/cmake/BuildMsgpack.cmake @@ -1,6 +1,3 @@ -if(USE_EXISTING_SRC_DIR) - unset(MSGPACK_URL) -endif() ExternalProject_Add(msgpack URL ${MSGPACK_URL} URL_HASH SHA256=${MSGPACK_SHA256} -- cgit From f4d83ac1e22e55a12895e5945680d90ee7c09b85 Mon Sep 17 00:00:00 2001 From: dundargoc <33953936+dundargoc@users.noreply.github.com> Date: Sun, 5 Mar 2023 15:21:46 +0100 Subject: build: consistently use the provided option paths We provide options such as "DEPS_BIN_DIR" for the user to set, but only sometimes use them. This makes binaries and other files to be spread out if the user defines a custom DEPS_BIN_DIR location. --- cmake.deps/cmake/BuildMsgpack.cmake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'cmake.deps/cmake/BuildMsgpack.cmake') diff --git a/cmake.deps/cmake/BuildMsgpack.cmake b/cmake.deps/cmake/BuildMsgpack.cmake index 82993c265d..c9033be1ae 100644 --- a/cmake.deps/cmake/BuildMsgpack.cmake +++ b/cmake.deps/cmake/BuildMsgpack.cmake @@ -11,7 +11,7 @@ ExternalProject_Add(msgpack if (NOT MSVC) add_custom_target(clean_shared_libraries_msgpack ALL COMMAND ${CMAKE_COMMAND} - -D REMOVE_FILE_GLOB=${DEPS_INSTALL_DIR}/lib/${CMAKE_SHARED_LIBRARY_PREFIX}*${CMAKE_SHARED_LIBRARY_SUFFIX}* + -D REMOVE_FILE_GLOB=${DEPS_LIB_DIR}/${CMAKE_SHARED_LIBRARY_PREFIX}*${CMAKE_SHARED_LIBRARY_SUFFIX}* -P ${PROJECT_SOURCE_DIR}/cmake/RemoveFiles.cmake) add_dependencies(clean_shared_libraries_msgpack msgpack) endif() -- cgit From 10860164778327c0009f6efc8e020308cadb13a2 Mon Sep 17 00:00:00 2001 From: dundargoc <33953936+dundargoc@users.noreply.github.com> Date: Sat, 13 May 2023 12:12:29 +0200 Subject: build: cmake cleanup - Simplify error checking when using execute_process. - Set BUILD_SHARED_LIBS to OFF when building dependencies. This is normally not needed, but msgpack interprets an unset BUILD_SHARED_LIBS to build a shared library, which is the opposite of the cmake behavior. - Move function check_lua_module to Util.cmake. - Remove unnecessary code. - Make variable naming more consistent --- cmake.deps/cmake/BuildMsgpack.cmake | 8 -------- 1 file changed, 8 deletions(-) (limited to 'cmake.deps/cmake/BuildMsgpack.cmake') diff --git a/cmake.deps/cmake/BuildMsgpack.cmake b/cmake.deps/cmake/BuildMsgpack.cmake index c9033be1ae..f63559e6b4 100644 --- a/cmake.deps/cmake/BuildMsgpack.cmake +++ b/cmake.deps/cmake/BuildMsgpack.cmake @@ -7,11 +7,3 @@ ExternalProject_Add(msgpack -D MSGPACK_BUILD_TESTS=OFF -D MSGPACK_BUILD_EXAMPLES=OFF CMAKE_CACHE_ARGS ${DEPS_CMAKE_CACHE_ARGS}) - -if (NOT MSVC) - add_custom_target(clean_shared_libraries_msgpack ALL - COMMAND ${CMAKE_COMMAND} - -D REMOVE_FILE_GLOB=${DEPS_LIB_DIR}/${CMAKE_SHARED_LIBRARY_PREFIX}*${CMAKE_SHARED_LIBRARY_SUFFIX}* - -P ${PROJECT_SOURCE_DIR}/cmake/RemoveFiles.cmake) - add_dependencies(clean_shared_libraries_msgpack msgpack) -endif() -- cgit From 99b8a343e197cdec53f752e1cce01ae25eb45c12 Mon Sep 17 00:00:00 2001 From: dundargoc Date: Mon, 20 Nov 2023 12:42:54 +0100 Subject: fixup: quick update, squash later --- cmake.deps/cmake/BuildMsgpack.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'cmake.deps/cmake/BuildMsgpack.cmake') diff --git a/cmake.deps/cmake/BuildMsgpack.cmake b/cmake.deps/cmake/BuildMsgpack.cmake index f63559e6b4..f60bdad5c9 100644 --- a/cmake.deps/cmake/BuildMsgpack.cmake +++ b/cmake.deps/cmake/BuildMsgpack.cmake @@ -1,9 +1,9 @@ ExternalProject_Add(msgpack URL ${MSGPACK_URL} URL_HASH SHA256=${MSGPACK_SHA256} - DOWNLOAD_NO_PROGRESS TRUE DOWNLOAD_DIR ${DEPS_DOWNLOAD_DIR}/msgpack CMAKE_ARGS ${DEPS_CMAKE_ARGS} -D MSGPACK_BUILD_TESTS=OFF -D MSGPACK_BUILD_EXAMPLES=OFF - CMAKE_CACHE_ARGS ${DEPS_CMAKE_CACHE_ARGS}) + CMAKE_CACHE_ARGS ${DEPS_CMAKE_CACHE_ARGS} + ${EXTERNALPROJECT_OPTIONS}) -- cgit