Update to 9.4.0

This commit is contained in:
Simone Caronni 2019-01-12 15:25:34 +01:00
parent 3065577c28
commit e1c39539ef
5 changed files with 124 additions and 103 deletions

View File

@ -1,7 +1,7 @@
diff -Naur bacula-9.2.1.old/autoconf/configure.in bacula-9.2.1/autoconf/configure.in
--- bacula-9.2.1.old/autoconf/configure.in 2018-08-20 16:48:59.390677113 +0200
+++ bacula-9.2.1/autoconf/configure.in 2018-08-20 17:02:58.579289152 +0200
@@ -2983,11 +2983,6 @@
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}
@ -13,10 +13,10 @@ diff -Naur bacula-9.2.1.old/autoconf/configure.in bacula-9.2.1/autoconf/configur
LDFLAGS=${LDFLAGS--O}
CPPFLAGS="$CPPFLAGS"
CFLAGS="$CFLAGS"
diff -Naur bacula-9.2.1.old/configure bacula-9.2.1/configure
--- bacula-9.2.1.old/configure 2018-08-20 16:48:59.380676927 +0200
+++ bacula-9.2.1/configure 2018-08-20 17:02:58.582289208 +0200
@@ -30881,11 +30881,6 @@
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}

View File

@ -1,6 +1,6 @@
diff -Naur bacula-9.2.1.old/src/lib/lib.h bacula-9.2.1/src/lib/lib.h
--- bacula-9.2.1.old/src/lib/lib.h 2018-08-20 16:48:59.350676369 +0200
+++ bacula-9.2.1/src/lib/lib.h 2018-08-20 16:55:33.168002883 +0200
diff -Naur bacula-9.4.0.old/src/lib/lib.h bacula-9.4.0/src/lib/lib.h
--- bacula-9.4.0.old/src/lib/lib.h 2018-12-16 11:30:25.000000000 +0100
+++ bacula-9.4.0/src/lib/lib.h 2019-01-12 15:29:19.939350837 +0100
@@ -54,7 +54,6 @@
#include "fnmatch.h"
#endif
@ -9,9 +9,9 @@ diff -Naur bacula-9.2.1.old/src/lib/lib.h bacula-9.2.1/src/lib/lib.h
#include "tree.h"
#include "watchdog.h"
#include "btimers.h"
diff -Naur bacula-9.2.1.old/src/lib/Makefile.in bacula-9.2.1/src/lib/Makefile.in
--- bacula-9.2.1.old/src/lib/Makefile.in 2018-08-20 16:48:59.350676369 +0200
+++ bacula-9.2.1/src/lib/Makefile.in 2018-08-20 16:56:16.939817198 +0200
diff -Naur bacula-9.4.0.old/src/lib/Makefile.in bacula-9.4.0/src/lib/Makefile.in
--- bacula-9.4.0.old/src/lib/Makefile.in 2018-12-16 11:30:25.000000000 +0100
+++ bacula-9.4.0/src/lib/Makefile.in 2019-01-12 15:29:46.724837145 +0100
@@ -38,7 +38,7 @@
flist.h fnmatch.h guid_to_name.h htable.h lex.h \
lib.h lz4.h md5.h mem_pool.h message.h \
@ -30,21 +30,30 @@ diff -Naur bacula-9.2.1.old/src/lib/Makefile.in bacula-9.2.1/src/lib/Makefile.in
signal.c smartall.c rblist.c tls.c tree.c \
util.c var.c watchdog.c workq.c btimers.c \
worker.c flist.c \
@@ -217,13 +217,6 @@
@@ -246,22 +246,6 @@
$(RMF) md5.o
$(CXX) $(DEFS) $(DEBUG) -c $(CPPFLAGS) -I$(srcdir) -I$(basedir) $(DINCLUDE) $(CFLAGS) md5.c
-sha1sum: Makefile sha1.o
-sha1sum: Makefile libbac.la sha1.c
- $(RMF) sha1.o
- $(CXX) -DSHA1_SUM $(DEFS) $(DEBUG) -c $(CPPFLAGS) -I$(srcdir) -I$(basedir) $(DINCLUDE) $(CFLAGS) sha1.c
- $(LIBTOOL_LINK) $(CXX) $(LDFLAGS) -L. -o $@ sha1.o $(DLIB) -lbac -lm $(LIBS) $(OPENSSL_LIBS)
- $(LIBTOOL_INSTALL) $(INSTALL_PROGRAM) $@ $(DESTDIR)$(sbindir)/
- $(RMF) sha1.o
- $(CXX) $(DEFS) $(DEBUG) -c $(CPPFLAGS) -I$(srcdir) -I$(basedir) $(DINCLUDE) $(CFLAGS) sha1.c
-
bsnprintf: Makefile bsnprintf.o
-sha1_test: Makefile libbac.la sha1.c unittests.o
- $(RMF) sha1.o
- $(CXX) -DTEST_PROGRAM $(DEFS) $(DEBUG) -c $(CPPFLAGS) -I$(srcdir) -I$(basedir) $(DINCLUDE) $(CFLAGS) sha1.c
- $(LIBTOOL_LINK) $(CXX) $(LDFLAGS) -L. -o $@ sha1.o unittests.o $(DLIB) -lbac -lm $(LIBS)
- $(LIBTOOL_INSTALL) $(INSTALL_PROGRAM) $@ $(DESTDIR)$(sbindir)/
- $(RMF) sha1.o
- $(CXX) $(DEFS) $(DEBUG) -c $(CPPFLAGS) -I$(srcdir) -I$(basedir) $(DINCLUDE) $(CFLAGS) sha1.c
-
bsnprintf_test: Makefile libbac.la bsnprintf.c unittests.o
$(RMF) bsnprintf.o
$(CXX) -DTEST_PROGRAM $(DEFS) $(DEBUG) -c $(CPPFLAGS) -I$(srcdir) -I$(basedir) $(DINCLUDE) $(CFLAGS) bsnprintf.c
@@ -287,7 +280,7 @@
@@ -329,7 +313,7 @@
clean: libtool-clean
@$(RMF) core a.out *.o *.bak *.tex *.pdf *~ *.intpro *.extpro 1 2 3
@ -53,10 +62,10 @@ diff -Naur bacula-9.2.1.old/src/lib/Makefile.in bacula-9.2.1/src/lib/Makefile.in
realclean: clean
@$(RMF) tags
diff -Naur bacula-9.2.1.old/src/lib/sha1.c bacula-9.2.1/src/lib/sha1.c
--- bacula-9.2.1.old/src/lib/sha1.c 2018-08-20 16:48:59.352676406 +0200
+++ bacula-9.2.1/src/lib/sha1.c 1970-01-01 01:00:00.000000000 +0100
@@ -1,510 +0,0 @@
diff -Naur bacula-9.4.0.old/src/lib/sha1.c bacula-9.4.0/src/lib/sha1.c
--- bacula-9.4.0.old/src/lib/sha1.c 2018-12-16 11:30:25.000000000 +0100
+++ bacula-9.4.0/src/lib/sha1.c 1970-01-01 01:00:00.000000000 +0100
@@ -1,517 +0,0 @@
-/*
- * sha1.c
- *
@ -423,8 +432,12 @@ diff -Naur bacula-9.2.1.old/src/lib/sha1.c bacula-9.2.1/src/lib/sha1.c
- SHA1ProcessMessageBlock(context);
-}
-
-#ifdef TEST_DRIVER
-
-#ifndef TEST_PROGRAM
-#define TEST_PROGRAM_A
-#endif
-
-#ifdef TEST_PROGRAM
-/*
- * sha1test.c
- *
@ -443,6 +456,9 @@ diff -Naur bacula-9.2.1.old/src/lib/sha1.c bacula-9.2.1/src/lib/sha1.c
-#include <stdio.h>
-#include <string.h>
-#include "sha1.h"
-#include "unittests.h"
-
-#define NRTESTS 4
-
-/*
- * Define patterns for testing
@ -457,81 +473,81 @@ diff -Naur bacula-9.2.1.old/src/lib/sha1.c bacula-9.2.1/src/lib/sha1.c
-#define TEST4b "01234567012345670123456701234567"
- /* an exact multiple of 512 bits */
-#define TEST4 TEST4a TEST4b
-char *testarray[4] =
-
-const char *testarray[NRTESTS] =
-{
- TEST1,
- TEST2,
- TEST3,
- TEST4
-};
-long int repeatcount[4] = { 1, 1, 1000000, 10 };
-char *resultarray[4] =
-
-int repeatcount[NRTESTS] = { 1, 1, 1000000, 10 };
-
-const uint8_t resultarray[NRTESTS][20] =
-{
- "A9 99 3E 36 47 06 81 6A BA 3E 25 71 78 50 C2 6C 9C D0 D8 9D",
- "84 98 3E 44 1C 3B D2 6E BA AE 4A A1 F9 51 29 E5 E5 46 70 F1",
- "34 AA 97 3C D4 C4 DA A4 F6 1E EB 2B DB AD 27 31 65 34 01 6F",
- "DE A3 56 A2 CD DD 90 C7 A7 EC ED C5 EB B5 63 93 4F 46 04 52"
- { 0xA9, 0x99, 0x3E, 0x36, 0x47, 0x06, 0x81, 0x6A, 0xBA, 0x3E, 0x25, 0x71, 0x78, 0x50, 0xC2, 0x6C, 0x9C, 0xD0, 0xD8, 0x9D },
- { 0x84, 0x98, 0x3E, 0x44, 0x1C, 0x3B, 0xD2, 0x6E, 0xBA, 0xAE, 0x4A, 0xA1, 0xF9, 0x51, 0x29, 0xE5, 0xE5, 0x46, 0x70, 0xF1 },
- { 0x34, 0xAA, 0x97, 0x3C, 0xD4, 0xC4, 0xDA, 0xA4, 0xF6, 0x1E, 0xEB, 0x2B, 0xDB, 0xAD, 0x27, 0x31, 0x65, 0x34, 0x01, 0x6F },
- { 0xDE, 0xA3, 0x56, 0xA2, 0xCD, 0xDD, 0x90, 0xC7, 0xA7, 0xEC, 0xED, 0xC5, 0xEB, 0xB5, 0x63, 0x93, 0x4F, 0x46, 0x04, 0x52 },
-};
-
-int main()
-{
- Unittests sha1_test("sha1_test");
- SHA1Context sha;
- int i, j, err;
- uint8_t Message_Digest[20];
- bool check_cont;
- bool ct;
-
- /*
- * Perform SHA-1 tests
- */
- for(j = 0; j < 4; ++j) {
- printf( "\nTest %d: %d, '%s'\n",
- j+1,
- repeatcount[j],
- testarray[j]);
-
- // printf( "\nTest %d: %d, '%s'\n", j+1, repeatcount[j], testarray[j]);
- err = SHA1Init(&sha);
- nok(err, "Test SHA1Init");
- if (err) {
- fprintf(stderr, "SHA1Reset Error %d.\n", err );
- break; /* out of for j loop */
- }
-
- ct = true;
- for(i = 0; i < repeatcount[j]; ++i) {
-
- err = SHA1Input(&sha,
- (const unsigned char *) testarray[j],
- strlen(testarray[j]));
- err = SHA1Update(&sha, (const unsigned char *) testarray[j], strlen(testarray[j]));
- if (i < 5){
- nok(err, "Test SHA1Update");
- }
- if (ct && repeatcount[j] > 4 && i > 4){
- ct = false;
- printf("...\n");
- }
- if (err) {
- fprintf(stderr, "SHA1Input Error %d.\n", err );
- nok(err, "Test SHA1Update");
- break; /* out of for i loop */
- }
- }
-
- err = SHA1Final(&sha, Message_Digest);
- if (err) {
- fprintf(stderr,
- "SHA1Result Error %d, could not compute message digest.\n",
- err );
- }
- else
- {
- printf("\t");
- nok(err, "Test SHA1Final");
- check_cont = true;
- for(i = 0; i < 20 ; ++i) {
- printf("%02X ", Message_Digest[i]);
- if (Message_Digest[i] != resultarray[j][i]){
- check_cont = false;
- }
- printf("\n");
- }
- printf("Should match:\n");
- printf("\t%s\n", resultarray[j]);
- ok(check_cont, "Checking expected result");
- }
-
- /* Test some error returns */
- err = SHA1Input(&sha,(const unsigned char *) testarray[1], 1);
- printf ("\nError %d. Should be %d.\n", err, shaStateError );
- err = SHA1Update(&sha,(const unsigned char *) testarray[1], 1);
- ok(err == shaStateError, "Checking for shaStateError");
- err = SHA1Init(0);
- printf ("\nError %d. Should be %d.\n", err, shaNull );
- return 0;
- ok(err == shaNull, "Checking for shaNull");
-
- return report();
-}
-
-#endif /* TEST_DRIVER */
-#endif /* TEST_PROGRAM */
-
-#ifdef SHA1_SUM
-/*
@ -566,10 +582,10 @@ diff -Naur bacula-9.2.1.old/src/lib/sha1.c bacula-9.2.1/src/lib/sha1.c
- printf(" %s\n", argv[1]);
- fclose(fd);
-}
-#endif
diff -Naur bacula-9.2.1.old/src/lib/sha1.h bacula-9.2.1/src/lib/sha1.h
--- bacula-9.2.1.old/src/lib/sha1.h 2018-08-20 16:48:59.350676369 +0200
+++ bacula-9.2.1/src/lib/sha1.h 1970-01-01 01:00:00.000000000 +0100
-#endif /* SHA1_SUM */
diff -Naur bacula-9.4.0.old/src/lib/sha1.h bacula-9.4.0/src/lib/sha1.h
--- bacula-9.4.0.old/src/lib/sha1.h 2018-12-16 11:30:25.000000000 +0100
+++ bacula-9.4.0/src/lib/sha1.h 1970-01-01 01:00:00.000000000 +0100
@@ -1,107 +0,0 @@
-/*
- * sha1.h

View File

@ -1,6 +1,6 @@
diff -Naur bacula-9.0.6.old/src/lib/crypto.c bacula-9.0.6/src/lib/crypto.c
--- bacula-9.0.6.old/src/lib/crypto.c 2017-12-07 15:42:03.771178189 +0100
+++ bacula-9.0.6/src/lib/crypto.c 2017-12-07 15:42:25.300578772 +0100
diff -Naur bacula-9.4.0.old/src/lib/crypto.c bacula-9.4.0/src/lib/crypto.c
--- bacula-9.4.0.old/src/lib/crypto.c 2018-12-16 11:30:25.000000000 +0100
+++ bacula-9.4.0/src/lib/crypto.c 2019-01-12 15:18:04.623955646 +0100
@@ -42,7 +42,7 @@
* For OpenSSL version 1.x, EVP_PKEY_encrypt no longer
* exists. It was not an official API.
@ -10,9 +10,9 @@ diff -Naur bacula-9.0.6.old/src/lib/crypto.c bacula-9.0.6/src/lib/crypto.c
#define EVP_PKEY_encrypt EVP_PKEY_encrypt_old
#define EVP_PKEY_decrypt EVP_PKEY_decrypt_old
#endif
diff -Naur bacula-9.0.6.old/src/lib/tls.c bacula-9.0.6/src/lib/tls.c
--- bacula-9.0.6.old/src/lib/tls.c 2017-12-07 15:42:03.770178170 +0100
+++ bacula-9.0.6/src/lib/tls.c 2017-12-07 15:42:26.891608376 +0100
diff -Naur bacula-9.4.0.old/src/lib/tls.c bacula-9.4.0/src/lib/tls.c
--- bacula-9.4.0.old/src/lib/tls.c 2018-12-16 11:30:25.000000000 +0100
+++ bacula-9.4.0/src/lib/tls.c 2019-01-12 15:18:04.646956092 +0100
@@ -47,9 +47,6 @@
#include "openssl-compat.h"
@ -23,7 +23,7 @@ diff -Naur bacula-9.0.6.old/src/lib/tls.c bacula-9.0.6/src/lib/tls.c
/* TLS Context Structure */
struct TLS_Context {
SSL_CTX *openssl;
@@ -206,7 +203,7 @@
@@ -215,7 +212,7 @@
SSL_CTX_set_options(ctx->openssl, SSL_OP_SINGLE_DH_USE);
}
@ -32,7 +32,7 @@ diff -Naur bacula-9.0.6.old/src/lib/tls.c bacula-9.0.6/src/lib/tls.c
Jmsg0(NULL, M_ERROR, 0,
_("Error setting cipher list, no valid ciphers available\n"));
goto err;
@@ -328,7 +325,7 @@
@@ -336,7 +333,7 @@
extname = OBJ_nid2sn(OBJ_obj2nid(X509_EXTENSION_get_object(ext)));
if (strcmp(extname, "subjectAltName") == 0) {

View File

@ -1,6 +1,6 @@
diff -Naur bacula-9.2.1.old/src/lib/message.c bacula-9.2.1/src/lib/message.c
--- bacula-9.2.1.old/src/lib/message.c 2018-08-20 16:48:59.351676388 +0200
+++ bacula-9.2.1/src/lib/message.c 2018-08-20 16:50:18.934156941 +0200
diff -Naur bacula-9.4.0.old/src/lib/message.c bacula-9.4.0/src/lib/message.c
--- bacula-9.4.0.old/src/lib/message.c 2018-12-16 11:30:25.000000000 +0100
+++ bacula-9.4.0/src/lib/message.c 2019-01-12 15:20:25.794653213 +0100
@@ -28,6 +28,7 @@
*
*/
@ -9,7 +9,7 @@ diff -Naur bacula-9.2.1.old/src/lib/message.c bacula-9.2.1/src/lib/message.c
#include "bacula.h"
#include "jcr.h"
@@ -1398,7 +1399,8 @@
@@ -1413,7 +1414,8 @@
if (type == M_ABORT) {
char *p = 0;

View File

@ -2,8 +2,8 @@
%global username bacula
Name: bacula
Version: 9.2.1
Release: 2%{?dist}
Version: 9.4.0
Release: 1%{?dist}
Summary: Cross platform network backup for Linux, Unix, Mac and Windows
# See LICENSE for details
License: AGPLv3 with exceptions
@ -28,16 +28,16 @@ Source17: %{name}-sd.sysconfig
# Image taken from http://www.bacula.org/git/cgit.cgi/bacula/plain/bacula/src/tray-monitor/generic.xpm
Source19: generic.xpm
Patch1: %{name}-9.0.6-openssl.patch
Patch1: %{name}-9.4.0-openssl.patch
Patch2: %{name}-9.0.0-queryfile.patch
Patch3: %{name}-9.0.4-sqlite-priv.patch
Patch4: %{name}-9.0.6-bat-build.patch
Patch5: %{name}-9.2.1-seg-fault.patch
Patch5: %{name}-9.4.0-seg-fault.patch
Patch6: %{name}-5.2.13-logwatch.patch
Patch7: %{name}-9.2.1-non-free-code.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.2.1-g++-options.patch
Patch9: %{name}-9.4.0-g++-options.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
@ -58,6 +58,7 @@ BuildRequires: libacl-devel
BuildRequires: libstdc++-devel
BuildRequires: libxml2-devel
BuildRequires: libcap-devel
BuildRequires: libs3-devel
BuildRequires: lzo-devel
BuildRequires: ncurses-devel
BuildRequires: openssl-devel
@ -668,6 +669,7 @@ fi
%config(noreplace) %{_sysconfdir}/bacula/bacula-sd.conf %attr(640,root,root)
%config(noreplace) %{_sysconfdir}/sysconfig/bacula-sd
%{_libexecdir}/%{name}/disk-changer
%{_libexecdir}/%{name}/isworm
%{_libexecdir}/%{name}/mtx-changer
%{_libexecdir}/%{name}/mtx-changer.conf
%{_libexecdir}/%{name}/tapealert
@ -737,6 +739,9 @@ fi
%{_libdir}/nagios/plugins/check_bacula
%changelog
* Sat Jan 12 2019 Simone Caronni <negativo17@gmail.com> - 9.4.0-1
- Update to 9.4.0.
* Sat Jan 12 2019 Simone Caronni <negativo17@gmail.com> - 9.2.1-2
- Make the build succeed also on supported RHEL and Fedora releases.
- Remove Fedora 27 references.