[Pkg-samba-maint] r3579 - in trunk/samba/debian: . patches

vorlon at alioth.debian.org vorlon at alioth.debian.org
Tue Sep 7 07:47:42 UTC 2010


Author: vorlon
Date: 2010-09-07 07:47:39 +0000 (Tue, 07 Sep 2010)
New Revision: 3579

Modified:
   trunk/samba/debian/changelog
   trunk/samba/debian/patches/fhs-filespaths.patch
   trunk/samba/debian/samba.postinst
   trunk/samba/debian/winbind.postinst
Log:
debian/patches/fhs-filespaths.patch, debian/samba.postinst,
debian/winbind.postinst: move some files from /etc/samba to
/var/lib/samba where they belong: MACHINE.SID, schannel_store.tdb,
and idmap2.tdb.

Modified: trunk/samba/debian/changelog
===================================================================
--- trunk/samba/debian/changelog	2010-09-07 07:27:40 UTC (rev 3578)
+++ trunk/samba/debian/changelog	2010-09-07 07:47:39 UTC (rev 3579)
@@ -6,6 +6,12 @@
   * Danish (Joe Dalton).  Closes: #592789.
   * Galician (Jorge Barreiro).  Closes: #592809
 
+  [ Steve Langasek ]
+  * debian/patches/fhs-filespaths.patch, debian/samba.postinst,
+    debian/winbind.postinst: move some files from /etc/samba to
+    /var/lib/samba where they belong: MACHINE.SID, schannel_store.tdb,
+    and idmap2.tdb.
+
  -- Christian Perrier <bubulle at debian.org>  Mon, 06 Sep 2010 22:41:12 +0200
 
 samba (2:3.5.4~dfsg-1) experimental; urgency=low

Modified: trunk/samba/debian/patches/fhs-filespaths.patch
===================================================================
--- trunk/samba/debian/patches/fhs-filespaths.patch	2010-09-07 07:27:40 UTC (rev 3578)
+++ trunk/samba/debian/patches/fhs-filespaths.patch	2010-09-07 07:47:39 UTC (rev 3579)
@@ -13,10 +13,10 @@
 Forwarded: not-needed
 
 
-Index: experimental/source3/passdb/pdb_tdb.c
+Index: b/source3/passdb/pdb_tdb.c
 ===================================================================
---- experimental.orig/source3/passdb/pdb_tdb.c
-+++ experimental/source3/passdb/pdb_tdb.c
+--- a/source3/passdb/pdb_tdb.c
++++ b/source3/passdb/pdb_tdb.c
 @@ -1255,7 +1255,7 @@
  	/* save the path for later */
  
@@ -26,10 +26,10 @@
  			     PASSDB_FILE_NAME) < 0) {
  			return NT_STATUS_NO_MEMORY;
  		}
-Index: experimental/source3/passdb/secrets.c
+Index: b/source3/passdb/secrets.c
 ===================================================================
---- experimental.orig/source3/passdb/secrets.c
-+++ experimental/source3/passdb/secrets.c
+--- a/source3/passdb/secrets.c
++++ b/source3/passdb/secrets.c
 @@ -61,7 +61,7 @@
  		return True;
  
@@ -39,3 +39,42 @@
  	if (fname == NULL) {
  		return false;
  	}
+Index: b/source3/passdb/machine_sid.c
+===================================================================
+--- a/source3/passdb/machine_sid.c
++++ b/source3/passdb/machine_sid.c
+@@ -128,7 +128,7 @@
+ 	}
+ 
+ 	/* check for an old MACHINE.SID file for backwards compatibility */
+-	if (asprintf(&fname, "%s/MACHINE.SID", lp_private_dir()) == -1) {
++	if (asprintf(&fname, "%s/MACHINE.SID", get_dyn_STATEDIR()) == -1) {
+ 		SAFE_FREE(sam_sid);
+ 		return NULL;
+ 	}
+Index: b/source3/passdb/secrets_schannel.c
+===================================================================
+--- a/source3/passdb/secrets_schannel.c
++++ b/source3/passdb/secrets_schannel.c
+@@ -33,7 +33,7 @@
+ 	TDB_DATA vers;
+ 	uint32 ver;
+ 	TDB_CONTEXT *tdb_sc = NULL;
+-	char *fname = talloc_asprintf(mem_ctx, "%s/schannel_store.tdb", lp_private_dir());
++	char *fname = talloc_asprintf(mem_ctx, "%s/schannel_store.tdb", get_dyn_STATEDIR());
+ 
+ 	if (!fname) {
+ 		return NULL;
+Index: b/source3/winbindd/idmap_tdb2.c
+===================================================================
+--- a/source3/winbindd/idmap_tdb2.c
++++ b/source3/winbindd/idmap_tdb2.c
+@@ -107,7 +107,7 @@
+ 	if (db_path == NULL) {
+ 		/* fall back to the private directory, which, despite
+ 		   its name, is usually on shared storage */
+-		db_path = talloc_asprintf(NULL, "%s/idmap2.tdb", lp_private_dir());
++		db_path = talloc_asprintf(NULL, "%s/idmap2.tdb", dyn_get_STATEDIR());
+ 	}
+ 	NT_STATUS_HAVE_NO_MEMORY(db_path);
+ 

Modified: trunk/samba/debian/samba.postinst
===================================================================
--- trunk/samba/debian/samba.postinst	2010-09-07 07:27:40 UTC (rev 3578)
+++ trunk/samba/debian/samba.postinst	2010-09-07 07:47:39 UTC (rev 3579)
@@ -93,8 +93,8 @@
 	mv /var/run/samba/share_info.tdb /var/lib/samba/share_info.tdb
 fi
 
-if dpkg --compare-versions "$2" lt-nl 2:3.2.0-3 \
-   && dpkg --compare-versions "$2" ge 3.0.24 \
+if dpkg --compare-versions "$2" lt-nl 2:3.5.4~dfsg-2 \
+   && dpkg --compare-versions "$2" ge 2:3.5.0~rc1~dfsg-1 \
    && [ -e /etc/samba/schannel_store.tdb ] \
    && ! [ -e /var/lib/samba/schannel_store.tdb ]
 then

Modified: trunk/samba/debian/winbind.postinst
===================================================================
--- trunk/samba/debian/winbind.postinst	2010-09-07 07:27:40 UTC (rev 3578)
+++ trunk/samba/debian/winbind.postinst	2010-09-07 07:47:39 UTC (rev 3579)
@@ -13,6 +13,13 @@
         mv /var/run/samba/idmap_cache.tdb /var/cache/samba/idmap_cache.tdb
 fi
 
+if dpkg --compare-versions "$2" lt-nl 2:3.5.4~dfsg-2 \
+   && [ -e /etc/samba/idmap2.tdb ] \
+   && ! [ -e /var/lib/samba/idmap2.tdb ]
+then
+	mv /etc/samba/idmap2.tdb /var/lib/samba/idmap2.tdb
+fi
+
 pam-auth-update --package
 
 #DEBHELPER#





More information about the Pkg-samba-maint mailing list