ports/163243: [MAINTAINER-UPDATE] [PATCH] databases/autobackupmysql: bugfix
Frank Wall
fw at moov.de
Tue Dec 13 12:40:04 UTC 2011
>Number: 163243
>Category: ports
>Synopsis: [MAINTAINER-UPDATE] [PATCH] databases/autobackupmysql: bugfix
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: maintainer-update
>Submitter-Id: current-users
>Arrival-Date: Tue Dec 13 12:40:04 UTC 2011
>Closed-Date:
>Last-Modified:
>Originator: Frank Wall
>Release: 7.3-RELEASE-p7
>Organization:
>Environment:
FreeBSD 7.3-RELEASE-p7 FreeBSD 7.3-RELEASE-p7 #0: Tue Sep 27 13:10:21 UTC 2011 root at amd64-builder.daemonology.net:/usr/obj/usr/src/sys/GENERIC amd64
>Description:
small bugfix for databases/autobackupmysql:
- replace GNU sed pattern with BSD equivalent (thanks to Cameron Berkenpas!)
- add my self-hosted mirror dl.moov.de
- bump PORTREVISION
>How-To-Repeat:
>Fix:
apply patch to the ports tree
Patch attached with submission follows:
--- databases/autobackupmysql/Makefile.orig 2011-12-13 13:24:30.000000000 +0100
+++ databases/autobackupmysql/Makefile 2011-12-13 13:27:44.000000000 +0100
@@ -2,13 +2,15 @@
# Date created: 2009-12-21
# Whom: Frank Wall <fw at moov.de>
#
-# $FreeBSD: ports/databases/autobackupmysql/Makefile,v 1.1 2009/12/24 23:38:54 miwi Exp $
+# $FreeBSD$
#
PORTNAME= autobackupmysql
PORTVERSION= 1.1
+PORTREVISION= 1
CATEGORIES= databases
-MASTER_SITES= SF/${PORTNAME}
+MASTER_SITES= SF/${PORTNAME} \
+ http://dl.moov.de/freebsd/${PORTNAME}/
DISTNAME= ${PORTNAME}
EXTRACT_SUFX= .sh
@@ -17,10 +19,6 @@
RUN_DEPENDS= ${LOCALBASE}/bin/bash:${PORTSDIR}/shells/bash
-.if defined(WITH_OLDBASH)
-RUN_DEPENDS= ${LOCALBASE}/bin/bash:${PORTSDIR}/shells/bash3
-.endif
-
NO_BUILD= yes
PLIST_FILES= sbin/autobackupmysql.sh
--- databases/autobackupmysql/files/patch-autobackupmysql.sh.orig 2011-12-13 13:24:34.000000000 +0100
+++ databases/autobackupmysql/files/patch-autobackupmysql.sh 2011-12-13 13:21:27.000000000 +0100
@@ -1,5 +1,5 @@
---- autobackupmysql.sh.orig 2009-12-21 15:25:29.000000000 +0100
-+++ autobackupmysql.sh 2009-12-21 16:07:01.000000000 +0100
+--- autobackupmysql.sh.orig 2009-12-18 13:23:34.000000000 +0100
++++ autobackupmysql.sh 2011-12-13 13:18:11.000000000 +0100
@@ -1,4 +1,4 @@
-#!/bin/bash
+#!/usr/local/bin/bash
@@ -17,4 +17,21 @@
else
# Username to access the MySQL server e.g. dbuser
USERNAME='dbuser'
-
+@@ -292,6 +292,7 @@
+ LOGERR=$BACKUPDIR/ERRORS_$DBHOST-`date +%N`.log # Logfile Name
+ BACKUPFILES=""
+ OPT="--quote-names --opt" # OPT string for use with mysqldump ( see man mysqldump )
++UNAME_S="`uname -s | tr "[:upper:]" "[:lower:]"`" # identify operating system
+
+ # Add --compress mysqldump option to $OPT
+ if [ "$COMMCOMP" = "yes" ];
+@@ -440,7 +441,8 @@
+ # If DBs are excluded
+ for exclude in $DBEXCLUDE
+ do
+- DBNAMES=`echo $DBNAMES | sed "s/\b$exclude\b//g"`
++ [ "$UNAME_S" = "linux" ] && DBNAMES=`echo $DBNAMES | sed "s/\b$exclude\b//g"`
++ [ "$UNAME_S" = "freebsd" ] && DBNAMES=`echo $DBNAMES | sed "s/[[:<:]]$exclude[[:>:]]//g"`
+ done
+
+ MDBNAMES=$DBNAMES
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list