[csw-devel] SF.net SVN: gar:[4287] csw/mgar/pkg/vsftpd/trunk

chninkel at users.sourceforge.net chninkel at users.sourceforge.net
Sun Apr 12 16:05:48 CEST 2009


Revision: 4287
          http://gar.svn.sourceforge.net/gar/?rev=4287&view=rev
Author:   chninkel
Date:     2009-04-12 14:05:48 +0000 (Sun, 12 Apr 2009)

Log Message:
-----------
vsftpd: switched to cswclassutils cswusergroup

Modified Paths:
--------------
    csw/mgar/pkg/vsftpd/trunk/Makefile
    csw/mgar/pkg/vsftpd/trunk/checksums
    csw/mgar/pkg/vsftpd/trunk/files/CSWvsftpd.prototype
    csw/mgar/pkg/vsftpd/trunk/files/vsftpd_dyngspec.fakespec

Added Paths:
-----------
    csw/mgar/pkg/vsftpd/trunk/files/cswusergroup

Removed Paths:
-------------
    csw/mgar/pkg/vsftpd/trunk/files/CSWvsftpd.csw_usrgrp_config
    csw/mgar/pkg/vsftpd/trunk/files/csw_usrgrp.gspec
    csw/mgar/pkg/vsftpd/trunk/files/csw_usrgrp.preinstall

Modified: csw/mgar/pkg/vsftpd/trunk/Makefile
===================================================================
--- csw/mgar/pkg/vsftpd/trunk/Makefile	2009-04-12 13:46:36 UTC (rev 4286)
+++ csw/mgar/pkg/vsftpd/trunk/Makefile	2009-04-12 14:05:48 UTC (rev 4287)
@@ -35,7 +35,7 @@
 
 # adding configuration handling classes
 # (init/smf classes are dynamically added in checkinstall)
-SPKG_CLASSES = none cswpreserveconf
+SPKG_CLASSES = none cswpreserveconf cswusergroup
 
 
 ###### Upstream and opencsw files information #######
@@ -44,10 +44,11 @@
 UFILES_REGEX = $(GARNAME)-(\d+(?:\.\d+)*).tar.gz
 
 DISTFILES  = $(GARNAME)-$(GARVERSION).tar.gz
-DISTFILES += CSWvsftpd.prototype CSWvsftpd.preinstall CSWvsftpd.csw_usrgrp_config
+DISTFILES += CSWvsftpd.prototype CSWvsftpd.preinstall
 DISTFILES += changelog.CSW README.CSW
 DISTFILES += vsftpd.conf vsftpd.userlist
 DISTFILES += cswvsftpd cswvsftpd.xml svc-cswvsftpd 
+DISTFILES += cswusergroup
 
 # build options are set by modifying 
 # builddefs.h, so we patch it to enable
@@ -119,11 +120,12 @@
 	 ginstall -d $(DESTDIR)$(docdir)/vsftpd )
 
 
-post-merge: merge-doc-files merge-config-files merge-class-files
+post-merge: merge-doc-files merge-config-files 
 
 merge-config-files:
 	ginstall -D "$(WORKDIR_FIRSTMOD)/vsftpd.conf" "$(PKGROOT)$(sysconfdir)/vsftpd/vsftpd.conf.CSW"
 	ginstall -D "$(WORKDIR_FIRSTMOD)/vsftpd.userlist" "$(PKGROOT)$(sysconfdir)/vsftpd/vsftpd.userlist.CSW"
+	ginstall -D "$(WORKDIR_FIRSTMOD)/cswusergroup" "$(PKGROOT)$(sysconfdir)/pkg/CSWvsftpd/cswusergroup"
 
 merge-doc-files:
 	for FILE in $(DOCFILES); do \
@@ -131,6 +133,3 @@
 	done
 	ginstall -D "$(WORKDIR_FIRSTMOD)/changelog.CSW" "$(PKGROOT)$(docdir)/vsftpd/changelog.CSW"
 	ginstall -D "$(WORKDIR_FIRSTMOD)/README.CSW" "$(PKGROOT)$(docdir)/vsftpd/README.CSW"
-
-merge-class-files:
-	ginstall "$(DOWNLOADDIR)/"*.conf $(WORKDIR)/

Modified: csw/mgar/pkg/vsftpd/trunk/checksums
===================================================================
--- csw/mgar/pkg/vsftpd/trunk/checksums	2009-04-12 13:46:36 UTC (rev 4286)
+++ csw/mgar/pkg/vsftpd/trunk/checksums	2009-04-12 14:05:48 UTC (rev 4287)
@@ -1,11 +1,11 @@
-314e73654490c2abe742b7ed7be798b1  download/CSWvsftpd.csw_usrgrp_config
 a2f5b70fe49839b0463c9d90af0f11dd  download/CSWvsftpd.preinstall
-3445fbf0fc7e28cc7f2db827dfbaddb0  download/CSWvsftpd.prototype
+accf66084b40cc8ea89037f1cc351833  download/CSWvsftpd.prototype
 eeaf77528b2da0c7730323838f30b7ef  download/README.CSW
 281c51282cabd9475cceef363bbc699b  download/build_options.patch
 68178673c7d33baead2d7b97e878ed79  download/changelog.CSW
 54c1c39c6bfa8747a4457f135fd5bca1  download/csw_build_system.patch
 a9e994d2b57999b76a0e03503745c01a  download/csw_paths.patch
+98e1d831801985daf5ce2ed01fbc0efd  download/cswusergroup
 8a11892757760e07534a4a455f051e84  download/cswvsftpd
 5d093652c802b21dd00a52b2d012d977  download/cswvsftpd.xml
 73e59f9ada47d3d20199f7c97849fb13  download/destdir.patch
@@ -14,4 +14,4 @@
 7890b54e7ffa6106ffbdfda53f47fa41  download/vsftpd-2.1.0.tar.gz
 f6ce22a6959b93e500a4ae800295c2ee  download/vsftpd.conf
 60c736802e2ce00c531953b01e4a26f6  download/vsftpd.userlist
-0b0357e8470ccea567eabe6103daa769  download/vsftpd_dyngspec.fakespec
+372d9e524d45e1b62578ef3361c8524c  download/vsftpd_dyngspec.fakespec

Deleted: csw/mgar/pkg/vsftpd/trunk/files/CSWvsftpd.csw_usrgrp_config
===================================================================
--- csw/mgar/pkg/vsftpd/trunk/files/CSWvsftpd.csw_usrgrp_config	2009-04-12 13:46:36 UTC (rev 4286)
+++ csw/mgar/pkg/vsftpd/trunk/files/CSWvsftpd.csw_usrgrp_config	2009-04-12 14:05:48 UTC (rev 4287)
@@ -1,4 +0,0 @@
-version=1
-group=vsftpd
-user=vsftpd:vsftpd:/opt/csw/var/empty/vsftpd:/bin/false:vsftpd privsep user
-user=ftp:nogroup:/opt/csw/var/ftp:/bin/false:ftp user for anonymous access

Modified: csw/mgar/pkg/vsftpd/trunk/files/CSWvsftpd.prototype
===================================================================
--- csw/mgar/pkg/vsftpd/trunk/files/CSWvsftpd.prototype	2009-04-12 13:46:36 UTC (rev 4286)
+++ csw/mgar/pkg/vsftpd/trunk/files/CSWvsftpd.prototype	2009-04-12 14:05:48 UTC (rev 4287)
@@ -1,6 +1,7 @@
 d none /opt/csw/etc/vsftpd 0755 root bin
-f none /opt/csw/etc/vsftpd/vsftpd.conf.CSW 0755 root bin
-f cswpreserveconf /opt/csw/etc/vsftpd/vsftpd.userlist.CSW 0755 root bin
+f none /opt/csw/etc/vsftpd/vsftpd.conf.CSW 0644 root bin
+f cswpreserveconf /opt/csw/etc/vsftpd/vsftpd.userlist.CSW 0644 root bin
+f cswusergroup /opt/csw/etc/pkg/CSWvsftpd/cswusergroup 0644 root bin
 f none /opt/csw/sbin/vsftpd 0755 root bin
 d none /opt/csw/share/doc/vsftpd 0755 root bin
 d none /opt/csw/share/doc/vsftpd/EXAMPLE 0755 root bin

Deleted: csw/mgar/pkg/vsftpd/trunk/files/csw_usrgrp.gspec
===================================================================
--- csw/mgar/pkg/vsftpd/trunk/files/csw_usrgrp.gspec	2009-04-12 13:46:36 UTC (rev 4286)
+++ csw/mgar/pkg/vsftpd/trunk/files/csw_usrgrp.gspec	2009-04-12 14:05:48 UTC (rev 4287)
@@ -1,3 +0,0 @@
-%prototype:merge
-i csw_usrgrp_config=CSW%{bitname}.csw_usrgrp_config
-%preinstall:merge       url file://files/csw_usrgrp.preinstall

Deleted: csw/mgar/pkg/vsftpd/trunk/files/csw_usrgrp.preinstall
===================================================================
--- csw/mgar/pkg/vsftpd/trunk/files/csw_usrgrp.preinstall	2009-04-12 13:46:36 UTC (rev 4286)
+++ csw/mgar/pkg/vsftpd/trunk/files/csw_usrgrp.preinstall	2009-04-12 14:05:48 UTC (rev 4287)
@@ -1,79 +0,0 @@
-################################################################################
-# Start csw_usrgrp.postinstall
-################################################################################
-
-# This was once based upon the preinstallation script from vsftpd
-
-set -e
-
-##################################################
-# create the given group if it doesn't exist
-##################################################
-create_group()
-{
-    NAME=$1
-
-    if /usr/sbin/chroot "$PKG_INSTALL_ROOT" /usr/bin/getent group $NAME > /dev/null; then 
-        /usr/bin/echo "Group already exist: $NAME"
-    else 
-        /usr/sbin/chroot "$PKG_INSTALL_ROOT" /usr/sbin/groupadd $NAME
-        /usr/bin/echo "Group created: $NAME"
-    fi
-}
-
-##################################################
-# create the given user if it doesn't exist
-# paramters are: userid gid home shell gecos
-##################################################
-create_user()
-{
-    NAME=$1
-    GROUP=$2
-    HOME=$3
-    SHELL=$4
-    COMMENT="$5"
-
-    if /usr/sbin/chroot "$PKG_INSTALL_ROOT" /usr/bin/getent passwd $NAME > /dev/null; then 
-        /usr/bin/echo "User already exists: $NAME"
-    else 
-        /usr/sbin/chroot "$PKG_INSTALL_ROOT" /usr/sbin/useradd -g "$GROUP" -c "$COMMENT" -d $HOME -s $SHELL $NAME
-        /usr/sbin/chroot "$PKG_INSTALL_ROOT" /usr/bin/pwconv
-        /usr/bin/echo "User created: $NAME"
-    fi
-}
-
-PKG_INSTALL_ROOT=${PKG_INSTALL_ROOT:-/}
-
-CSW_USRGRP_CONFIG="$PKGSAV/../install/csw_usrgrp_config"
-
-# Note to self: do not replace this with a "return" as additional scripts can be merged after this script
-if [ -r "$CSW_USRGRP_CONFIG" ]
-then
-    # Read the csw_usrgrp_config file and make sure that it has the correct version
-    set +e
-    version=`grep "^version=" "$CSW_USRGRP_CONFIG"`
-    set -e
-
-    if [ "$version" != "version=1" ]
-    then
-      echo "ERROR: invalid csw_usrgrp_config file. Expected version=1" 
-      exit 1
-    fi
-
-    OIFS="$IFS"; 
-    IFS=":"
-    sed -n "s/^group=//p" "$CSW_USRGRP_CONFIG" | while read NAME
-    do
-      create_group "$NAME"
-    done
-  
-    sed -n "s/^user=//p" "$CSW_USRGRP_CONFIG" | while read NAME GROUP HOME SHELL COMMENT
-    do
-      create_user "$NAME" "$GROUP" "$HOME" "$SHELL" "$COMMENT"
-    done
-    IFS="$OIFS"
-fi
-
-################################################################################
-# End csw_usrgrp.postinstall
-################################################################################

Added: csw/mgar/pkg/vsftpd/trunk/files/cswusergroup
===================================================================
--- csw/mgar/pkg/vsftpd/trunk/files/cswusergroup	                        (rev 0)
+++ csw/mgar/pkg/vsftpd/trunk/files/cswusergroup	2009-04-12 14:05:48 UTC (rev 4287)
@@ -0,0 +1,2 @@
+vsftpd:vsftpd:vsftpd privsep user:/opt/csw/var/empty/vsftpd:/bin/false::
+ftp:nogroup:ftp user for anonymous access:/opt/csw/var/ftp:/bin/false::

Modified: csw/mgar/pkg/vsftpd/trunk/files/vsftpd_dyngspec.fakespec
===================================================================
--- csw/mgar/pkg/vsftpd/trunk/files/vsftpd_dyngspec.fakespec	2009-04-12 13:46:36 UTC (rev 4286)
+++ csw/mgar/pkg/vsftpd/trunk/files/vsftpd_dyngspec.fakespec	2009-04-12 14:05:48 UTC (rev 4287)
@@ -1,4 +1,3 @@
 %include        url file://%{PKGLIB}/csw_dyngspec.gspec
 %var		SERVICE_CONF_FILES /opt/csw/etc/vsftpd/vsftpd.conf
 %include        url file://%{PKGLIB}/smf_enabled.gspec
-%include  	url file://files/csw_usrgrp.gspec


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