mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2026-02-01 14:02:24 +01:00
community/ceph: do not force CMAKE_BUILD_TYPE option
Previous CMAKE_BUILD_TYPE was debug which created massive libraries and binaries without the -s flag
This commit is contained in:
parent
400e837b74
commit
0fe6f5feed
36
community/ceph/44-cmake-buildtype.patch
Normal file
36
community/ceph/44-cmake-buildtype.patch
Normal file
@ -0,0 +1,36 @@
|
||||
commit a7e3ece459111d157a20d05de3a92cf4dab6bde6
|
||||
Author: Kefu Chai <kchai@redhat.com>
|
||||
Date: Thu Jul 1 15:24:50 2021 +0800
|
||||
|
||||
cmake: set CMAKE_BUILD_TYPE only if .git exists
|
||||
|
||||
distros intend to fine tune the CFLAGS and CXXFLAGS by themselves, see
|
||||
|
||||
- https://git.alpinelinux.org/abuild/tree/abuild.conf
|
||||
- https://wiki.archlinux.org/title/CMake_package_guidelines#CMake_undesired_behaviors
|
||||
- https://github.com/Debian/debhelper/blob/5d1bb29841043d8e47ebbdd043e6cd086cad508e/lib/Debian/Debhelper/Buildsystem/cmake.pm#L16
|
||||
|
||||
so instead of setting a CMAKE_BUILD_TYPE when building from a
|
||||
dist tarball, let's just leave it empty.
|
||||
|
||||
Signed-off-by: Kefu Chai <kchai@redhat.com>
|
||||
|
||||
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
|
||||
index 760a2ceb0c..6f35e87f90 100644
|
||||
--- a/src/CMakeLists.txt
|
||||
+++ b/src/CMakeLists.txt
|
||||
@@ -156,12 +156,8 @@ elseif(CMAKE_CXX_COMPILER_ID STREQUAL Clang)
|
||||
endif()
|
||||
endif(CMAKE_CXX_COMPILER_ID STREQUAL GNU)
|
||||
|
||||
-if(NOT CMAKE_BUILD_TYPE)
|
||||
- if(EXISTS "${CMAKE_SOURCE_DIR}/.git")
|
||||
- set(default_build_type "Debug")
|
||||
- else()
|
||||
- set(default_build_type "RelWithDebInfo")
|
||||
- endif()
|
||||
+if(DEFINED CMAKE_BUILD_TYPE OR EXISTS "${CMAKE_SOURCE_DIR}/.git")
|
||||
+ set(default_build_type "Debug")
|
||||
set(CMAKE_BUILD_TYPE "${default_build_type}" CACHE
|
||||
STRING "Default BUILD_TYPE is Debug, other options are: RelWithDebInfo, Release, and MinSizeRel." FORCE)
|
||||
endif()
|
||||
@ -120,6 +120,7 @@ source="https://download.ceph.com/tarballs/ceph_$pkgver.orig.tar.gz
|
||||
37-fix_tests.patch
|
||||
42-no-virtualenvs.patch
|
||||
43-aarch64-erasure.patch
|
||||
44-cmake-buildtype.patch
|
||||
44-LogClock.h.patch
|
||||
44-staticcast.patch
|
||||
44-node_modules.patch
|
||||
@ -210,6 +211,7 @@ build() {
|
||||
export NPM_REGISTRY=https://registry.npmjs.org
|
||||
|
||||
cmake -B build \
|
||||
-DCMAKE_BUILD_TYPE=None \
|
||||
-DLUA_LIBRARIES=/usr/lib/lua"$_lua"/liblua.so \
|
||||
-DALLOCATOR=libc \
|
||||
-DCMAKE_INSTALL_PREFIX=/usr \
|
||||
@ -546,6 +548,7 @@ abb3cab9c01cc3d6d42a9858678059a8c9c43bda2649bf97b489fdc205eb10ae27f9fb7302062e0f
|
||||
908169df45177240d2dcc721fe1637c521789aed56c3b3400ed3ba9c73d93634e4369258fb0e0395dc27053be26229ee8f370e445f0e69d01f551a710a29d407 37-fix_tests.patch
|
||||
2584ceb68b50423fac386ce83ad194f22aa574e11b99916e712471bacba28486d2639a8fe63d97c5697f33270c0de99db1f0e76eb43b14cc47c6de7da6903fde 42-no-virtualenvs.patch
|
||||
aea43c2a99f16f7fccf33aeca3565077bb2274816ca68db64b672addc85bde5c479bc9ad0fb33dbde79c9390f9acf1d98545e20e311e40dd428dad5ed02f0651 43-aarch64-erasure.patch
|
||||
741a0f83ecf1a8298bcc8cb8ab9f25f6d27cfe69367150a8821fde445efe20a255b3f1296dc92003a2956475e3f15f3d0ac920be280dd03ac3f311c754dbb890 44-cmake-buildtype.patch
|
||||
e47d736d3ab1417758fc5f92798a77272b978799e6d9f0728b2036d6cc5975c6c10f8dc4590c2e1cb31e1e9fc03c582394b30727e315a6889de524fc8bf95369 44-LogClock.h.patch
|
||||
f89c913a53e2806c59508d26f5dc72abb428c7e4e3b7c1aeb6eaf92744ea9a13cac2f00a2ac90f91ad7682f66d876a5fffedd10feeceecd71a944793581da443 44-staticcast.patch
|
||||
85d0009b0d1442af81d115402cdbd17667d85314030e1748a4656c1ee798b02efdcff41ccb374a6b63f7bf012bf1756b61e75c5d2b6399c329a6e62024ad0011 44-node_modules.patch
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user