Skip to content

Commit 2ff622d

Browse files
committed
Fix build with cmake 4
1 parent 6920940 commit 2ff622d

File tree

3 files changed

+25
-2
lines changed

3 files changed

+25
-2
lines changed

CMakeLists.txt

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,6 @@ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-attributes -Wno-deprecated-declarat
2424
add_compile_definitions(_FILE_OFFSET_BITS=64 _LARGEFILE64_SOURCE)
2525

2626
# Dependencies
27-
add_subdirectory(vendor/zopfli EXCLUDE_FROM_ALL)
28-
2927
find_package(BISON REQUIRED)
3028
find_package(EXPAT REQUIRED)
3129
find_package(FLEX REQUIRED)
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
From 68abb8acdb3a6a6fea82a1fc8e9fdbe87e7038dc Mon Sep 17 00:00:00 2001
2+
From: Biswapriyo Nath <[email protected]>
3+
Date: Wed, 1 Jan 2025 00:00:00 +0000
4+
Subject: [PATCH] zopfli: Bump minimum cmake version for cmake 4
5+
6+
---
7+
CMakeLists.txt | 2 +-
8+
1 file changed, 1 insertion(+), 1 deletion(-)
9+
10+
diff --git a/CMakeLists.txt b/CMakeLists.txt
11+
index e56fd2f..0561b79 100644
12+
--- a/CMakeLists.txt
13+
+++ b/CMakeLists.txt
14+
@@ -1,4 +1,4 @@
15+
-cmake_minimum_required(VERSION 2.8.11)
16+
+cmake_minimum_required(VERSION 3.12.0)
17+
18+
project(Zopfli)
19+
20+
--
21+
2.49.0
22+

vendor/CMakeLists.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ set(android-vendored
1111
libziparchive
1212
aidl
1313
core
14+
zopfli
1415
)
1516

1617
option(ANDROID_BUILD_TOOLS_PATCH_VENDOR "Enable patching vendor projects using patches directory" ON)
@@ -31,6 +32,8 @@ if(ANDROID_BUILD_TOOLS_PATCH_VENDOR AND EXISTS "${ANDROID_PATCH_DIR}/")
3132
endforeach(v)
3233
endif()
3334

35+
add_subdirectory(zopfli EXCLUDE_FROM_ALL)
36+
3437
include(aapt.cmake)
3538
include(aapt2.cmake)
3639
include(aidl.cmake)

0 commit comments

Comments
 (0)