From mboxrd@z Thu Jan 1 00:00:00 1970 From: Michael Tremer To: development@lists.ipfire.org Subject: [PATCH] squidGuard: Fix generating databases with libdb >= 5 Date: Fri, 22 May 2020 11:49:03 +0000 Message-ID: <20200522114903.7093-1-michael.tremer@ipfire.org> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============2275248959977531114==" List-Id: --===============2275248959977531114== Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Signed-off-by: Michael Tremer --- lfs/squidguard | 1 + src/patches/squidGuard-1.4-db5.patch | 12 ++++++++++++ 2 files changed, 13 insertions(+) create mode 100644 src/patches/squidGuard-1.4-db5.patch diff --git a/lfs/squidguard b/lfs/squidguard index f627a27d8..38efab0ee 100644 --- a/lfs/squidguard +++ b/lfs/squidguard @@ -71,6 +71,7 @@ $(TARGET) : $(patsubst %,$(DIR_DL)/%,$(objects)) @$(PREBUILD) @rm -rf $(DIR_APP) && cd $(DIR_SRC) && tar zxf $(DIR_DL)/$(DL_FILE) cd $(DIR_APP) && patch -Np1 -i $(DIR_SRC)/src/patches/squidguard-1.4-squid-= helper-protocol.patch + cd $(DIR_APP) && patch -Np1 -i $(DIR_SRC)/src/patches/squidGuard-1.4-db5.pa= tch cd $(DIR_APP) && ./configure --prefix=3D/usr --datadir=3D/usr/share \ --sysconfdir=3D/etc --localstatedir=3D/var --infodir=3D/usr/info --mandir= =3D/usr/man \ --with-sg-config=3D/var/ipfire/urlfilter/squidGuard.conf \ diff --git a/src/patches/squidGuard-1.4-db5.patch b/src/patches/squidGuard-1.= 4-db5.patch new file mode 100644 index 000000000..733fbad2e --- /dev/null +++ b/src/patches/squidGuard-1.4-db5.patch @@ -0,0 +1,12 @@ +diff -ruN squidGuard-1.4-vanilla/src/sgDb.c squidGuard-1.4/src/sgDb.c +--- squidGuard-1.4-vanilla/src/sgDb.c 2008-07-15 04:29:41.000000000 +1000 ++++ squidGuard-1.4/src/sgDb.c 2013-01-21 12:47:41.049325756 +1100 +@@ -114,7 +114,7 @@ + } + } + #endif +-#if DB_VERSION_MAJOR =3D=3D 4 ++#if DB_VERSION_MAJOR >=3D 4 + if(globalUpdate || createdb || (dbfile !=3D NULL && stat(dbfile,&st))){ + flag =3D DB_CREATE; + if(createdb) \ No newline at end of file --=20 2.20.1 --===============2275248959977531114==--