- add myplc-devel subpackage
authorMark Huang <mlhuang@cs.princeton.edu>
Mon, 17 Jul 2006 21:45:42 +0000 (21:45 +0000)
committerMark Huang <mlhuang@cs.princeton.edu>
Mon, 17 Jul 2006 21:45:42 +0000 (21:45 +0000)
- Old versions of myplc used to ship with a bootstrapped database and
  /etc/planetlab directory. Including generated files in the manifest
  was dangerous; if /plc/data/var/lib/pgsql/data/base/1/16676 changed
  names from one RPM build to another, it would be rpmsaved and thus
  effectively deleted. Now we do not include these files in the
  manifest. However, to avoid deleting these files in the process of
  upgrading from one of these old versions of myplc, we must back up
  the database and /etc/planetlab and restore them after the old
  version has been uninstalled in %triggerpostun.
- add changelog

myplc.spec

index 29a8960..7a94a72 100644 (file)
@@ -39,8 +39,8 @@ source code, and all the tools necessary to compile it.
 
 %build
 pushd myplc
-#./build_devel.sh
-#./build.sh
+./build_devel.sh
+./build.sh
 popd
 
 %install
@@ -117,6 +117,7 @@ fi
 if [ $1 -gt 0 ] ; then
     for dir in /var/lib/pgsql/data /etc/planetlab ; do
        if [ -d /plc/data/$dir ] ; then
+           echo "Preserving /plc/data/$dir"
            mv /plc/data/$dir /plc/data/$dir.rpmsave
        fi
     done
@@ -142,6 +143,7 @@ touch /plc/data/etc/planetlab/default_config.xml
 if [ $1 -gt 0 ] ; then
     for dir in /var/lib/pgsql/data /etc/planetlab ; do
        if [ -d /plc/data/$dir.rpmsave -a -d /plc/data/$dir ] ; then
+           echo "Merging /plc/data/$dir"
            if tar -C /plc/data/$dir.rpmsave -cpf - . | \
               tar -C /plc/data/$dir -xpf - ; then
                rm -rf /plc/data/$dir.rpmsave