aboutsummaryrefslogtreecommitdiffstats
path: root/sysutils
diff options
context:
space:
mode:
authoritetcu <itetcu@FreeBSD.org>2007-01-05 07:22:30 +0800
committeritetcu <itetcu@FreeBSD.org>2007-01-05 07:22:30 +0800
commitf7deb8f224d5a48951c6961cd255011e4b7c2563 (patch)
tree615e38cf34021243aaa8fe003b034b3b585425b1 /sysutils
parentc6b9d86371d2eafcfe698cafb30cb04b15e153e1 (diff)
downloadfreebsd-ports-gnome-f7deb8f224d5a48951c6961cd255011e4b7c2563.tar.gz
freebsd-ports-gnome-f7deb8f224d5a48951c6961cd255011e4b7c2563.tar.zst
freebsd-ports-gnome-f7deb8f224d5a48951c6961cd255011e4b7c2563.zip
Move bacula-server-devel into bacula-server, now that 2.0.0
has been released. Split the documentation into a new port, sysutils/bacula-docs. You must run the database upgrade script after upgrading to Bacula 2.0.0 Many new features here. See http://www.bacula.org/?page=presskits for an overview, and ReleaseNotes for full details. PR: ports/107535 Submitted by: Dan Langille (maintainer)
Diffstat (limited to 'sysutils')
-rw-r--r--sysutils/bacula-server/Makefile129
-rw-r--r--sysutils/bacula-server/distinfo12
-rw-r--r--sysutils/bacula-server/files/bacula-dir.in3
-rw-r--r--sysutils/bacula-server/files/bacula-fd.in3
-rw-r--r--sysutils/bacula-server/files/bacula-sd.in5
-rw-r--r--sysutils/bacula-server/files/patch-configure21
-rw-r--r--sysutils/bacula-server/files/patch-scripts-Makefile.in36
-rw-r--r--sysutils/bacula-server/files/pkg-deinstall.client.in7
-rw-r--r--sysutils/bacula-server/files/pkg-install.client.in26
-rw-r--r--sysutils/bacula-server/files/pkg-message.client.in23
-rw-r--r--sysutils/bacula-server/files/pkg-message.in20
-rw-r--r--sysutils/bacula-server/files/pkg-message.server.in66
-rw-r--r--sysutils/bacula-server/pkg-deinstall.client7
-rw-r--r--sysutils/bacula-server/pkg-install.client26
-rw-r--r--sysutils/bacula-server/pkg-plist31
-rw-r--r--sysutils/bacula-server/pkg-plist.client1
16 files changed, 221 insertions, 195 deletions
diff --git a/sysutils/bacula-server/Makefile b/sysutils/bacula-server/Makefile
index 1cb57e515588..85b99421fbd1 100644
--- a/sysutils/bacula-server/Makefile
+++ b/sysutils/bacula-server/Makefile
@@ -6,29 +6,36 @@
#
PORTNAME= bacula
-DISTVERSION= 1.38.11
-PORTREVISION= 3
+DISTVERSION= 2.0.0
CATEGORIES= sysutils
MASTER_SITES= ${MASTER_SITE_SOURCEFORGE}
MASTER_SITE_SUBDIR= bacula
-PKGNAMESUFFIX?= -server
MAINTAINER= dan@langille.org
COMMENT?= The network backup solution (server)
-CONFLICTS= bacula-server-devel-[0-9]* bacula-client-devel-[0-9]*
+PKGNAMESUFFIX?= -server
+
+CONFLICTS= bacula-server-devel-[0-9]* bacula-client-devel-[0-9]* bacula-docs-devel-[0-9]*
UNIQUENAME?=${PORTNAME}${PKGNAMESUFFIX}
+DISTFILES= ${PORTNAME}-${PORTVERSION}.tar.gz
+
USE_RC_SUBR?= bacula-dir bacula-sd
-SUB_FILES+= pkg-message
+.if defined(WITH_CLIENT_ONLY)
+SUB_FILES+= pkg-message.client
+.else
+SUB_FILES+= pkg-message.server
+.endif
# The user/group IDs below are registered, see
# http://www.freebsd.org/doc/en_US.ISO8859-1/books/porters-handbook/book.html#DADS-UID
#
BACULA_DIR?=/var/db/bacula
#
+MANCOMPRESSED= yes
GNU_CONFIGURE= yes
CONFIGURE_ARGS= --with-tcp-wrappers=/usr/lib \
--enable-smartalloc \
@@ -53,8 +60,6 @@ CONFIGURE_ENV+= CPPFLAGS="-I/usr/include/readline -I${LOCALBASE}/include" \
PTHREAD_CFLAGS="${PTHREAD_CFLAGS}" \
PTHREAD_LIBS="${PTHREAD_LIBS}"
-ALL_OPTIONS= CLIENT_ONLY WXCONSOLE GNOMECONSOLE SQLITE3 MYSQL POSTGRESQL MTX OPENSSL DOCS
-
.for opt in ${ALL_OPTIONS}
.if defined(WITH_${opt})
BATCH= yes
@@ -68,7 +73,6 @@ IS_INTERACTIVE= yes
.if defined(WITH_CLIENT_ONLY)
OPTIONS+= WXCONSOLE "Build with wxGTK based GUI console" off
OPTIONS+= GNOMECONSOLE "Build with GNOME based GUI console" off
-OPTIONS+= DOCS "Install documention" off
.else
OPTIONS= SQLITE3 "Use SqLite-3 database instead of SqLite-2" off
OPTIONS+= MYSQL "Use MySQL database instead of SqLite" off
@@ -88,24 +92,13 @@ USE_GNOME= libgnome
PLIST_SUB+= BACULA_DIR=${BACULA_DIR}
-MAN8= bacula.8
-
.include <bsd.port.pre.mk>
-DISTFILES= ${PORTNAME}-${PORTVERSION}.tar.gz
-.if defined(WITH_DOCS)
-DISTFILES+= ${PORTNAME}-docs-${PORTVERSION}-1.tar.gz
-.endif
-
-.if defined(WITH_DOCS)
-PORTDOCS= ReleaseNotes bacula.pdf developers.pdf kernstodo manual bacula-web
-.endif
-
.if defined(WITH_NLS)
USE_GETTEXT= yes
CONFIGURE_ARGS+= --enable-nls
.else
-CONFIGURE_ARGS+= --disable-nls
+CONFIGURE_ARGS+= --disable-nls
.endif
# Client only or full server version
@@ -171,8 +164,13 @@ CONFIGURE_ARGS+= --with-openssl
.endif
.if defined(WITH_CLIENT_ONLY)
-MAN8=bacula.8
+MAN8=bacula-fd.8 bconsole.8
+.else
+MAN8=bacula.8 bacula-dir.8 bacula-sd.8 bcopy.8 bextract.8 bls.8 bscan.8 btape.8 btraceback.8 dbcheck.8
+MAN1=bsmtp.1 bacula-console-gnome.1 bacula-tray-monitor.1 bacula-wxconsole.1
.endif
+MAKE_ARGS+= -E MAN8 -E MAN1
+MAKE_ENV+= MAN8="${MAN8}" MAN1="${MAN1}"
pre-everything::
.if !defined(WITH_CLIENT_ONLY)
@@ -196,7 +194,6 @@ pre-everything::
@${ECHO_MSG} ""
@${ECHO_MSG} "The default DB is SQLite-2!"
.endif
- @${ECHO_MSG} " WITH_DOCS=yes if you want the documentation installed."
@${ECHO_MSG} " WITH_OPENSSL=yes Enable OpenSSL for encrypted communication."
@${ECHO_MSG} ""
@${ECHO_MSG} "===> Using ${DBTYPE} as the bacula database."
@@ -212,10 +209,10 @@ post-patch:
# In client port only install startup script out of script dir (see below post-install)
# Dont mkdir ${PREFIX}/share/bacula cause it's empty
@${REINPLACE_CMD} -e 's|^\(fd_subdirs = .*\)scripts\(.*\)|\1\2|g' ${WRKSRC}/Makefile.in
- ${REINPLACE_CMD} -e 's|\(.*$$(MKDIR) $$(DESTDIR)$$(scriptdir)\)|#\1|g' ${WRKSRC}/Makefile.in
+ ${REINPLACE_CMD} -e 's|\(.*$${MKDIR} $${DESTDIR}$${scriptdir}\)|#\1|g' ${WRKSRC}/Makefile.in
.else
# In server port don't install filed
- @${REINPLACE_CMD} -e 's|^all_subdirs = .*|all_subdirs = scripts src\/lib src\/findlib $${subdirs}|g' ${WRKSRC}/Makefile.in
+ @${REINPLACE_CMD} -e '/^fd_subdirs = /s|src/filed||' -e 's|src/console||' ${WRKSRC}/Makefile.in
.endif
pre-install:
@@ -226,11 +223,9 @@ pre-install:
${ECHO_CMD} "${BACULA_DIR} already exists"; \
fi
-.if !defined(WITH_CLIENT_ONLY)
# Extend /etc/services and install UID/GID
@ ${SETENV} PKG_PREFIX=${PREFIX} \
${SH} ${PKGINSTALL} ${PORTNAME} PRE-INSTALL
-.endif
post-install:
.if defined(WITH_CLIENT_ONLY)
@@ -240,8 +235,10 @@ post-install:
# Console stuff
if [ -f ${PREFIX}/etc/bconsole.conf.new ]; then \
${ECHO_CMD} "etc/bconsole.conf.new" >> ${TMPPLIST}; \
+ ${CHGRP} bacula ${PREFIX}/etc/bconsole.conf.new; \
elif [ -f ${PREFIX}/etc/bconsole.conf ]; then \
${MV} ${PREFIX}/etc/bconsole.conf ${PREFIX}/etc/bconsole.conf.sample; \
+ ${CHGRP} bacula ${PREFIX}/etc/bconsole.conf.sample; \
${ECHO_CMD} "etc/bconsole.conf.sample" >> ${TMPPLIST}; \
fi
.if defined(WITH_WXCONSOLE)
@@ -261,23 +258,8 @@ post-install:
fi
.endif
-.if defined(WITH_CLIENT_ONLY)
- ${INSTALL_MAN} ${WRKSRC}/scripts/bacula.man ${PREFIX}/man/man8/bacula.8
-.endif
-
-# Documentation is only installed in -client port
-.if defined(WITH_DOCS)
- for na in manual bacula-web; do \
- ${MKDIR} ${DOCSDIR}/$$na ;\
- cd ${WRKDIR}/${PORTNAME}-docs-${PORTVERSION}-1 && ${FIND} $$na | \
- ${CPIO} -pdm -L -R root:wheel ${DOCSDIR}; \
- done
- ${INSTALL_DATA} ${WRKDIR}/${PORTNAME}-${PORTVERSION}/ReleaseNotes ${DOCSDIR}
- ${INSTALL_DATA} ${WRKDIR}/${PORTNAME}-docs-${PORTVERSION}-1/manual/bacula.pdf ${DOCSDIR}
- ${INSTALL_DATA} ${WRKDIR}/${PORTNAME}-docs-${PORTVERSION}-1/developers/developers.pdf ${DOCSDIR}
- ${INSTALL_DATA} ${WRKDIR}/${PORTNAME}-${PORTVERSION}/kernstodo ${DOCSDIR}
-.endif
-
+# ensure that users in the bacula group can run bconsole
+ ${CHGRP} bacula ${PREFIX}/sbin/bconsole
.else
# Install config files and preserve existing ones
${INSTALL_SCRIPT} ${FILESDIR}/chio-bacula ${PREFIX}/sbin
@@ -291,6 +273,7 @@ post-install:
# chmod of bsmtp program so bacula can use it with dropped down permissions
${CHMOD} o+x ${PREFIX}/sbin/bsmtp
${CHOWN} -R bacula:bacula ${PREFIX}/share/bacula
+
.endif
# Install leaves existing conf files untouched. Respect this here!
for na in ${CONFFILES}; do \
@@ -302,64 +285,6 @@ post-install:
fi; \
done
-# Inform user after install about important things ....
- @${ECHO_MSG} "*********************************************************************"
- @${ECHO_MSG} "NOTE:"
- @${ECHO_MSG} "Sample files are installed in ${PREFIX}/etc:"
- @${ECHO_MSG} " bconsole.conf.sample, bacula-barcodes.sample, bacula-fd.conf.sample"
-.if !defined(WITH_CLIENT_ONLY)
- @${ECHO_MSG} " bacula-sd.conf.sample, bacula-dir.conf.sample"
- @${ECHO_MSG} ""
- @${ECHO_MSG} "An auto-changer manipulation script based on FreeBSDs"
- @${ECHO_MSG} "chio command is included and installed at"
- @${ECHO_MSG} ""
- @${ECHO_MSG} " ${PREFIX}/sbin/chio-bacula"
- @${ECHO_MSG} ""
- @${ECHO_MSG} "Please have a look at it if you want to use an"
- @${ECHO_MSG} "autochanger. You have to configure the usage in"
- @${ECHO_MSG} ""
- @${ECHO_MSG} " ${PREFIX}/etc/bacula-dir.conf"
- @${ECHO_MSG} ""
- @${ECHO_MSG} "Take care of correct permissions for changer and"
- @${ECHO_MSG} "tape device (e.g. /dev/ch0 and /dev/n[r]sa0) i.e."
- @${ECHO_MSG} "they must be accessible by user bacula."
- @${ECHO_MSG} ""
- @${ECHO_MSG} "Due to lack of some features in the FreeBSD tape driver"
- @${ECHO_MSG} "implementation you MUST add some OS dependent options to"
- @${ECHO_MSG} "the bacula-sd.conf file:"
- @${ECHO_MSG} ""
- @${ECHO_MSG} " Hardware End of Medium = no;"
- @${ECHO_MSG} " Backward Space Record = no;"
- @${ECHO_MSG} " Backward Space File = no;"
- @${ECHO_MSG} ""
- @${ECHO_MSG} "With 2 filemarks at EOT (see man mt):"
- @${ECHO_MSG} " Fast Forward Space File = no;"
- @${ECHO_MSG} " BSF at EOM = yes;"
- @${ECHO_MSG} " TWO EOF = yes;"
- @${ECHO_MSG} ""
- @${ECHO_MSG} "With 1 filemarks at EOT (see man mt):"
- @${ECHO_MSG} " Fast Forward Space File = yes;"
- @${ECHO_MSG} " BSF at EOM = no;"
- @${ECHO_MSG} " TWO EOF = no;"
- @${ECHO_MSG} ""
- @${ECHO_MSG} "NOTE: YOU CAN SWITCH EOT model ONLY when starting"
- @${ECHO_MSG} " from scratch with EMPTY tapes!!!!"
- @${ECHO_MSG} ""
- @${ECHO_MSG} "It is also important that all the scripts accessed"
- @${ECHO_MSG} "by RunBeforeJob and RunAfterJob can be executed by"
- @${ECHO_MSG} "the user bacula."
- @${ECHO_MSG} ""
- @${ECHO_MSG} "For USB support read the bacula manual!! It could be necessary"
- @${ECHO_MSG} "to configure/compile a new kernel!"
- @${ECHO_MSG} ""
- @${ECHO_MSG} "Look at ${PREFIX}/share/bacula/update_bacula_tables for"
- @${ECHO_MSG} "database update procedure. Details can be found in the"
- @${ECHO_MSG} "ReleaseNotes"
-.endif
- @${ECHO_MSG} "*********************************************************************"
-
-.if defined(WITH_DOCS)
- ${CAT} ${PKGMESSAGE}
-.endif
+ @${CAT} ${PKGMESSAGE}
.include <bsd.port.post.mk>
diff --git a/sysutils/bacula-server/distinfo b/sysutils/bacula-server/distinfo
index 670fd2fd100c..84cefa662ed5 100644
--- a/sysutils/bacula-server/distinfo
+++ b/sysutils/bacula-server/distinfo
@@ -1,6 +1,6 @@
-MD5 (bacula-1.38.11.tar.gz) = 0d6d6614afdc468d214de4e66f9f5a26
-SHA256 (bacula-1.38.11.tar.gz) = d095165d256771c918b80f836feaf837aedc1362b2d67171013d3ab7ac5ee47f
-SIZE (bacula-1.38.11.tar.gz) = 2078095
-MD5 (bacula-docs-1.38.11-1.tar.gz) = ea827e52b24787edcb04bfd073434501
-SHA256 (bacula-docs-1.38.11-1.tar.gz) = f38ab74f782425c1a8ee30c63e0fc4af6101849deba12adf719f4c93af2c66fd
-SIZE (bacula-docs-1.38.11-1.tar.gz) = 24774751
+MD5 (bacula-docs-2.0.0.tar.gz) = 9fe0efdf50c82f40f15b3ea6c7ad7ed6
+SHA256 (bacula-docs-2.0.0.tar.gz) = 6f5b9bfe171800bf06dbb48b3a265febc6f1797e0dde657bffdf962b096852b0
+SIZE (bacula-docs-2.0.0.tar.gz) = 28132575
+MD5 (bacula-2.0.0.tar.gz) = fbf990e64eb895a674c52c0de5acf0cd
+SHA256 (bacula-2.0.0.tar.gz) = 208aa7a65983a515b32f5e28d4f46468a4823f00685c679560f86f8f3e5386ee
+SIZE (bacula-2.0.0.tar.gz) = 2488471
diff --git a/sysutils/bacula-server/files/bacula-dir.in b/sysutils/bacula-server/files/bacula-dir.in
index 5bfa0eeb10e2..5739a308b77a 100644
--- a/sysutils/bacula-server/files/bacula-dir.in
+++ b/sysutils/bacula-server/files/bacula-dir.in
@@ -19,10 +19,11 @@
name="bacula_dir"
rcvar=${name}_enable
command=%%PREFIX%%/sbin/bacula-dir
-pidfile="${bacula_dir_pidfile}"
load_rc_config $name
+pidfile="${bacula_dir_pidfile}"
+
: ${bacula_dir_enable="NO"}
: ${bacula_dir_flags=" -u bacula -g bacula -v -c %%PREFIX%%/etc/bacula-dir.conf"}
: ${bacula_dir_pidfile="/var/run/bacula-dir.9101.pid"}
diff --git a/sysutils/bacula-server/files/bacula-fd.in b/sysutils/bacula-server/files/bacula-fd.in
index 5cf5fcf38f0f..b6539219b683 100644
--- a/sysutils/bacula-server/files/bacula-fd.in
+++ b/sysutils/bacula-server/files/bacula-fd.in
@@ -19,10 +19,11 @@
name="bacula_fd"
rcvar=${name}_enable
command=/usr/local/sbin/bacula-fd
-pidfile="${bacula_fd_pidfile}"
load_rc_config $name
+pidfile="${bacula_fd_pidfile}"
+
: ${bacula_fd_enable="NO"}
: ${bacula_fd_flags=" -u root -g wheel -v -c /usr/local/etc/bacula-fd.conf"}
: ${bacula_fd_pidfile="/var/run/bacula-fd.9102.pid"}
diff --git a/sysutils/bacula-server/files/bacula-sd.in b/sysutils/bacula-server/files/bacula-sd.in
index e851f6212c7d..ac78f5ce889a 100644
--- a/sysutils/bacula-server/files/bacula-sd.in
+++ b/sysutils/bacula-server/files/bacula-sd.in
@@ -19,12 +19,13 @@
name="bacula_sd"
rcvar=`set_rcvar`
command=/usr/local/sbin/bacula-sd
-pidfile="${bacula_sd_pidfile}"
load_rc_config $name
+pidfile="${bacula_sd_pidfile}"
+
: ${bacula_sd_enable="NO"}
-: ${bacula_sd_flags=" -u bacula -g operator -v -c /usr/local/etc/bacula-sd.conf"}
+: ${bacula_sd_flags=" -u bacula -g bacula -v -c /usr/local/etc/bacula-sd.conf"}
: ${bacula_sd_pidfile="/var/run/bacula-sd.9103.pid"}
run_rc_command "$1"
diff --git a/sysutils/bacula-server/files/patch-configure b/sysutils/bacula-server/files/patch-configure
deleted file mode 100644
index f370488bbc48..000000000000
--- a/sysutils/bacula-server/files/patch-configure
+++ /dev/null
@@ -1,21 +0,0 @@
-*** configure.org Sun Mar 6 16:46:54 2005
---- configure Sun Mar 6 16:49:20 2005
-***************
-*** 29490,29497 ****
- DISTVER=`uname -a |awk '{print $3}'`
- VER=`echo $DISTVER | cut -c 1`
- if test x$VER = x4 ; then
-! PTHREAD_LIB="-pthread"
-! CFLAGS="${CFLAGS} -pthread"
- fi
- lld="qd"
- llu="qu"
---- 21037,21044 ----
- DISTVER=`uname -a |awk '{print $3}'`
- VER=`echo $DISTVER | cut -c 1`
- if test x$VER = x4 ; then
-! PTHREAD_LIB="${PTHREAD_LIBS}"
-! CFLAGS="${CFLAGS} ${PTHREAD_CFLAGS}"
- fi
- lld="qd"
- llu="qu"
diff --git a/sysutils/bacula-server/files/patch-scripts-Makefile.in b/sysutils/bacula-server/files/patch-scripts-Makefile.in
index eeb841f253db..d05246bbbcd7 100644
--- a/sysutils/bacula-server/files/patch-scripts-Makefile.in
+++ b/sysutils/bacula-server/files/patch-scripts-Makefile.in
@@ -1,33 +1,11 @@
---- scripts/Makefile.in.orig Sat Mar 25 10:37:41 2006
-+++ scripts/Makefile.in Thu Mar 30 13:01:21 2006
-@@ -33,14 +33,6 @@
+--- scripts/Makefile.in.orig Tue Sep 12 12:03:08 2006
++++ scripts/Makefile.in Tue Sep 12 12:03:08 2006
+@@ -33,8 +33,6 @@
$(MKDIR) $(DESTDIR)$(mandir)
-
+
install: installdirs
- $(INSTALL_SCRIPT) startmysql $(DESTDIR)$(scriptdir)/startmysql
- $(INSTALL_SCRIPT) stopmysql $(DESTDIR)$(scriptdir)/stopmysql
-- $(INSTALL_SCRIPT) bconsole $(DESTDIR)$(scriptdir)/bconsole
-- $(INSTALL_SCRIPT) gconsole $(DESTDIR)$(scriptdir)/gconsole
-- $(INSTALL_SCRIPT) bacula $(DESTDIR)$(scriptdir)/bacula
-- $(INSTALL_SCRIPT) bacula-ctl-dir $(DESTDIR)$(scriptdir)/bacula-ctl-dir
-- $(INSTALL_SCRIPT) bacula-ctl-fd $(DESTDIR)$(scriptdir)/bacula-ctl-fd
-- $(INSTALL_SCRIPT) bacula-ctl-sd $(DESTDIR)$(scriptdir)/bacula-ctl-sd
- @if test -f ${DESTDIR}${scriptdir}/mtx-changer; then \
- echo " ==> Saving existing mtx-changer to mtx-changer.old"; \
- $(MV) -f ${DESTDIR}${scriptdir}/mtx-changer ${DESTDIR}${scriptdir}/mtx-changer.old; \
-@@ -56,14 +48,7 @@
- $(MV) -f ${DESTDIR}${scriptdir}/dvd-handler ${DESTDIR}${scriptdir}/dvd-handler.old; \
- fi
- $(INSTALL_SCRIPT) dvd-handler $(DESTDIR)$(scriptdir)/dvd-handler
-- $(INSTALL_DATA) btraceback.gdb $(DESTDIR)$(scriptdir)/btraceback.gdb
-- $(INSTALL_DATA) btraceback.dbx $(DESTDIR)$(scriptdir)/btraceback.dbx
-- chmod 0644 $(DESTDIR)$(scriptdir)/btraceback.gdb \
-- $(DESTDIR)$(scriptdir)/btraceback.dbx
-- $(INSTALL_SCRIPT) btraceback $(DESTDIR)$(sbindir)/btraceback
-- gzip <bacula.man >bacula.8.gz
-- $(INSTALL_DATA) bacula.8.gz $(DESTDIR)$(mandir)/bacula.8.gz
-- @rm -f bacula.8.gz
-+ $(INSTALL_DATA) bacula.man $(DESTDIR)$(mandir)/bacula.8
-
-
- uninstall:
+ $(INSTALL_SCRIPT) bconsole $(DESTDIR)$(scriptdir)/bconsole
+ $(INSTALL_SCRIPT) gconsole $(DESTDIR)$(scriptdir)/gconsole
+ $(INSTALL_SCRIPT) bacula $(DESTDIR)$(scriptdir)/bacula
diff --git a/sysutils/bacula-server/files/pkg-deinstall.client.in b/sysutils/bacula-server/files/pkg-deinstall.client.in
index cadbda56ab93..206ec9efca6b 100644
--- a/sysutils/bacula-server/files/pkg-deinstall.client.in
+++ b/sysutils/bacula-server/files/pkg-deinstall.client.in
@@ -20,5 +20,12 @@ case "$2" in
if [ -d ${BACULA_DIR} ]; then
echo "Check if ${BACULA_DIR} is empty and delete it to permanently remove the bacula port"
fi
+
+ # Note how to delete UID/GID
+ USER=bacula
+ GROUP=${USER}
+ if pw groupshow "${USER}" 2>/dev/null 1>&2; then
+ echo "To delete Bacula group permanently, use 'pw groupdel ${GROUP}'"
+ fi
;;
esac
diff --git a/sysutils/bacula-server/files/pkg-install.client.in b/sysutils/bacula-server/files/pkg-install.client.in
index 7dc31b47c8b8..656acca83733 100644
--- a/sysutils/bacula-server/files/pkg-install.client.in
+++ b/sysutils/bacula-server/files/pkg-install.client.in
@@ -15,3 +15,29 @@ bacula-sd 9103/tcp #Bacula storage daemon
# Bacule port end" >> /etc/services
fi
+case $2 in
+PRE-INSTALL)
+ # Install UID/GID
+ USER=bacula
+ GROUP=${USER}
+ UID=910
+ GID=${UID}
+
+ if [ ! -d ${BACULA_DIR} ]; then
+ mkdir -p ${BACULA_DIR}
+ fi
+
+ if pw group show "${GROUP}" 2>/dev/null; then
+ echo "You already have a group \"${GROUP}\", so I will use it."
+ else
+ if pw groupadd ${GROUP} -g ${GID}; then
+ echo "Added group \"${GROUP}\"."
+ else
+ echo "Adding group \"${GROUP}\" failed..."
+ exit 1
+ fi
+ fi
+
+ chgrp -R ${GROUP} ${BACULA_DIR}
+ ;;
+esac
diff --git a/sysutils/bacula-server/files/pkg-message.client.in b/sysutils/bacula-server/files/pkg-message.client.in
new file mode 100644
index 000000000000..bb9c496d6b13
--- /dev/null
+++ b/sysutils/bacula-server/files/pkg-message.client.in
@@ -0,0 +1,23 @@
+################################################################################
+
+NOTE:
+Sample files are installed in ${PREFIX}/etc:
+bconsole.conf.sample, bacula-barcodes.sample, bacula-fd.conf.sample
+
+ Please read this file:
+
+ %%DOCSDIR%%/ReleaseNotes
+
+ as installed by docs port for the upgrade procedure.
+
+IMPORTANT UPGRADE NOTES:
+
+- A database upgrade is required.
+- Your Director and SD must be simultaneously upgraded.
+- The "Accept Any Volume" directive has been removed.
+
+- Lots of new features
+
+Read the ReleaseNotes for further information.
+
+################################################################################
diff --git a/sysutils/bacula-server/files/pkg-message.in b/sysutils/bacula-server/files/pkg-message.in
deleted file mode 100644
index d5136f5ec426..000000000000
--- a/sysutils/bacula-server/files/pkg-message.in
+++ /dev/null
@@ -1,20 +0,0 @@
-################################################################################
- Please read this file:
-
- %%DOCSDIR%%/ReleaseNotes
-
- for the upgrade procedure!
-
- IF YOU IGNORE THIS you may !! LOSE DATA !!
-
- WARNING: That file also contains important information regarding
- Windows FD, blackslashes in FileSets, and Scratch Pools.
-
- For USB support read the manual. It may be necessary
- to configure/compile a new kernel.
-
- Please note that bacula-server no longer installs the client
- and that the documentation can be optionally installed with the
- client port (sysutils/bacula-client).
-
-################################################################################
diff --git a/sysutils/bacula-server/files/pkg-message.server.in b/sysutils/bacula-server/files/pkg-message.server.in
new file mode 100644
index 000000000000..cf7423856926
--- /dev/null
+++ b/sysutils/bacula-server/files/pkg-message.server.in
@@ -0,0 +1,66 @@
+################################################################################
+NOTE:
+
+An auto-changer manipulation script based on FreeBSDs
+chio command is included and installed at
+
+ ${PREFIX}/sbin/chio-bacula
+
+Please have a look at it if you want to use an
+autochanger. You have to configure the usage in
+
+ ${PREFIX}/etc/bacula-dir.conf
+
+Take care of correct permissions for changer and
+tape device (e.g. /dev/ch0 and /dev/n[r]sa0) i.e.
+they must be accessible by user bacula.
+
+Due to lack of some features in the FreeBSD tape driver
+implementation you MUST add some OS dependent options to
+the bacula-sd.conf file:
+
+ Hardware End of Medium = no;
+ Backward Space Record = no;
+ Backward Space File = no;
+
+With 2 filemarks at EOT (see man mt):
+ Fast Forward Space File = no;
+ BSF at EOM = yes;
+ TWO EOF = yes;
+
+With 1 filemarks at EOT (see man mt):
+ Fast Forward Space File = yes;
+ BSF at EOM = no;
+ TWO EOF = no;
+
+NOTE: YOU CAN SWITCH EOT model ONLY when starting
+ from scratch with EMPTY tapes.
+
+It is also important that all the scripts accessed
+by RunBeforeJob and RunAfterJob will be executed by
+the user bacula. Check your permissions.
+
+For USB support read the bacula manual. It could be necessary
+to configure/compile a new kernel.
+
+Look at ${PREFIX}/share/bacula/update_bacula_tables for
+database update procedure. Details can be found in the
+ReleaseNotes
+
+ Please read this file:
+
+ %%DOCSDIR%%/ReleaseNotes
+
+ as installed by docs port for the upgrade procedure.
+
+IMPORTANT UPGRADE NOTES FOR THIS RELEASE:
+
+- A database upgrade is required.
+- Your Director and SD must be simultaneously upgraded.
+- The "Accept Any Volume" directive has been removed.
+
+- Lots of new features
+
+Read the ReleaseNotes for further information.
+
+################################################################################
diff --git a/sysutils/bacula-server/pkg-deinstall.client b/sysutils/bacula-server/pkg-deinstall.client
index cadbda56ab93..206ec9efca6b 100644
--- a/sysutils/bacula-server/pkg-deinstall.client
+++ b/sysutils/bacula-server/pkg-deinstall.client
@@ -20,5 +20,12 @@ case "$2" in
if [ -d ${BACULA_DIR} ]; then
echo "Check if ${BACULA_DIR} is empty and delete it to permanently remove the bacula port"
fi
+
+ # Note how to delete UID/GID
+ USER=bacula
+ GROUP=${USER}
+ if pw groupshow "${USER}" 2>/dev/null 1>&2; then
+ echo "To delete Bacula group permanently, use 'pw groupdel ${GROUP}'"
+ fi
;;
esac
diff --git a/sysutils/bacula-server/pkg-install.client b/sysutils/bacula-server/pkg-install.client
index 7dc31b47c8b8..656acca83733 100644
--- a/sysutils/bacula-server/pkg-install.client
+++ b/sysutils/bacula-server/pkg-install.client
@@ -15,3 +15,29 @@ bacula-sd 9103/tcp #Bacula storage daemon
# Bacule port end" >> /etc/services
fi
+case $2 in
+PRE-INSTALL)
+ # Install UID/GID
+ USER=bacula
+ GROUP=${USER}
+ UID=910
+ GID=${UID}
+
+ if [ ! -d ${BACULA_DIR} ]; then
+ mkdir -p ${BACULA_DIR}
+ fi
+
+ if pw group show "${GROUP}" 2>/dev/null; then
+ echo "You already have a group \"${GROUP}\", so I will use it."
+ else
+ if pw groupadd ${GROUP} -g ${GID}; then
+ echo "Added group \"${GROUP}\"."
+ else
+ echo "Adding group \"${GROUP}\" failed..."
+ exit 1
+ fi
+ fi
+
+ chgrp -R ${GROUP} ${BACULA_DIR}
+ ;;
+esac
diff --git a/sysutils/bacula-server/pkg-plist b/sysutils/bacula-server/pkg-plist
index 9f07f77ff5c6..8ba64eccb539 100644
--- a/sysutils/bacula-server/pkg-plist
+++ b/sysutils/bacula-server/pkg-plist
@@ -1,5 +1,3 @@
-%%DATADIR%%/query.sql
-sbin/chio-bacula
sbin/bacula-dir
sbin/bacula-sd
sbin/bcopy
@@ -7,31 +5,38 @@ sbin/bextract
sbin/bls
sbin/bregex
sbin/bscan
+sbin/bsmtp
sbin/btape
+sbin/btraceback
sbin/bwild
-%%WXCONS%%sbin/wx-console
-%%GNOMECONS%%sbin/gnome-console
+sbin/chio-bacula
sbin/dbcheck
-sbin/bsmtp
-@unexec if cmp -s %D/share/bacula/mtx-changer.old %D/share/bacula/mtx-changer; then rm -f %D/share/bacula/mtx-changer.old; fi
-@unexec if cmp -s %D/share/bacula/disk-changer.old %D/share/bacula/disk-changer; then rm -f %D/share/bacula/disk-changer.old; fi
-%%DATADIR%%/mtx-changer
+%%DATADIR%%/bacula
+%%DATADIR%%/bacula-ctl-dir
+%%DATADIR%%/bacula-ctl-fd
+%%DATADIR%%/bacula-ctl-sd
+%%DATADIR%%/bconsole
+%%DATADIR%%/btraceback.gdb
+%%DATADIR%%/btraceback.dbx
%%DATADIR%%/create_bacula_database
%%DATADIR%%/create_%%DBTYPE%%_database
+%%DATADIR%%/delete_catalog_backup
+%%DATADIR%%/disk-changer
%%DATADIR%%/drop_bacula_database
-%%DATADIR%%/drop_%%DBTYPE%%_database
%%DATADIR%%/drop_bacula_tables
+%%DATADIR%%/drop_%%DBTYPE%%_database
%%DATADIR%%/drop_%%DBTYPE%%_tables
+%%DATADIR%%/dvd-handler
+%%DATADIR%%/gconsole
%%DATADIR%%/grant_bacula_privileges
%%DATADIR%%/grant_%%DBTYPE%%_privileges
%%DATADIR%%/make_bacula_tables
+%%DATADIR%%/make_catalog_backup
%%DATADIR%%/make_%%DBTYPE%%_tables
+%%DATADIR%%/mtx-changer
+%%DATADIR%%/query.sql
%%DATADIR%%/update_bacula_tables
%%DATADIR%%/update_%%DBTYPE%%_tables
-%%DATADIR%%/delete_catalog_backup
-%%DATADIR%%/make_catalog_backup
-%%DATADIR%%/dvd-handler
-%%DATADIR%%/disk-changer
@dirrm %%DATADIR%%
@unexec /usr/bin/killall bacula-sd > /dev/null 2>&1 || true
diff --git a/sysutils/bacula-server/pkg-plist.client b/sysutils/bacula-server/pkg-plist.client
index 8e0a85d7c7f3..8285b9a481f6 100644
--- a/sysutils/bacula-server/pkg-plist.client
+++ b/sysutils/bacula-server/pkg-plist.client
@@ -5,3 +5,4 @@ sbin/bconsole
@unexec /usr/bin/killall badula-fd > /dev/null 2>&1 || true
@exec mkdir -p %%BACULA_DIR%%
@dirrmtry %%BACULA_DIR%%
+@dirrm share/bacula