diff --git a/CMakeLists.txt b/CMakeLists.txt index e11ba9863..1abb193de 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -2,6 +2,7 @@ cmake_minimum_required(VERSION 3.16) # Options option(IMHEX_OFFLINE_BUILD "Enable offline build" OFF) +option(IMHEX_IGNORE_BAD_CLONE "Disabled the bad clone prevention checks" OFF) option(IMHEX_PATTERNS_PULL_MASTER "Download latest files from master branch of the ImHex-Patterns repo" OFF) # Basic compiler and cmake configurations diff --git a/cmake/build_helpers.cmake b/cmake/build_helpers.cmake index 76548e272..b4658f17b 100644 --- a/cmake/build_helpers.cmake +++ b/cmake/build_helpers.cmake @@ -294,7 +294,11 @@ function(loadVersion version) set(${version} ${read_version} PARENT_SCOPE) endfunction() -macro(detectBadClone) +function(detectBadClone) + if (IMHEX_IGNORE_BAD_CLONE) + return() + endif() + file (GLOB EXTERNAL_DIRS "lib/external/*") foreach (EXTERNAL_DIR ${EXTERNAL_DIRS}) file(GLOB RESULT "${EXTERNAL_DIR}/*") @@ -303,7 +307,7 @@ macro(detectBadClone) message(FATAL_ERROR "External dependency ${EXTERNAL_DIR} is empty!\nMake sure to correctly clone ImHex using the --recurse-submodules git option or initialize the submodules manually.") endif() endforeach () -endmacro() +endfunction() macro(setVariableInParent variable value) get_directory_property(hasParent PARENT_DIRECTORY) diff --git a/lib/external/pattern_language b/lib/external/pattern_language index 13d92f5d2..451abb159 160000 --- a/lib/external/pattern_language +++ b/lib/external/pattern_language @@ -1 +1 @@ -Subproject commit 13d92f5d2d8e8f039d8e3c21ba13ccfc5538c0cc +Subproject commit 451abb159b41571acd345406751c7a95629709f3 diff --git a/lib/libimhex/include/hex/helpers/socket.hpp b/lib/libimhex/include/hex/helpers/socket.hpp index 9c1cc63fa..982217def 100644 --- a/lib/libimhex/include/hex/helpers/socket.hpp +++ b/lib/libimhex/include/hex/helpers/socket.hpp @@ -14,6 +14,7 @@ #else #include #include + #include #include #include