From 7606afaa5fa7d10d641b688f1fd35b05b5236cf2 Mon Sep 17 00:00:00 2001 From: Mark Huang Date: Mon, 17 Jul 2006 21:45:42 +0000 Subject: [PATCH] - add myplc-devel subpackage - 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 | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/myplc.spec b/myplc.spec index 29a8960..7a94a72 100644 --- a/myplc.spec +++ b/myplc.spec @@ -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 -- 2.47.0