SF.net SVN: gar:[22934] csw/mgar/pkg/mirrorbrain/trunk

dmichelsen at users.sourceforge.net dmichelsen at users.sourceforge.net
Sun Feb 2 21:52:14 CET 2014


Revision: 22934
          http://sourceforge.net/p/gar/code/22934
Author:   dmichelsen
Date:     2014-02-02 20:52:12 +0000 (Sun, 02 Feb 2014)
Log Message:
-----------
mirrorbrain/trunk: Update to 2.18.0, add apache pre-/post-scripts, more reinplacements

Modified Paths:
--------------
    csw/mgar/pkg/mirrorbrain/trunk/Makefile
    csw/mgar/pkg/mirrorbrain/trunk/checksums

Added Paths:
-----------
    csw/mgar/pkg/mirrorbrain/trunk/files/CSWap2-mod-autoindex-mb.postinstall
    csw/mgar/pkg/mirrorbrain/trunk/files/CSWap2-mod-autoindex-mb.preremove
    csw/mgar/pkg/mirrorbrain/trunk/files/CSWap2-mod-mirrorbrain.postinstall
    csw/mgar/pkg/mirrorbrain/trunk/files/CSWap2-mod-mirrorbrain.preremove

Removed Paths:
-------------
    csw/mgar/pkg/mirrorbrain/trunk/files/0001-Change-default-for-getaddrinfo.patch
    csw/mgar/pkg/mirrorbrain/trunk/files/0001-Exit-if-geoip-file-cannot-be-opened.patch
    csw/mgar/pkg/mirrorbrain/trunk/files/0001-Make-geoip-database-position-adjustable.patch

Modified: csw/mgar/pkg/mirrorbrain/trunk/Makefile
===================================================================
--- csw/mgar/pkg/mirrorbrain/trunk/Makefile	2014-02-02 20:43:29 UTC (rev 22933)
+++ csw/mgar/pkg/mirrorbrain/trunk/Makefile	2014-02-02 20:52:12 UTC (rev 22934)
@@ -2,27 +2,19 @@
 # TODO (release-critical prefixed with !, non release-critical with *)
 #
 NAME = mirrorbrain
-VERSION = 2.17.0
+VERSION = 2.18.0
 GARTYPE = v2
 
 DESCRIPTION = Content distribution tool
 
 MASTER_SITES = http://mirrorbrain.org/files/releases/
 DISTFILES  = $(DISTNAME).tar.gz
+DTSTFILES += CSWap2-mod-autoindex-mb.postinstall
+DTSTFILES += CSWap2-mod-autoindex-mb.preremove
+DTSTFILES += CSWap2-mod-mirrorbrain.postinstall
+DTSTFILES += CSWap2-mod-mirrorbrain.preremove
 
 # Use patch until this is fixed:
-#   http://mirrorbrain.org/issues/issue130
-PATCHFILES += 0001-Make-geoip-database-position-adjustable.patch
-
-# Use patch until this is fixed:
-#   http://mirrorbrain.org/issues/issue135
-PATCHFILES += 0001-Change-default-for-getaddrinfo.patch
-
-# Use patch until this is fixed:
-#   http://mirrorbrain.org/issues/issue138
-PATCHFILES += 0001-Exit-if-geoip-file-cannot-be-opened.patch
-
-# Use patch until this is fixed:
 #   http://mirrorbrain.org/issues/issue139
 PATCHFILES += 0001-Do-not-take-ref-on-a-simple-scalar-string-or-it-wont.patch
 
@@ -93,6 +85,10 @@
 REINPLACE_WITH_python = \#!$(bindir)/python
 REINPLACE_FILES_python += tools/null-rsync
 REINPLACE_FILES_python += mirrorprobe/mirrorprobe.py
+REINPLACE_FILES_python += tools/bdecode
+REINPLACE_FILES_python += tools/rsyncinfo
+REINPLACE_FILES_python += tools/rsyncusers
+REINPLACE_FILES_python += tools/create_timestamp
 
 REINPLACEMENTS += perl
 REINPLACE_MATCH_perl = \#!.*perl.*
@@ -103,12 +99,18 @@
 REINPLACE_MATCH_mbconf = /etc/mirrorbrain.conf
 REINPLACE_WITH_mbconf = $(sysconfdir)/mirrorbrain.conf
 REINPLACE_FILES_mbconf += tools/scanner.pl
+REINPLACE_FILES_mbconf += mirrorprobe/mirrorprobe.py
 
+REINPLACEMENTS += mplog
+REINPLACE_MATCH_mplog = /var/log/mirrorbrain/mirrorprobe.log
+REINPLACE_WITH_mplog = $(localstatedur)/mirrorbrain/mirrorprobe.log
+REINPLACE_FILES_mplog += mirrorprobe/mirrorprobe.py
+
 # The language must be in lower case
-REINPLACEMENTS += sql
-REINPLACE_MATCH_sql = 'SQL'
-REINPLACE_WITH_sql = 'sql'
-REINPLACE_FILES_sql += sql/schema-postgresql.sql
+#REINPLACEMENTS += sql
+#REINPLACE_MATCH_sql = 'SQL'
+#REINPLACE_WITH_sql = 'sql'
+#REINPLACE_FILES_sql += sql/schema-postgresql.sql
 
 GEOIPCITYFILE = $(sharedstatedir)/GeoIP/GeoIPCity.dat
 GEOIPFILE = $(sharedstatedir)/GeoIP/GeoIP.dat
@@ -142,6 +144,10 @@
 	ginstall -m 0755 $(WORKSRC)/tools/geoiplookup_continent $(DESTDIR)$(bindir)/geoiplookup_continent
 	ginstall -m 0755 $(WORKSRC)/tools/null-rsync $(DESTDIR)$(bindir)/null-rsync
 	ginstall -m 0755 $(WORKSRC)/tools/scanner.pl $(DESTDIR)$(bindir)/scanner
+	ginstall -m 0755 $(WORKSRC)/tools/bdecode $(DESTDIR)$(bindir)/bdecode
+	ginstall -m 0755 $(WORKSRC)/tools/rsyncinfo $(DESTDIR)$(bindir)/rsyncinfo
+	ginstall -m 0755 $(WORKSRC)/tools/rsyncusers $(DESTDIR)$(bindir)/rsyncusers
+	ginstall -m 0755 $(WORKSRC)/tools/create_timestamp $(DESTDIR)$(bindir)/create_timestamp
 	ginstall -m 0755 $(WORKSRC)/mirrorprobe/mirrorprobe.py $(DESTDIR)$(bindir)/mirrorprobe
 	ginstall -d $(DESTDIR)$(sharedstatedir)/mirrorbrain/sql
 	ginstall -m 0644 $(WORKSRC)/sql/initialdata-postgresql.sql $(DESTDIR)$(sharedstatedir)/mirrorbrain/sql/initialdata-postgresql.sql

Modified: csw/mgar/pkg/mirrorbrain/trunk/checksums
===================================================================
--- csw/mgar/pkg/mirrorbrain/trunk/checksums	2014-02-02 20:43:29 UTC (rev 22933)
+++ csw/mgar/pkg/mirrorbrain/trunk/checksums	2014-02-02 20:52:12 UTC (rev 22934)
@@ -1 +1 @@
-c0556adb5c5eef8983b517f938375abc  mirrorbrain-2.17.0.tar.gz
+b0b9172578cb567aec6eb7a164fba657  mirrorbrain-2.18.0.tar.gz

Deleted: csw/mgar/pkg/mirrorbrain/trunk/files/0001-Change-default-for-getaddrinfo.patch
===================================================================
--- csw/mgar/pkg/mirrorbrain/trunk/files/0001-Change-default-for-getaddrinfo.patch	2014-02-02 20:43:29 UTC (rev 22933)
+++ csw/mgar/pkg/mirrorbrain/trunk/files/0001-Change-default-for-getaddrinfo.patch	2014-02-02 20:52:12 UTC (rev 22934)
@@ -1,25 +0,0 @@
-From 3f59a009b2997cfe2f79ad020613a4a1dbf1ae14 Mon Sep 17 00:00:00 2001
-From: Dagobert Michelsen <dam at opencsw.org>
-Date: Sat, 25 Jan 2014 11:17:09 +0100
-Subject: [PATCH] Change default for getaddrinfo
-
----
- mb/mb/asn.py | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/mb/mb/asn.py b/mb/mb/asn.py
-index 0b6d602..3a5c2c4 100644
---- a/mb/mb/asn.py
-+++ b/mb/mb/asn.py
-@@ -17,7 +17,7 @@ def iplookup(conn, s):
-         ips = []
-         ip6s = []
-         try:
--            for res in socket.getaddrinfo(s, 0):
-+            for res in socket.getaddrinfo(s, None):
-                 af, socktype, proto, canonname, sa = res
-                 if ':' in sa[0]:
-                     if sa[0] not in ip6s:
--- 
-1.8.4.1
-

Deleted: csw/mgar/pkg/mirrorbrain/trunk/files/0001-Exit-if-geoip-file-cannot-be-opened.patch
===================================================================
--- csw/mgar/pkg/mirrorbrain/trunk/files/0001-Exit-if-geoip-file-cannot-be-opened.patch	2014-02-02 20:43:29 UTC (rev 22933)
+++ csw/mgar/pkg/mirrorbrain/trunk/files/0001-Exit-if-geoip-file-cannot-be-opened.patch	2014-02-02 20:52:12 UTC (rev 22934)
@@ -1,43 +0,0 @@
-From b9bad73a01288801847ba7f01c1980453885cab7 Mon Sep 17 00:00:00 2001
-From: Dagobert Michelsen <dam at opencsw.org>
-Date: Sun, 26 Jan 2014 21:28:31 +0100
-Subject: [PATCH] Exit if geoip file cannot be opened
-
----
- tools/geoiplookup_city.c      | 4 ++++
- tools/geoiplookup_continent.c | 4 ++++
- 2 files changed, 8 insertions(+)
-
-diff --git a/tools/geoiplookup_city.c b/tools/geoiplookup_city.c
-index 2b33c1d..6faed7e 100644
---- a/tools/geoiplookup_city.c
-+++ b/tools/geoiplookup_city.c
-@@ -58,6 +58,10 @@ int main(int argc, char **argv) {
-         }
- 
- 	gip = GeoIP_open(geoipfilename, GEOIP_STANDARD);
-+	if( gip == NULL ) {
-+		printf("An error occured during GeoIP_open\n");
-+		return 1;
-+	}
- 	edition = GeoIP_database_edition(gip);
- 
- 	if (edition == GEOIP_COUNTRY_EDITION) {
-diff --git a/tools/geoiplookup_continent.c b/tools/geoiplookup_continent.c
-index 983afe2..871b247 100644
---- a/tools/geoiplookup_continent.c
-+++ b/tools/geoiplookup_continent.c
-@@ -56,6 +56,10 @@ int main(int argc, char **argv) {
-         }
- 
- 	gip = GeoIP_open(geoipfilename, GEOIP_STANDARD);
-+	if( gip == NULL ) {
-+		printf("An error occured during GeoIP_open\n");
-+		return 1;
-+	}
- 	edition = GeoIP_database_edition(gip);
- 
- 	if (edition == GEOIP_COUNTRY_EDITION) {
--- 
-1.8.4.1
-

Deleted: csw/mgar/pkg/mirrorbrain/trunk/files/0001-Make-geoip-database-position-adjustable.patch
===================================================================
--- csw/mgar/pkg/mirrorbrain/trunk/files/0001-Make-geoip-database-position-adjustable.patch	2014-02-02 20:43:29 UTC (rev 22933)
+++ csw/mgar/pkg/mirrorbrain/trunk/files/0001-Make-geoip-database-position-adjustable.patch	2014-02-02 20:52:12 UTC (rev 22934)
@@ -1,46 +0,0 @@
-From 8fc9dd041d6c86b62ef81c69f9a121941799be02 Mon Sep 17 00:00:00 2001
-From: Dagobert Michelsen <dam at opencsw.org>
-Date: Thu, 19 Dec 2013 23:14:38 +0100
-Subject: [PATCH] Make geoip database position adjustable
-
----
- tools/geoiplookup_city.c      | 6 ++++--
- tools/geoiplookup_continent.c | 2 ++
- 2 files changed, 6 insertions(+), 2 deletions(-)
-
-diff --git a/tools/geoiplookup_city.c b/tools/geoiplookup_city.c
-index 9c1c24e..2b33c1d 100644
---- a/tools/geoiplookup_city.c
-+++ b/tools/geoiplookup_city.c
-@@ -27,10 +27,12 @@
- #include <GeoIP.h>
- #include <GeoIPCity.h>
- 
--#define DEFAULT_GEOIPFILE "/var/lib/GeoIP/GeoLiteCity.dat"
-+#ifndef DEFAULT_GEOIPCITYFILE
-+#define DEFAULT_GEOIPCITYFILE "/var/lib/GeoIP/GeoLiteCity.dat"
-+#endif
- 
- int main(int argc, char **argv) {
--	const char *geoipfilename = DEFAULT_GEOIPFILE;
-+	const char *geoipfilename = DEFAULT_GEOIPCITYFILE;
- 	GeoIP *gip = NULL;
- 	GeoIPRecord *gir = NULL;
- 	char *name;
-diff --git a/tools/geoiplookup_continent.c b/tools/geoiplookup_continent.c
-index 1691e8a..983afe2 100644
---- a/tools/geoiplookup_continent.c
-+++ b/tools/geoiplookup_continent.c
-@@ -25,7 +25,9 @@
- #include <GeoIP.h>
- #include <GeoIPCity.h>
- 
-+#ifndef DEFAULT_GEOIPFILE
- #define DEFAULT_GEOIPFILE "/var/lib/GeoIP/GeoIP.dat"
-+#endif
- 
- int main(int argc, char **argv) {
- 	const char *geoipfilename = DEFAULT_GEOIPFILE;
--- 
-1.8.3.4
-

Copied: csw/mgar/pkg/mirrorbrain/trunk/files/CSWap2-mod-autoindex-mb.postinstall (from rev 22420, csw/mgar/pkg/mod_asn/trunk/files/CSWap2-mod-asn.postinstall)
===================================================================
--- csw/mgar/pkg/mirrorbrain/trunk/files/CSWap2-mod-autoindex-mb.postinstall	                        (rev 0)
+++ csw/mgar/pkg/mirrorbrain/trunk/files/CSWap2-mod-autoindex-mb.postinstall	2014-02-02 20:52:12 UTC (rev 22934)
@@ -0,0 +1,30 @@
+#!/bin/sh
+
+CSW_PREFIX=${PKG_INSTALL_ROOT}/opt/csw
+AP2_PREFIX=$CSW_PREFIX/apache2
+AP2_BINDIR=$AP2_PREFIX/sbin
+AP2_LIBEXEC=$AP2_PREFIX/libexec
+AP2_CONFDIR=$AP2_PREFIX/etc
+AP2_EXTRADIR=$AP2_CONFDIR/extra
+AP2_CONFIG=$AP2_CONFDIR/httpd.conf
+
+PKG_INSTALL_ROOT=${PKG_INSTALL_ROOT:-'/'}
+# Disable the autoindex module
+chroot $PKG_INSTALL_ROOT \
+    $AP2_BINDIR/apxs -S LIBEXECDIR=$AP2_LIBEXEC -e -A -n \
+    autoindex mod_autoindex.so
+# Enable the autoindex_mb module
+chroot $PKG_INSTALL_ROOT \
+    $AP2_BINDIR/apxs -S LIBEXECDIR=$AP2_LIBEXEC -e -a -n \
+    autoindex_mb mod_autoindex_mb.so
+
+# Finito
+cat <<END
+
+NOTICE: mod_autoindex_mb is enabled in httpd.conf but the server was not restarted.
+        mod_autoindex has been disabled in httpd.conf as it is incompatible with mod_autoindex_mb.
+        Please check your configuration and restart apache.
+
+END
+
+exit 0

Copied: csw/mgar/pkg/mirrorbrain/trunk/files/CSWap2-mod-autoindex-mb.preremove (from rev 22420, csw/mgar/pkg/mod_asn/trunk/files/CSWap2-mod-asn.preremove)
===================================================================
--- csw/mgar/pkg/mirrorbrain/trunk/files/CSWap2-mod-autoindex-mb.preremove	                        (rev 0)
+++ csw/mgar/pkg/mirrorbrain/trunk/files/CSWap2-mod-autoindex-mb.preremove	2014-02-02 20:52:12 UTC (rev 22934)
@@ -0,0 +1,24 @@
+#!/bin/sh
+
+CSW_PREFIX=${PKG_INSTALL_ROOT}/opt/csw
+AP2_PREFIX=$CSW_PREFIX/apache2
+AP2_BINDIR=$AP2_PREFIX/sbin
+AP2_LIBEXEC=$AP2_PREFIX/libexec
+AP2_CONFDIR=$AP2_PREFIX/etc
+AP2_EXTRADIR=$AP2_CONFDIR/extra
+AP2_CONFIG=$AP2_CONFDIR/httpd.conf
+
+# Disable the autoindex_mb module
+PKG_INSTALL_ROOT=${PKG_INSTALL_ROOT:-'/'}
+chroot $PKG_INSTALL_ROOT \
+    $AP2_BINDIR/apxs -S LIBEXECDIR=$AP2_LIBEXEC -e -A -n \
+    asn mod_autoindex_mb.so
+
+cat <<END
+
+NOTICE: mod_autoindex_mb is disabled in httpd.conf but the server was not restarted.
+        Please check your configuration and restart apache.
+
+END
+
+exit 0

Copied: csw/mgar/pkg/mirrorbrain/trunk/files/CSWap2-mod-mirrorbrain.postinstall (from rev 22420, csw/mgar/pkg/mod_asn/trunk/files/CSWap2-mod-asn.postinstall)
===================================================================
--- csw/mgar/pkg/mirrorbrain/trunk/files/CSWap2-mod-mirrorbrain.postinstall	                        (rev 0)
+++ csw/mgar/pkg/mirrorbrain/trunk/files/CSWap2-mod-mirrorbrain.postinstall	2014-02-02 20:52:12 UTC (rev 22934)
@@ -0,0 +1,25 @@
+#!/bin/sh
+
+CSW_PREFIX=${PKG_INSTALL_ROOT}/opt/csw
+AP2_PREFIX=$CSW_PREFIX/apache2
+AP2_BINDIR=$AP2_PREFIX/sbin
+AP2_LIBEXEC=$AP2_PREFIX/libexec
+AP2_CONFDIR=$AP2_PREFIX/etc
+AP2_EXTRADIR=$AP2_CONFDIR/extra
+AP2_CONFIG=$AP2_CONFDIR/httpd.conf
+
+# Enable the mirrorbrain module
+PKG_INSTALL_ROOT=${PKG_INSTALL_ROOT:-'/'}
+chroot $PKG_INSTALL_ROOT \
+    $AP2_BINDIR/apxs -S LIBEXECDIR=$AP2_LIBEXEC -e -a -n \
+    mirrorbrain mod_mirrorbrain.so
+
+# Finito
+cat <<END
+
+NOTICE: mod_mirrorbrain is enabled in httpd.conf but the server was not restarted.
+        Please check your configuration and restart apache.
+
+END
+
+exit 0

Copied: csw/mgar/pkg/mirrorbrain/trunk/files/CSWap2-mod-mirrorbrain.preremove (from rev 22420, csw/mgar/pkg/mod_asn/trunk/files/CSWap2-mod-asn.preremove)
===================================================================
--- csw/mgar/pkg/mirrorbrain/trunk/files/CSWap2-mod-mirrorbrain.preremove	                        (rev 0)
+++ csw/mgar/pkg/mirrorbrain/trunk/files/CSWap2-mod-mirrorbrain.preremove	2014-02-02 20:52:12 UTC (rev 22934)
@@ -0,0 +1,24 @@
+#!/bin/sh
+
+CSW_PREFIX=${PKG_INSTALL_ROOT}/opt/csw
+AP2_PREFIX=$CSW_PREFIX/apache2
+AP2_BINDIR=$AP2_PREFIX/sbin
+AP2_LIBEXEC=$AP2_PREFIX/libexec
+AP2_CONFDIR=$AP2_PREFIX/etc
+AP2_EXTRADIR=$AP2_CONFDIR/extra
+AP2_CONFIG=$AP2_CONFDIR/httpd.conf
+
+# Disable the mirrorbrain module
+PKG_INSTALL_ROOT=${PKG_INSTALL_ROOT:-'/'}
+chroot $PKG_INSTALL_ROOT \
+    $AP2_BINDIR/apxs -S LIBEXECDIR=$AP2_LIBEXEC -e -A -n \
+    mirrorbrain mod_mirrorbrain.so
+
+cat <<END
+
+NOTICE: mod_mirrorbrain is disabled in httpd.conf but the server was not restarted.
+        Please check your configuration and restart apache.
+
+END
+
+exit 0

This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.



More information about the devel mailing list