[csw-devel] SF.net SVN: gar:[4049] csw/mgar/pkg/lftp/trunk

chninkel at users.sourceforge.net chninkel at users.sourceforge.net
Sun Mar 29 16:03:21 CEST 2009


Revision: 4049
          http://gar.svn.sourceforge.net/gar/?rev=4049&view=rev
Author:   chninkel
Date:     2009-03-29 14:03:20 +0000 (Sun, 29 Mar 2009)

Log Message:
-----------
lftp: now uses cswpreserveconf to handle configuration files

Modified Paths:
--------------
    csw/mgar/pkg/lftp/trunk/Makefile
    csw/mgar/pkg/lftp/trunk/checksums
    csw/mgar/pkg/lftp/trunk/files/CSWlftp.prototype

Removed Paths:
-------------
    csw/mgar/pkg/lftp/trunk/files/i.conf
    csw/mgar/pkg/lftp/trunk/files/r.conf

Modified: csw/mgar/pkg/lftp/trunk/Makefile
===================================================================
--- csw/mgar/pkg/lftp/trunk/Makefile	2009-03-29 13:52:08 UTC (rev 4048)
+++ csw/mgar/pkg/lftp/trunk/Makefile	2009-03-29 14:03:20 UTC (rev 4049)
@@ -26,8 +26,9 @@
 
 REQUIRED_PKGS = CSWexpat CSWggettextrt CSWiconv CSWosslrt CSWreadline 
 
-# adding the conf classe for handling configuration files
-SPKG_CLASSES = none conf
+# we're using conf handling class from the cswclassutils package
+REQUIRED_PKGS += CSWcswclassutils
+SPKG_CLASSES = none cswpreserveconf
 
 
 ###### Upstream and opencsw files information #######
@@ -40,7 +41,6 @@
 DISTFILES  = $(GARNAME)-$(GARVERSION).tar.gz
 DISTFILES += CSWlftp.prototype
 DISTFILES += changelog.CSW
-DISTFILES += i.conf r.conf
 
 
 ##### Build and installation information #####
@@ -59,8 +59,8 @@
 
 include gar/category.mk
 
-post-install-modulated:
-	ginstall -D $(DOWNLOADDIR)/changelog.CSW $(PKGROOT)/$(docdir)/lftp/changelog.CSW
-	ginstall $(DOWNLOADDIR)/*.conf $(WORKROOTDIR)/build-global/
+post-merge:
+	@ginstall -D $(PKGROOT)/$(sysconfdir)/lftp.conf $(PKGROOT)/$(sysconfdir)/lftp.conf.CSW
+	@ginstall -D $(DOWNLOADDIR)/changelog.CSW $(PKGROOT)/$(docdir)/lftp/changelog.CSW
 	@$(MAKECOOKIE)
 

Modified: csw/mgar/pkg/lftp/trunk/checksums
===================================================================
--- csw/mgar/pkg/lftp/trunk/checksums	2009-03-29 13:52:08 UTC (rev 4048)
+++ csw/mgar/pkg/lftp/trunk/checksums	2009-03-29 14:03:20 UTC (rev 4049)
@@ -1,5 +1,3 @@
 6fe8793f3ccde1d2f8446d599d8a69a9  download/lftp-3.7.11.tar.gz
-5e4827569eaa797b1e4e77d5bf9682df  download/CSWlftp.prototype
+5bc881a13c106b1c97f2137ff1755817  download/CSWlftp.prototype
 23a0c19689c59ae1b7716da30e39fead  download/changelog.CSW
-3a01fb949dfe799507720c311222cd96  download/i.conf
-51abe2144219c1af4c79c2e8b7e81cb9  download/r.conf

Modified: csw/mgar/pkg/lftp/trunk/files/CSWlftp.prototype
===================================================================
--- csw/mgar/pkg/lftp/trunk/files/CSWlftp.prototype	2009-03-29 13:52:08 UTC (rev 4048)
+++ csw/mgar/pkg/lftp/trunk/files/CSWlftp.prototype	2009-03-29 14:03:20 UTC (rev 4049)
@@ -1,8 +1,6 @@
-i i.conf=i.conf
-i r.conf=r.conf
 f none /opt/csw/bin/lftp 0755 root bin
 f none /opt/csw/bin/lftpget 0755 root bin
-e conf /opt/csw/etc/lftp.conf 0644 root bin
+f cswpreserveconf /opt/csw/etc/lftp.conf.CSW 0644 root bin
 d none /opt/csw/lib/lftp 0755 root bin
 d none /opt/csw/share/doc/lftp 0755 root bin
 f none /opt/csw/share/doc/lftp/changelog.CSW 0644 root bin

Deleted: csw/mgar/pkg/lftp/trunk/files/i.conf
===================================================================
--- csw/mgar/pkg/lftp/trunk/files/i.conf	2009-03-29 13:52:08 UTC (rev 4048)
+++ csw/mgar/pkg/lftp/trunk/files/i.conf	2009-03-29 14:03:20 UTC (rev 4049)
@@ -1,32 +0,0 @@
-# PKGINST parameter provided by installation service
-umask 0022
-
-while read src dest; do
-  if [ ! -f "$dest" ]; then
-      cp "$src" "$dest"
-  else
-      cp "$src" "$dest.CSW"
-  fi
-done
-
-# Unfortunately pkgadd doesn't backup the source file if the destination file is identical.
-# It's a problem with zones installation where pkgadd try to find the backup files, so
-# we do the backup manually
-awk '{ if ( $3 == "conf" ) print $2,$3,$4,$5,$6,$7  }' $INST_DATADIR/$PKG/pkgmap | \
-    while read FTYPE CLASS FPATH MODE OWNER GROUP; do
-        if echo $FPATH | grep "^/" >/dev/null; then
-            INST_PATH="$INST_DATADIR/$PKG/root/$FPATH"
-            SAVE_PATH="$PKGSAV/pspool/$PKG/root/$FPATH"
-        else
-            INST_PATH="$INST_DATADIR/$PKG/reloc/$FPATH"
-            SAVE_PATH="$PKGSAV/pspool/$PKG/reloc/$FPATH"
-        fi
-
-        if [ ! -f "$SAVE_PATH" ]; then
-            mkdir -p "`LANG=C dirname $SAVE_PATH`"
-            cp "$INST_PATH" "$SAVE_PATH"
-        fi
-     done
-
-exit 0
-

Deleted: csw/mgar/pkg/lftp/trunk/files/r.conf
===================================================================
--- csw/mgar/pkg/lftp/trunk/files/r.conf	2009-03-29 13:52:08 UTC (rev 4048)
+++ csw/mgar/pkg/lftp/trunk/files/r.conf	2009-03-29 14:03:20 UTC (rev 4049)
@@ -1,8 +0,0 @@
-# We don't delete config file, only backup ones installed
-# by the package.
-while read DEST; do
-    if [ -f "$DEST.CSW" ]; then
-        rm "$DEST.CSW"
-    fi
-done
-


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.



More information about the devel mailing list