Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix cmake 3.31 warnings #1973

Merged
merged 2 commits into from
Nov 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Makefile.defs
Original file line number Diff line number Diff line change
Expand Up @@ -806,7 +806,7 @@ endif
# Native & cross definitions.
define cmake_toolchain

cmake_minimum_required(VERSION 3.5.1)
cmake_minimum_required(VERSION 3.15)

# CMake Cross ToolChain config file. Adapted from Debian's dpkg-cross ;).
# c.f., https://cmake.org/cmake/help/latest/manual/cmake-toolchains.7.html#cross-compiling-toolchain
Expand Down
9 changes: 8 additions & 1 deletion thirdparty/cmake_modules/koreader_external_project.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,11 @@ if(POLICY CMP0116)
cmake_policy(SET CMP0116 NEW)
endif()

# Stricter `add_custom_command()` (rejects invalid argument(s)).
if(POLICY CMP0175)
cmake_policy(SET CMP0175 NEW)
endif()

# Crappy macOS command line utilities strike again…
set(PRINTF_QS "%q")
if(CMAKE_HOST_APPLE)
Expand Down Expand Up @@ -65,8 +70,10 @@ function(external_project_step NAME)
DEPENDS $<TARGET_PROPERTY:${PROJECT_NAME}-${NAME},DEPENDS>
VERBATIM
${_USES_TERMINAL}
WORKING_DIRECTORY ${_WORKING_DIRECTORY}
)
if(DEFINED _WORKING_DIRECTORY)
list(APPEND SPEC WORKING_DIRECTORY ${_WORKING_DIRECTORY})
endif()
if(DEFINED _DEPFILE)
list(APPEND SPEC DEPFILE ${_DEPFILE})
endif()
Expand Down