summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeroen Roovers <jer@gentoo.org>2019-12-26 13:11:25 +0100
committerJeroen Roovers <jer@gentoo.org>2019-12-26 13:11:40 +0100
commit9819a200cbbba1409b10d07b383da91d0cc74202 (patch)
treecd17156bf705a2ceaa29381398591ef8c41de907 /net-analyzer/sarg/files
parentapp-arch/plzip: keyword 1.8 on ~ppc64 (diff)
downloadgentoo-9819a200cbbba1409b10d07b383da91d0cc74202.tar.gz
gentoo-9819a200cbbba1409b10d07b383da91d0cc74202.tar.bz2
gentoo-9819a200cbbba1409b10d07b383da91d0cc74202.zip
net-analyzer/sarg: Version 2.4.0_pre3
Package-Manager: Portage-2.3.83, Repoman-2.3.20 Signed-off-by: Jeroen Roovers <jer@gentoo.org>
Diffstat (limited to 'net-analyzer/sarg/files')
-rw-r--r--net-analyzer/sarg/files/sarg-2.4.0-config.patch81
-rw-r--r--net-analyzer/sarg/files/sarg-2.4.0-configure.patch43
-rw-r--r--net-analyzer/sarg/files/sarg-2.4.0-fabs.patch11
-rw-r--r--net-analyzer/sarg/files/sarg-2.4.0-format.patch22
4 files changed, 157 insertions, 0 deletions
diff --git a/net-analyzer/sarg/files/sarg-2.4.0-config.patch b/net-analyzer/sarg/files/sarg-2.4.0-config.patch
new file mode 100644
index 000000000000..1168f98337d7
--- /dev/null
+++ b/net-analyzer/sarg/files/sarg-2.4.0-config.patch
@@ -0,0 +1,81 @@
+--- a/log.c
++++ b/log.c
+@@ -151,7 +151,7 @@
+ strcpy(FontSize,"9px");
+ strcpy(TempDir,"/tmp");
+ TempDirPath[0] = '\0';
+- strcpy(OutputDir,"/var/www/html/squid-reports");
++ strcpy(OutputDir,"/var/www/localhost/htdocs/squid-reports");
+ AnonymousOutputFiles=false;
+ Ip2Name=false;
+ DateFormat='u';
+--- a/htaccess
++++ b/htaccess
+@@ -1,4 +1,4 @@
+-AuthUserFile /usr/local/sarg/passwd
++AuthUserFile /etc/sarg/passwd
+ AuthName "SARG, Squid Analysis Report Generator"
+ AuthType Basic
+ <Limit GET POST>
+--- a/sarg.conf
++++ b/sarg.conf
+@@ -17,7 +17,7 @@
+ # If some files are passed on the command line with "sarg -l file" or
+ # "sarg file", the files listed here are ignored.
+ #
+-#access_log /usr/local/squid/var/logs/access.log
++#access_log /var/log/squid/access.log
+
+ # TAG: graphs yes|no
+ # Use graphics where is possible.
+@@ -147,7 +147,7 @@
+ # The reports will be saved in that directory
+ # sarg -o dir
+ #
+-#output_dir /var/www/html/squid-reports
++#output_dir /var/www/localhost/htdocs/squid-reports
+
+ # TAG: anonymous_output_files yes/no
+ # Use anonymous file and directory names in the report. If it is set to
+@@ -632,7 +632,7 @@
+ # Generate reports from SquidGuard logs.
+ # Use 'none' to disable.
+ # You can use sarg -L filename to use an alternate squidGuard log.
+-# squidguard_conf /usr/local/squidGuard/squidGuard.conf
++# squidguard_conf /etc/squidGuard/squidGuard.conf
+ #
+ #squidguard_conf none
+
+--- a/user_limit_block
++++ b/user_limit_block
+@@ -24,8 +24,8 @@
+ #
+ #
+
+-conf="/usr/local/sarg/sarg.conf"
+-squid_password_file="/usr/local/squid/etc/passwd"
++conf="/etc/sarg/sarg.conf"
++squid_password_file="/etc/squid/passwd"
+ tmp="/tmp/sarg_limit.$$"
+
+ limit_file=`grep "per_user_limit" $conf|grep -v "#"|awk '{print $2}'`
+--- a/sarg-php/config.php.inc
++++ b/sarg-php/config.php.inc
+@@ -1,13 +1,13 @@
+ <?php
+
+ // Change to squidGuard and sarg config file paths
+-$SargConf = "/usr/local/sarg/sarg.conf";
+-$squidGuardConf = "/usr/local/squidGuard/squidGuard.conf";
++$SargConf = "/etc/sarg/sarg.conf";
++$squidGuardConf = "/etc/squidGuard/squidGuard.conf";
+
+ // File where URL to block will be appended
+-$DefaultSquidBlock = "/usr/local/squid/etc/block.txt";
++$DefaultSquidBlock = "/etc/squid/etc/block.txt";
+
+ // Choose the locale you want to use to display messages (it must exist on your system)
+-$language = "fr_BE.utf-8";
++$language = "POSIX";
+
+ ?>
diff --git a/net-analyzer/sarg/files/sarg-2.4.0-configure.patch b/net-analyzer/sarg/files/sarg-2.4.0-configure.patch
new file mode 100644
index 000000000000..7ca44a6901f1
--- /dev/null
+++ b/net-analyzer/sarg/files/sarg-2.4.0-configure.patch
@@ -0,0 +1,43 @@
+--- a/configure.ac
++++ b/configure.ac
+@@ -35,6 +35,11 @@
+ dnl C99 support is required to define LLONG_MAX (at least on CentOS 5.7)
+ AC_PROG_CC_C99
+
++dnl mkdir_p / MKDIR_P
++AC_PROG_MKDIR_P
++mkdir_p="$MKDIR_P"
++AC_SUBST(mkdir_p)
++
+ # Report more warnings to improve code quality.
+ CFLAGS="${CFLAGS} -Wall"
+
+@@ -50,23 +55,23 @@
+ # Don't compare signs as it is a mess
+ CFLAGS="${CFLAGS} -Wno-sign-compare"
+
+-AC_MSG_CHECKING([for implicit-function-declaration error flag in $CC])
++AC_MSG_CHECKING([for implicit-function-declaration warning flag in $CC])
+ saved_CFLAGS="${CFLAGS}"
+-CFLAGS="${CFLAGS} -Werror=implicit-function-declaration"
++CFLAGS="${CFLAGS} -Wimplicit-function-declaration"
+ AC_COMPILE_IFELSE([AC_LANG_SOURCE([])],[have_implicit_function_declaration="yes"],[have_implicit_function_declaration="no"])
+ AC_MSG_RESULT($have_implicit_function_declaration)
+ AS_IF([test "$have_implicit_function_declaration" = "no"],[CFLAGS="${saved_CFLAGS}"])
+
+-AC_MSG_CHECKING([for format error flag in $CC])
++AC_MSG_CHECKING([for format warning flag in $CC])
+ saved_CFLAGS="${CFLAGS}"
+-CFLAGS="${CFLAGS} -Werror=format"
++CFLAGS="${CFLAGS} -Wformat"
+ AC_COMPILE_IFELSE([AC_LANG_SOURCE([])],[have_error_format="yes"],[have_error_format="no"])
+ AC_MSG_RESULT($have_error_format)
+ AS_IF([test "$have_error_format" = "no"],[CFLAGS="${saved_CFLAGS}"])
+
+ case "$host" in
+ *-solaris*)
+- LDFLAGS="${LDFLAGS} -lsocket -lnsl"
++ LIBS="${LIBS} -lsocket -lnsl"
+ CFLAGS="-DSOLARIS ${CFLAGS}"
+ ;;
+ esac
diff --git a/net-analyzer/sarg/files/sarg-2.4.0-fabs.patch b/net-analyzer/sarg/files/sarg-2.4.0-fabs.patch
new file mode 100644
index 000000000000..e9b73d88fb4a
--- /dev/null
+++ b/net-analyzer/sarg/files/sarg-2.4.0-fabs.patch
@@ -0,0 +1,11 @@
+--- a/btree_cache.c
++++ b/btree_cache.c
+@@ -268,7 +268,7 @@
+ static struct bt *get_disbalanced_node(struct bt *node)
+ {
+ struct bt *rdn;
+- if (fabs(node->balanceinfo) > 1)
++ if (abs(node->balanceinfo) > 1)
+ return node;
+ if (node->left)
+ {
diff --git a/net-analyzer/sarg/files/sarg-2.4.0-format.patch b/net-analyzer/sarg/files/sarg-2.4.0-format.patch
new file mode 100644
index 000000000000..686f659c1300
--- /dev/null
+++ b/net-analyzer/sarg/files/sarg-2.4.0-format.patch
@@ -0,0 +1,22 @@
+--- a/userinfo.c
++++ b/userinfo.c
+@@ -78,7 +78,7 @@
+ int skip;
+ int flen;
+ int count, clen;
+- char cstr[9];
++ char cstr[10];
+ char filename[MAX_USER_FNAME_LEN];
+
+ if (!UserStrings) {
+--- a/index.c
++++ b/index.c
+@@ -535,7 +535,7 @@
+ struct dirent *direntp;
+ char yearindex[MAXLEN];
+ char yeardir[MAXLEN];
+- char yearnum[10];
++ char yearnum[15];
+ int yearsort[150];
+ int nyears;
+ int year;