diff --git a/bacula-9.4.0-g++-options.patch b/bacula-9.4.0-g++-options.patch deleted file mode 100644 index 1759ac8..0000000 --- a/bacula-9.4.0-g++-options.patch +++ /dev/null @@ -1,30 +0,0 @@ -diff -Naur bacula-9.4.0.old/autoconf/configure.in bacula-9.4.0/autoconf/configure.in ---- bacula-9.4.0.old/autoconf/configure.in 2018-12-16 11:30:25.000000000 +0100 -+++ bacula-9.4.0/autoconf/configure.in 2019-01-12 15:31:43.259970610 +0100 -@@ -2985,11 +2985,6 @@ - AC_DEFINE(FDLIBS) - - CFLAGS=${CFLAGS--O} -- --if test x$have_gcc = xyes ; then -- CPPFLAGS="$CPPFLAGS -x c++ -fno-strict-aliasing -fno-exceptions -fno-rtti" -- CFLAGS="$CFLAGS -x c++ -fno-strict-aliasing -fno-exceptions -fno-rtti" --fi - LDFLAGS=${LDFLAGS--O} - CPPFLAGS="$CPPFLAGS" - CFLAGS="$CFLAGS" -diff -Naur bacula-9.4.0.old/configure bacula-9.4.0/configure ---- bacula-9.4.0.old/configure 2018-12-16 11:30:25.000000000 +0100 -+++ bacula-9.4.0/configure 2019-01-12 15:31:43.262970667 +0100 -@@ -30883,11 +30883,6 @@ - - - CFLAGS=${CFLAGS--O} -- --if test x$have_gcc = xyes ; then -- CPPFLAGS="$CPPFLAGS -x c++ -fno-strict-aliasing -fno-exceptions -fno-rtti" -- CFLAGS="$CFLAGS -x c++ -fno-strict-aliasing -fno-exceptions -fno-rtti" --fi - LDFLAGS=${LDFLAGS--O} - CPPFLAGS="$CPPFLAGS" - CFLAGS="$CFLAGS" diff --git a/bacula-9.4.1-g++-options.patch b/bacula-9.4.1-g++-options.patch new file mode 100644 index 0000000..a65cda0 --- /dev/null +++ b/bacula-9.4.1-g++-options.patch @@ -0,0 +1,15 @@ +diff -Naur bacula-9.4.1.old/autoconf/configure.in bacula-9.4.1/autoconf/configure.in +--- bacula-9.4.1.old/autoconf/configure.in 2019-01-13 11:43:36.011952506 +0100 ++++ bacula-9.4.1/autoconf/configure.in 2019-01-13 11:44:42.663167694 +0100 +@@ -2986,11 +2986,6 @@ + AC_DEFINE(FDLIBS) + + CFLAGS=${CFLAGS--O} +- +-if test x$have_gcc = xyes ; then +- CPPFLAGS="$CPPFLAGS -x c++ -fno-strict-aliasing -fno-exceptions -fno-rtti" +- CFLAGS="$CFLAGS -x c++ -fno-strict-aliasing -fno-exceptions -fno-rtti" +-fi + LDFLAGS=${LDFLAGS--O} + CPPFLAGS="$CPPFLAGS" + CFLAGS="$CFLAGS" diff --git a/bacula-9.4.1-s3-configure.patch b/bacula-9.4.1-s3-configure.patch new file mode 100644 index 0000000..0c173e9 --- /dev/null +++ b/bacula-9.4.1-s3-configure.patch @@ -0,0 +1,32 @@ +diff -Naur bacula-9.4.1.old/autoconf/configure.in bacula-9.4.1/autoconf/configure.in +--- bacula-9.4.1.old/autoconf/configure.in 2019-01-13 11:45:34.176106888 +0100 ++++ bacula-9.4.1/autoconf/configure.in 2019-01-13 11:46:13.992832830 +0100 +@@ -1887,6 +1887,20 @@ + + AC_CHECK_FUNC(accept4, [AC_DEFINE(HAVE_ACCEPT4, 1, [Define to 1 if you have the 'accept4' function.])]) + ++dnl --------------------------------------------------- ++dnl Check for S3 support/directory (default on) ++dnl --------------------------------------------------- ++dnl this allows you to turn it completely off ++ ++AC_ARG_ENABLE(s3, ++ AC_HELP_STRING([--disable-s3], [disable S3 support @<:@default=yes@:>@]), ++ [ ++ if test x$enableval = xno; then ++ support_s3=no ++ fi ++ ] ++) ++ + S3_INC= + S3_LIBS= + S3_LDFLAGS= +@@ -3624,6 +3638,7 @@ + Encryption support: ${support_crypto} + ZLIB support: ${have_zlib} + LZO support: ${have_lzo} ++ S3 support: ${have_libs3} + enable-smartalloc: ${support_smartalloc} + enable-lockmgr: ${support_lockmgr} + bat support: ${support_bat} diff --git a/bacula.spec b/bacula.spec index 420d164..4a0d128 100644 --- a/bacula.spec +++ b/bacula.spec @@ -3,7 +3,7 @@ Name: bacula Version: 9.4.1 -Release: 1%{?dist} +Release: 2%{?dist} Summary: Cross platform network backup for Linux, Unix, Mac and Windows # See LICENSE for details License: AGPLv3 with exceptions @@ -37,19 +37,23 @@ Patch6: %{name}-5.2.13-logwatch.patch Patch7: %{name}-9.4.0-non-free-code.patch # desktop-file-install not supported on RHEL 6 Patch8: %{name}-9.0.2-desktop.patch -Patch9: %{name}-9.4.0-g++-options.patch +Patch9: %{name}-9.4.1-g++-options.patch +# https://sources.debian.org/patches/bacula/9.4.1-1/upstream/add-libs3-checks/ +Patch10: %{name}-9.4.1-s3-configure.patch # Original patch removed by mistake, upstream is not willing to add it again: # http://www.bacula.org/git/cgit.cgi/bacula/commit/?h=Branch-7.0&id=51b3b98fb77ab3c0decee455cc6c4d2eb3c5303a # Without this, there is no library providing the correct shared object name # required by the daemons. # http://bugs.bacula.org/view.php?id=2084 -Patch11: %{name}-7.0.4-autoconf.patch +Patch12: %{name}-7.0.4-autoconf.patch BuildRequires: desktop-file-utils BuildRequires: perl-generators BuildRequires: sed +BuildRequires: autoconf +BuildRequires: automake BuildRequires: gcc BuildRequires: gcc-c++ BuildRequires: glibc-devel @@ -322,6 +326,13 @@ Provides check_bacula support for Nagios. cp %{SOURCE2} %{SOURCE3} %{SOURCE4} %{SOURCE5} . +# Regenerate configure +pushd autoconf +sed -i -r 's/(hardcode_into_libs)=.*$/\1=no/' libtool/libtool.m4 +aclocal -I bacula-macros/ -I gettext-macros/ -I libtool/ +popd +autoconf -I autoconf/ -o configure autoconf/configure.in + # Remove execution permissions from files we're packaging as docs later on find updatedb -type f | xargs chmod -x @@ -333,9 +344,11 @@ export PATH="$PATH:%{_qt5_bindir}" %else export PATH="$PATH:%{_qt4_bindir}" %endif + %configure \ --disable-conio \ --disable-rpath \ + --disable-s3 \ --docdir=%{_datadir}/bacula \ --enable-bat \ --enable-batch-insert \ @@ -375,8 +388,8 @@ export PATH="$PATH:%{_qt4_bindir}" sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool -make %{?_smp_mflags} -make -C examples/nagios/check_bacula +%make_build +%make_build -C examples/nagios/check_bacula pushd src/qt-console/tray-monitor %if 0%{?fedora} || 0%{?rhel} > 7 @@ -384,7 +397,7 @@ pushd src/qt-console/tray-monitor %else %{?qmake_qt4}%{!?qmake_qt4:qmake-qt4} tray-monitor.pro %endif - make %{?_smp_mflags} + %make_build cp -f .libs/bacula-tray-monitor . popd @@ -739,6 +752,12 @@ fi %{_libdir}/nagios/plugins/check_bacula %changelog +* Sun Jan 13 2019 Simone Caronni - 9.4.1-2 +- Add Debian patch to enable/disable S3 support at configure time. +- Disable S3 as it does not currently build: + http://bugs.bacula.org/view.php?id=2446 +- Update RPM macros. + * Sat Jan 12 2019 Simone Caronni - 9.4.1-1 - Update to 9.4.1.