rpms/zfs-fuse/EL-6 zfs-fuse.spec,1.24,1.25

Uwe Kubosch donv at fedoraproject.org
Sun Jul 4 14:39:25 UTC 2010


Author: donv

Update of /cvs/pkgs/rpms/zfs-fuse/EL-6
In directory cvs01.phx2.fedoraproject.org:/tmp/cvs-serv17353

Modified Files:
	zfs-fuse.spec 
Log Message:
* Patched SConstruct to define NDEBUG instead of DEBUG to avoid debug code while still generating debug symbols


Index: zfs-fuse.spec
===================================================================
RCS file: /cvs/pkgs/rpms/zfs-fuse/EL-6/zfs-fuse.spec,v
retrieving revision 1.24
retrieving revision 1.25
diff -u -p -r1.24 -r1.25
--- zfs-fuse.spec	4 Jul 2010 00:40:20 -0000	1.24
+++ zfs-fuse.spec	4 Jul 2010 14:39:24 -0000	1.25
@@ -1,6 +1,6 @@
 Name:             zfs-fuse
 Version:          0.6.9
-Release:          2%{?dist}
+Release:          4%{?dist}
 Summary:          ZFS ported to Linux FUSE
 Group:            System Environment/Base
 License:          CDDL
@@ -45,7 +45,10 @@ iconv -o $f -f iso88591 -t utf8 $f.iso88
 export CCFLAGS="%{optflags}"
 pushd src
 %{__sed} -i -e 's/-pipe -Wall/%{optflags}/' SConstruct
+
+# FIXME(uwe):  This patch should not be necessary.  Report as bug.
 %{__sed} -i -e "s/'debug', '0'/'debug', '1'/" SConstruct
+%{__sed} -i -e "s/env.Append(CCFLAGS = Split('-O2 -DDEBUG'))/env.Append(CCFLAGS = \['-DNDEBUG'\])/" SConstruct
 
 pushd lib/libzfs
 %{__sed} -i -e 's/cpppath.$/cpppath, LIBS = \["crypto"\])/' SConscript
@@ -80,6 +83,21 @@ scons install install_dir=%{buildroot}%{
 %post
 if [ $1 = 1 ] ; then
     /sbin/chkconfig --add %{name}
+    /sbin/service %{name} start >/dev/null 2>&1 || :
+fi
+
+# Move cache if upgrading
+oldcache=/etc/zfs/zpool.cache      # this changed per 0.6.9, only needed when upgrading from earlier versions
+newcache=/var/lib/zfs/zpool.cache
+
+if [[ -f $oldcache && ! -e $newcache ]]; then
+  echo "Moving existing zpool.cache to new location"
+  mkdir -p $(dirname $newcache)
+  mv $oldcache $newcache
+else
+  if [ -e $oldcache ]; then
+    echo "Note: old zpool.cache present but no longer used ($oldcache)"
+  fi
 fi
 
 %preun
@@ -115,6 +133,10 @@ fi
 %{_mandir}/man8/zstreamdump.8.gz
 
 %changelog
+* Sun Jul 04 2010 Uwe Kubosch <uwe at kubosch.no> - 0.6.9-4
+- Patched SConstruct to define NDEBUG instead of DEBUG to avoid debug code while still generating debug symbols
+- Added moving of zfs.cache when updating from pre 0.6.9 version
+
 * Sat Jul 03 2010 Uwe Kubosch <uwe at kubosch.no> - 0.6.9-2
 - Updated to upstream stable release 0.6.9
 - Patched default debug level from 0 to 1



More information about the scm-commits mailing list