]> git.sur5r.net Git - bacula/bacula/commitdiff
Resolve bug 181
authorScott Barninger <scott@barninger.com>
Sun, 6 Feb 2005 14:27:55 +0000 (14:27 +0000)
committerScott Barninger <scott@barninger.com>
Sun, 6 Feb 2005 14:27:55 +0000 (14:27 +0000)
git-svn-id: https://bacula.svn.sourceforge.net/svnroot/bacula/trunk@1817 91ce42f0-d328-0410-95d8-f526ca767f89

bacula/platforms/gentoo/1.36.1-cdrecord-configure.patch [new file with mode: 0644]
bacula/platforms/gentoo/bacula.ebuild

diff --git a/bacula/platforms/gentoo/1.36.1-cdrecord-configure.patch b/bacula/platforms/gentoo/1.36.1-cdrecord-configure.patch
new file mode 100644 (file)
index 0000000..573e7bd
--- /dev/null
@@ -0,0 +1,18 @@
+--- configure.old      2005-02-06 07:44:05.221997769 -0500
++++ configure  2005-02-06 07:45:18.300994158 -0500
+@@ -7478,15 +7478,6 @@
+ # get scsibus,target,lun
+ # -------------------------------------------
+ CDSTL="3,0,0"
+-if test ! x$CDRECORD = x ; then
+-   CDSTL=`${CDRECORD} -scanbus 2>/dev/null | grep CD-RW | ${AWK} '{print $1}'`
+-   if test x${CDSTL} = x ; then
+-      CDSTL=`${CDRECORD} -scanbus 2>/dev/null | grep CD+RW | ${AWK} '{print $1}'`
+-   fi
+-   if test x${CDSTL} = x ; then
+-      CDSTL="3,0,0"
+-   fi
+-fi
index 4b6f2653d674e8ee50dc82c9e60c7f982764c0bb..b98b779ff64b7b3ae95d06f9b8ca8ae721918f24 100644 (file)
 # write to /dev/sg0 - still can't reproduce this behavior
 # add an 'addpredict /dev/sg0'
 # 08 Dec 2004 D. Scott Barninger
+#
+# resolve bug #181 - problem is caused by configure calling cdrecord to scan
+# the scsi bus. patch configure to remove this. add logrotate script.
+# 06 Feb 2005 D. Scott Barninger
 
 DESCRIPTION="featureful client/server network backup suite"
 HOMEPAGE="http://www.bacula.org/"
@@ -53,6 +57,8 @@ RDEPEND="${DEPEND}
 
 src_compile() {
 
+       epatch ${FILESDIR}/1.36.1-cdrecord-configure.patch
+
        local myconf=""
 
        # define this to skip building the other daemons ...
@@ -99,7 +105,8 @@ src_compile() {
        fi
 
        # some users report sandbox violations
-       addpredict /dev/sg0
+       # should not be needed with above configure patch
+       #addpredict /dev/sg0
 
        ./configure \
                --enable-smartalloc \
@@ -198,6 +205,11 @@ src_install() {
        cp ${S}/src/filed/static-bacula-fd ${D}/etc/bacula/rescue/cdrom/bin/bacula-fd
        chmod 754 ${D}/etc/bacula/rescue/cdrom/bin/bacula-fd
 
+       # the logrotate configuration
+       mkdir -p ${D}/etc/logrotate.d
+       cp ${S}/scripts/logrotate ${D}/etc/logrotate.d/bacula
+       chmod 644 ${D}/etc/logrotate.d/bacula
+
        # documentation
        for a in ${S}/{Changelog,README,ReleaseNotes,kernstodo,LICENSE,doc/bacula.pdf}
        do
@@ -238,7 +250,10 @@ pkg_postinst() {
        einfo
        einfo "The CDRom rescue disk package has been installed into the"
        einfo "/etc/bacula/rescue/cdrom/ directory. Please examine the manual"
-       einfo "for information on creating a rescue CD."
+       einfo "for information on creating a rescue CD. CDR device detection"
+       einfo "during build has been disabled to prevent sandbox violations."
+       einfo "You need to examine /etc/bacula/rescue/cdrom/Makefile and adjust"
+       einfo "the device information for your CD recorder."
        einfo
 
        if [ ! $BUILD_CLIENT_ONLY ]; then