bug #71334: automatically copy of old privatedir to new location
authorChristian Andreetta <satya@gentoo.org>
Thu, 18 Nov 2004 12:10:10 +0000 (12:10 +0000)
committerChristian Andreetta <satya@gentoo.org>
Thu, 18 Nov 2004 12:10:10 +0000 (12:10 +0000)
net-fs/samba/ChangeLog
net-fs/samba/Manifest
net-fs/samba/samba-3.0.8-r1.ebuild
net-fs/samba/samba-3.0.8.ebuild

index c5824e15a192c1cc0a8f7ccdd4fd5cc12d4f36c5..c29bbd3e68a56efceda04542054e8cb040576664 100644 (file)
@@ -1,6 +1,10 @@
 # ChangeLog for net-fs/samba
 # Copyright 2002-2004 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-fs/samba/ChangeLog,v 1.130 2004/11/15 10:12:30 satya Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-fs/samba/ChangeLog,v 1.131 2004/11/18 12:10:10 satya Exp $
+
+  18 Nov 2004; Christian Andreetta <satya@gentoo.org> samba-3.0.8-r1.ebuild,
+  samba-3.0.8.ebuild:
+  bug #71334: automatically copy of old privatedir to new location
 
 *samba-3.0.8-r1 (15 Nov 2004)
 
index be42504f7e8e841a054b1e08bd555e1e32bddeef..3e547054411c03a3535a734d03332fa4d7113220 100644 (file)
@@ -2,10 +2,10 @@ MD5 3a0e5f78e38031ab57be3863a456d514 samba-3.0.7.ebuild 13924
 MD5 9b192ecc1db0a52318a676e8c03d4ac2 samba-3.0.7-r1.ebuild 15395
 MD5 cd9f3589a14d50054a0b1e4e129602af samba-3.0.6-r4.ebuild 14203
 MD5 fc36819e4e02fa146e936aa31947ad27 samba-3.0.6-r3.ebuild 14226
-MD5 a43f837ad8303a534ca76ea81bf66d53 samba-3.0.8.ebuild 16488
-MD5 62d9d0090688c993002a60808e680e07 ChangeLog 23934
+MD5 826ef7c1a083b2b7f564dc5198072698 samba-3.0.8.ebuild 16812
+MD5 b7f49631c4ca2eb9ea25b879bb522e74 ChangeLog 24101
 MD5 41299f246433a1a55c8fccc77ccd709e metadata.xml 491
-MD5 016874bb1d14c198e3bfde6cff28e4a4 samba-3.0.8-r1.ebuild 16511
+MD5 21a58d7b5372db46109fc8fa7e5bd269 samba-3.0.8-r1.ebuild 16863
 MD5 fcebd975211fecf647f6cecf26ba5c96 files/samba-3.0.4.patch 8086
 MD5 e89b19f1e62e257cbaa23a44a0362a58 files/swat.xinetd 527
 MD5 a7cc90ba23d86b1d90f65645826dde19 files/smbldap_conf.pm 7095
index d13d90b0ac374bd64e40a7980c6f1e6a68fb7ce9..c9d32a15142911176984f3f09ea18be67c29745f 100644 (file)
@@ -1,6 +1,6 @@
 # Copyright 1999-2004 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-fs/samba/samba-3.0.8-r1.ebuild,v 1.1 2004/11/15 10:12:30 satya Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-fs/samba/samba-3.0.8-r1.ebuild,v 1.2 2004/11/18 12:10:10 satya Exp $
 
 inherit eutils flag-o-matic
 #---------------------------------------------------------------------------
@@ -54,6 +54,7 @@ pkg_setup() {
        ewarn "    quotas:    now disabled by default"
        ewarn "    winbind:   now disabled by default"
        ewarn "    libclamav: (oav) don't use clamav daemon, just load libraries when needed"
+       ewarn "/etc/samba/private moved to /var/lib/samba/private"
        ebeep
        epause
 }
@@ -318,8 +319,9 @@ src_install() {
        fi
        # dirs -----------------------------------------------------------------
        diropts -m0700
-       dodir /var/lib/samba/private
-       touch ${D}/var/lib/samba/private/.keep
+       local PRIVATE_DST=/var/lib/samba/private
+       dodir ${PRIVATE_DST}
+       touch ${D}${PRIVATE_DST}/.keep
        diropts -m1777
        dodir /var/spool/samba
        touch ${D}/var/spool/samba/.keep
@@ -365,6 +367,13 @@ pkg_postinst() {
        # to mount smb shares don't get annoying warnings all the time..
        #[ ! -e ${ROOT}/etc/samba/smb.conf ] && touch ${ROOT}/etc/samba/smb.conf
 
+       local PRIVATE_DST=/var/lib/samba/private
+       local PRIVATE_SRC=/etc/samba/private
+       if [[ ! -r ${PRIVATE_DST}/secrets.tdb && -r ${PRIVATE_SRC}/secrets.tdb ]]; then
+               einfo "Copying ${PRIVATE_SRC}/* to ${PRIVATE_DST}/"
+               cp -af ${PRIVATE_SRC}/* ${D}${PRIVATE_DST}/
+       fi
+
        ewarn ""
        ewarn "If you are upgrading from a Samba version prior to 3.0.2, and you"
        ewarn "use Samba's password database, you must run the following command:"
index 571230c03c086668baafcfbd27e898e4f4a57cfd..308290173345744cd2bbb99df632e0f85966d8e4 100644 (file)
@@ -1,6 +1,6 @@
 # Copyright 1999-2004 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-fs/samba/samba-3.0.8.ebuild,v 1.10 2004/11/10 19:40:37 tester Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-fs/samba/samba-3.0.8.ebuild,v 1.11 2004/11/18 12:10:10 satya Exp $
 
 inherit eutils flag-o-matic
 #---------------------------------------------------------------------------
@@ -54,6 +54,7 @@ pkg_setup() {
        ewarn "    quotas:    now disabled by default"
        ewarn "    winbind:   now disabled by default"
        ewarn "    libclamav: (oav) don't use clamav daemon, just load libraries when needed"
+       ewarn "/etc/samba/private moved to /var/lib/samba/private"
        ebeep
        epause
 }
@@ -365,6 +366,12 @@ pkg_postinst() {
        # touch /etc/samba/smb.conf so that people installing samba just
        # to mount smb shares don't get annoying warnings all the time..
        #[ ! -e ${ROOT}/etc/samba/smb.conf ] && touch ${ROOT}/etc/samba/smb.conf
+       local PRIVATE_DST=/var/lib/samba/private
+       local PRIVATE_SRC=/etc/samba/private
+       if [[ ! -r ${PRIVATE_DST}/secrets.tdb && -r ${PRIVATE_SRC}/secrets.tdb ]]; then
+               einfo "Copying ${PRIVATE_SRC}/* to ${PRIVATE_DST}/"
+               cp -af ${PRIVATE_SRC}/* ${D}${PRIVATE_DST}/
+       fi
 
        ewarn ""
        ewarn "If you are upgrading from a Samba version prior to 3.0.2, and you"