mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-08-06 00:48:18 -07:00
app-backup/bareos: drop -Werror; fix build with GCC 12
Closes: https://bugs.gentoo.org/841734 Signed-off-by: Sam James <sam@gentoo.org>
This commit is contained in:
@@ -143,6 +143,8 @@ src_test() {
|
||||
src_prepare() {
|
||||
# fix gentoo platform support
|
||||
eapply -p1 "${FILESDIR}/${PN}-21-cmake-gentoo.patch"
|
||||
eapply "${FILESDIR}/${PN}-21.1.2-werror.patch"
|
||||
eapply "${FILESDIR}/${PN}-21.1.2-no-automagic-ccache.patch"
|
||||
|
||||
# fix missing DESTDIR in symlink creation
|
||||
sed -i '/bareos-symlink-default-db-backend.cmake/d' "${S}/core/src/cats/CMakeLists.txt"
|
||||
|
||||
@@ -0,0 +1,25 @@
|
||||
--- a/core/CMakeLists.txt
|
||||
+++ b/core/CMakeLists.txt
|
||||
@@ -44,12 +44,6 @@ set(CMAKE_INSTALL_DEFAULT_COMPONENT_NAME common)
|
||||
|
||||
include(GNUInstallDirs)
|
||||
|
||||
-find_program(CCACHE_FOUND ccache)
|
||||
-if(CCACHE_FOUND)
|
||||
- set_property(GLOBAL PROPERTY RULE_LAUNCH_COMPILE ccache)
|
||||
- set_property(GLOBAL PROPERTY RULE_LAUNCH_LINK ccache)
|
||||
-endif(CCACHE_FOUND)
|
||||
-
|
||||
# switch on CXX 17 Support
|
||||
#
|
||||
set(CMAKE_CXX_STANDARD 17)
|
||||
@@ -584,9 +578,6 @@ message(STATUS "CMAKE_SUPPRESS_REGENERATION: " ${CMAKE_SUPPRESS_REGENERATION})
|
||||
# A simple way to get switches to the compiler is to use ADD_DEFINITIONS(). But
|
||||
# there are also two variables exactly for this purpose:
|
||||
|
||||
-# wheter or not
|
||||
-message(STATUS "CCACHE_FOUND: " ${CCACHE_FOUND})
|
||||
-
|
||||
# Choose the type of build. Example: SET(CMAKE_BUILD_TYPE Debug)
|
||||
message(STATUS "CMAKE_BUILD_TYPE: " ${CMAKE_BUILD_TYPE})
|
||||
|
||||
23
app-backup/bareos/files/bareos-21.1.2-werror.patch
Normal file
23
app-backup/bareos/files/bareos-21.1.2-werror.patch
Normal file
@@ -0,0 +1,23 @@
|
||||
https://bugs.gentoo.org/841734
|
||||
--- a/core/CMakeLists.txt
|
||||
+++ b/core/CMakeLists.txt
|
||||
@@ -96,7 +96,7 @@ if(NOT ${CMAKE_SYSTEM_NAME} MATCHES "SunOS")
|
||||
-Werror=format-security compiler_error_format_security
|
||||
)
|
||||
if(${compiler_error_format_security})
|
||||
- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Werror=format-security")
|
||||
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wformat-security")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
@@ -353,8 +353,8 @@ if(developer)
|
||||
add_definitions("-DDEVELOPER=1")
|
||||
endif()
|
||||
|
||||
-set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Werror -Wall")
|
||||
-set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Werror -Wall")
|
||||
+set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall")
|
||||
+set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall")
|
||||
|
||||
include(BareosSetVariableDefaults)
|
||||
option(ENABLE_BCONSOLE "Build bconsole binary" ON)
|
||||
Reference in New Issue
Block a user