[csw-devel] SF.net SVN: gar:[11585] csw/mgar/pkg/apache2/trunk/files/conf_build_scripts
bdwalton at users.sourceforge.net
bdwalton at users.sourceforge.net
Fri Nov 12 03:27:54 CET 2010
Revision: 11585
http://gar.svn.sourceforge.net/gar/?rev=11585&view=rev
Author: bdwalton
Date: 2010-11-12 02:27:54 +0000 (Fri, 12 Nov 2010)
Log Message:
-----------
apache2: tweak the conf building script to make build CAS use easier
Modified Paths:
--------------
csw/mgar/pkg/apache2/trunk/files/conf_build_scripts
Modified: csw/mgar/pkg/apache2/trunk/files/conf_build_scripts
===================================================================
--- csw/mgar/pkg/apache2/trunk/files/conf_build_scripts 2010-11-11 19:51:19 UTC (rev 11584)
+++ csw/mgar/pkg/apache2/trunk/files/conf_build_scripts 2010-11-12 02:27:54 UTC (rev 11585)
@@ -9,24 +9,26 @@
for f in $(find . -type f | grep -v original/ ); do
echo "...processing $f"
+ template=$f.CSW
- cat <<EOF > $f.new
+ cat <<EOF > $template
PIR=\${PKG_INSTALL_ROOT:-/}
AP2_ROOT=\$PIR/$AP2_ROOT
AP2_CONF=\$AP2_ROOT/etc
+TEMPLATE=\$AP2_CONF/$template
if [ "\$1" = install ]; then
- cat <<EOS > \$AP2_CONF/$f.CSW
+ cat <<EOS > \$TEMPLATE
EOF
perl -pi -e 's/\$/\\\$/g' $f
-cat $f >> $f.new
+cat $f >> $template
-cat <<EOF >> $f.new
+cat <<EOF >> $template
EOS
if [ ! -f \$AP2_CONF/$f ]; then
- cp -p \$AP2_CONF/$f.CSW \$AP2_CONF/$f
+ cp -p \$TEMPLATE \$AP2_CONF/$f
fi
else
@@ -35,5 +37,5 @@
EOF
-mv $f.new $f
+rm $f
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