Revision: 7024
http://ipcop.svn.sourceforge.net/ipcop/?rev=7024&view=rev
Author: gespinasse
Date: 2013-05-08 09:26:02 +0000 (Wed, 08 May 2013)
Log Message:
-----------
Use debian patch set as that solve the %20 issue reported to us in May 2012
Enable ldap as there is mostly no cost to do that, even we are not ready to
support the feature in our GUI yet.
Add --with-db=/usr or there is some ugly -I/usr/local/BerkeleyDB/include (that
do not break the build)
Fix numerous warnings (I used sed here but patches has been send upstream and
to debian maintainer)
Create log file in our makefile, so tests could run without ugly can't write
file
Empty the log file after tests have run.
Modified Paths:
--------------
ipcop/trunk/config/rootfiles/common/squidGuard
ipcop/trunk/lfs/squidGuard
Modified: ipcop/trunk/config/rootfiles/common/squidGuard
===================================================================
--- ipcop/trunk/config/rootfiles/common/squidGuard 2013-05-08 07:36:48 UTC
(rev 7023)
+++ ipcop/trunk/config/rootfiles/common/squidGuard 2013-05-08 09:26:02 UTC
(rev 7024)
@@ -1,4 +1,3 @@
usr/bin/squidGuard
-#usr/squidGuard
-#var/ipcop/proxy/squidGuard.conf
var/log/squidGuard
+var/log/squidGuard/squidGuard.log
Modified: ipcop/trunk/lfs/squidGuard
===================================================================
--- ipcop/trunk/lfs/squidGuard 2013-05-08 07:36:48 UTC (rev 7023)
+++ ipcop/trunk/lfs/squidGuard 2013-05-08 09:26:02 UTC (rev 7024)
@@ -43,15 +43,21 @@
DIR_APP = $(DIR_SRC)/$(THISAPP)
TARGET = $(DIR_INFO)/$(STAGE_ORDER)_$(STAGE)/$(THISAPP)
+PATCH1 = squidguard_1.5-1.debian.tar.gz
+
+CFLAGS += -Wall
+
###############################################################################
# Top-level Rules
###############################################################################
-objects = $(DL_FILE)
+objects = $(DL_FILE) $(PATCH1)
-$(DL_FILE) = $(DL_FROM)/$(DL_FILE)
+$(DL_FILE):= $(DL_FROM)/$(DL_FILE)
+$(PATCH1) := $(URL_DEBIAN)/s/squidguard/$(PATCH1)
-$(DL_FILE)_MD5 = a15badd7f98f726f63b418a38f117283
+$(DL_FILE)_MD5:= a15badd7f98f726f63b418a38f117283
+$(PATCH1)_MD5 := 780576da1f75eebf752f60160d42c616
install : $(TARGET)
@@ -81,19 +87,43 @@
$(TARGET) : $(firstword $(MAKEFILE_LIST)) $(patsubst %,$(DIR_DL)/%,$(objects))
@$(PREBUILD)
@rm -rf $(DIR_APP) && cd $(DIR_SRC) && tar xf $(DIR_DL)/$(DL_FILE)
+ cd $(DIR_APP) && tar xf $(DIR_DL)/$(PATCH1)
+ cd $(DIR_APP) && for patch in `cat debian/patches/series` ; do echo
"Using $$patch"; patch -p1 -i debian/patches/$$patch; done
cd $(DIR_APP) && patch -Np1 -i
$(DIR_PATCHES)/$(THISAPP)_stdout-always.patch
+ # Fix implicit declaration of function 'HTUnEscape'
+ cd $(DIR_APP) && sed -i 's/sgEx.h.*/&\n#include "HTEscape.h"/'
src/sgDiv.c.in
+ # Fix format %d vs size_t
+ cd $(DIR_APP) && sed -i
'/userquota->time/s/s->userquota.seconds\|userquota->time\|userquota->last/(int)&/g'
src/sgDiv.c.in
+ # Fix implicit declaration of ldap functions deprecated since
openldap-2.3
+ cd $(DIR_APP) && sed -i 's/lber.h.*/&\n#define LDAP_DEPRECATED 1/'
src/sg.y.in
+ # Unused variables
+ cd $(DIR_APP) && sed -i '/struct IpInfo uq;/d;/ struct UserInfo
uq;/d' src/sg.y.in
+ # Fix 'yyunput' and 'input' defined but not used
+ cd $(DIR_APP) && sed -i 's/ignore /%option noinput\n%option
nounput\n&/' src/sg.l
- cd $(DIR_APP) && ./configure --with-squiduser=squid \
- --prefix=/usr \
+ # Use --with-db, so /usr/local does not appear for db
+ cd $(DIR_APP) && ./configure --prefix=/usr \
+ --with-db=/usr \
+ --with-ldap \
+ --with-squiduser=squid \
--with-sg-config=/var/ipcop/proxy/squidGuard.conf \
--with-sg-dbhome=/var/lib/squidguard/db \
--with-sg-logdir=/var/log/squidGuard \
--with-syslog=yes
+
cd $(DIR_APP) && make
+
+ # Create log, so tests could run without write error
+ mkdir -p /var/log/squidGuard
+ > /var/log/squidGuard/squidGuard.log
+ chown squid:root /var/log/squidGuard /var/log/squidGuard/squidGuard.log
+
ifeq "$(RUNNING_TEST)" "yes"
# Do not to stop on error in tests
-cd $(DIR_APP) && make test &> $(DIR_TEST)/$(THISAPP)-$(STAGE_ORDER).log
endif
+ # Empty log after tests
+ > /var/log/squidGuard/squidGuard.log
cd $(DIR_APP) && make install
@rm -rf $(DIR_APP)
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and
their applications. This 200-page book is written by three acclaimed
leaders in the field. The early access version is available now.
Download your free book today! http://p.sf.net/sfu/neotech_d2d_may
_______________________________________________
Ipcop-svn mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ipcop-svn