From 16c6f23791e2b3093b6074fe7bab6a9393ffc0b8 Mon Sep 17 00:00:00 2001 From: Dennis Luxen Date: Sat, 10 Dec 2022 20:50:32 +0100 Subject: [PATCH 1/2] Fix CMake warning CMake Warning (dev) at /usr/share/cmake-3.24/Modules/FindPackageHandleStandardArgs.cmake:438 (message): The package name passed to `find_package_handle_standard_args` (PkgConfig) does not match the name of the calling package (Lua). This can lead to problems in calling code that expects `find_package` result variables (e.g., `_FOUND`) to follow a certain pattern. Call Stack (most recent call first): /usr/share/cmake-3.24/Modules/FindPkgConfig.cmake:99 (find_package_handle_standard_args) cmake/FindLua.cmake:39 (include) CMakeLists.txt:571 (find_package) This warning is for project developers. Use -Wno-dev to suppress it. --- cmake/FindLua.cmake | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/cmake/FindLua.cmake b/cmake/FindLua.cmake index 237dca8e6..d8cc01e8a 100644 --- a/cmake/FindLua.cmake +++ b/cmake/FindLua.cmake @@ -36,7 +36,10 @@ # This is because, the lua location is not standardized and may exist in # locations other than lua/ -include(FindPkgConfig) +if(NOT PKG_CONFIG_FOUND) + include(CMakeFindDependencyMacro) + find_dependency(PkgConfig) +endif() unset(_lua_include_subdirs) unset(_lua_library_names) From 898cbe8da4ab10048740cc41c2c61411726a63df Mon Sep 17 00:00:00 2001 From: Dennis Luxen Date: Sat, 10 Dec 2022 21:50:24 +0100 Subject: [PATCH 2/2] Install PkgConfig on Docker build image --- docker/Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docker/Dockerfile b/docker/Dockerfile index 094bedee7..a44d3319f 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -5,7 +5,7 @@ RUN mkdir -p /src && mkdir -p /opt RUN apt-get update && \ apt-get -y --no-install-recommends install ca-certificates cmake make git gcc g++ libbz2-dev libxml2-dev wget \ - libzip-dev libboost1.74-all-dev lua5.4 liblua5.4-dev -o APT::Install-Suggests=0 -o APT::Install-Recommends=0 + libzip-dev libboost1.74-all-dev lua5.4 liblua5.4-dev pkg-config -o APT::Install-Suggests=0 -o APT::Install-Recommends=0 RUN NPROC=${BUILD_CONCURRENCY:-$(nproc)} && \ ldconfig /usr/local/lib && \