rpms/vdr/devel vdr-1.6.0-fedora-pkgconfig.patch, 1.2, 1.3 vdr-README.package, 1.7, 1.8 vdr-commands.conf, 1.2, 1.3 vdr-halt.local.sh, 1.4, 1.5 vdr-moveto.sh, 1.1, 1.2 vdr-shutdown.sh, 1.5, 1.6 vdr.spec, 1.34, 1.35

Ville Skyttä scop at fedoraproject.org
Sun Nov 23 22:02:47 UTC 2008


Author: scop

Update of /cvs/pkgs/rpms/vdr/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv32358

Modified Files:
	vdr-1.6.0-fedora-pkgconfig.patch vdr-README.package 
	vdr-commands.conf vdr-halt.local.sh vdr-moveto.sh 
	vdr-shutdown.sh vdr.spec 
Log Message:
* Sun Nov 23 2008 Ville Skyttä <ville.skytta at iki.fi> - 1.6.0-15
- Reorganize dir structure for better Fedora guidelines compliance (#443706):
  /var/lib/vdr/* -> /var/lib/vdr/data, /srv/video -> /var/lib/vdr/video.
- Drop audiodir and ownership of /srv/audio, examples still point to it.


vdr-1.6.0-fedora-pkgconfig.patch:

Index: vdr-1.6.0-fedora-pkgconfig.patch
===================================================================
RCS file: /cvs/pkgs/rpms/vdr/devel/vdr-1.6.0-fedora-pkgconfig.patch,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- vdr-1.6.0-fedora-pkgconfig.patch	7 Apr 2008 19:31:02 -0000	1.2
+++ vdr-1.6.0-fedora-pkgconfig.patch	23 Nov 2008 22:02:17 -0000	1.3
@@ -1,10 +1,9 @@
---- Makefile~	2008-04-04 20:28:08.000000000 +0300
-+++ Makefile	2008-04-04 20:32:48.000000000 +0300
-@@ -115,6 +115,15 @@
+--- Makefile~	2008-09-15 19:05:56.000000000 +0300
++++ Makefile	2008-09-15 19:06:26.000000000 +0300
+@@ -115,6 +115,14 @@
  	echo "localedir=$(LOCDIR)" >> $@
  	echo "apiversion=$(APIVERSION)" >> $@
  	echo "" >> $@
-+	echo "audiodir=$(AUDIODIR)" >> $@
 +	echo "datadir=$(DATADIR)" >> $@
 +	echo "cachedir=$(CACHEDIR)" >> $@
 +	echo "rundir=$(RUNDIR)" >> $@


Index: vdr-README.package
===================================================================
RCS file: /cvs/pkgs/rpms/vdr/devel/vdr-README.package,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -r1.7 -r1.8
--- vdr-README.package	25 Sep 2008 20:28:00 -0000	1.7
+++ vdr-README.package	23 Nov 2008 22:02:17 -0000	1.8
@@ -69,10 +69,10 @@
 /usr/lib*/vdr/bin directory and enabled in the default vdr command
 line built by the init script.  The script writes a time some time
 before the next configured timer (given by VDR, see the file INSTALL)
-as a number of seconds to /var/lib/vdr/next-wakeup, and shuts down the
-machine.  See commentary in the script for how to enable it and how to
-grant the required permissions to the vdr user so it can carry out
-these tasks.
+as a number of seconds to /var/lib/vdr/data/next-wakeup, and shuts
+down the machine.  See commentary in the script for how to enable it
+and how to grant the required permissions to the vdr user so it can
+carry out these tasks.
 
 To use the ACPI alarm feature present in many recent systems, adding a
 script like the supplied vdr-halt.local.sh (see same directory as this


Index: vdr-commands.conf
===================================================================
RCS file: /cvs/pkgs/rpms/vdr/devel/vdr-commands.conf,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- vdr-commands.conf	28 Jan 2007 11:11:18 -0000	1.2
+++ vdr-commands.conf	23 Nov 2008 22:02:17 -0000	1.3
@@ -1,8 +1,9 @@
 # Main menu commands for VDR.  See the vdr(5) manual page.
 
-# To rip audio CD's with abcde, uncomment this.  See /etc/abcde.conf (or the
-# -o option) for output format and other settings, and try
-# "env CDDA_TRANSPORT=cooked abcde -Np" instead of just "abcde -Np" in case
-# you experience problems, see https://bugzilla.redhat.com/166141
+# To rip audio CD's with abcde, uncomment this, and adjust the output directory
+# if needed (remember to make it writable by the vdr user).
+# See /etc/abcde.conf (or the -o option) for output format and other settings,
+# and try "env CDDA_TRANSPORT=cooked abcde -Np" instead of just "abcde -Np" in
+# case you experience problems, see https://bugzilla.redhat.com/166141
 #
 #Rip audio CD?: cd /srv/audio ; abcde -Np


Index: vdr-halt.local.sh
===================================================================
RCS file: /cvs/pkgs/rpms/vdr/devel/vdr-halt.local.sh,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- vdr-halt.local.sh	22 Nov 2008 20:37:26 -0000	1.4
+++ vdr-halt.local.sh	23 Nov 2008 22:02:17 -0000	1.5
@@ -9,7 +9,7 @@
 # #!/bin/sh
 # /usr/lib/vdr/bin/vdr-halt.local.sh
 
-wakeupfile=/var/lib/vdr/next-wakeup
+wakeupfile=/var/lib/vdr/data/next-wakeup
 rtcdir=/sys/class/rtc/rtc0
 procalarm=/proc/acpi/alarm
 


Index: vdr-moveto.sh
===================================================================
RCS file: /cvs/pkgs/rpms/vdr/devel/vdr-moveto.sh,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- vdr-moveto.sh	1 Aug 2007 20:49:04 -0000	1.1
+++ vdr-moveto.sh	23 Nov 2008 22:02:17 -0000	1.2
@@ -9,7 +9,7 @@
 # Move to movies: vdr-moveto.sh 00_Movies
 # Move to music: vdr-moveto.sh 00_Music
 
-videodir="/srv/vdr"
+videodir="/var/lib/vdr/video"
 
 to="$videodir/$1"
 what="$2"


Index: vdr-shutdown.sh
===================================================================
RCS file: /cvs/pkgs/rpms/vdr/devel/vdr-shutdown.sh,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -r1.5 -r1.6
--- vdr-shutdown.sh	7 Sep 2008 15:18:36 -0000	1.5
+++ vdr-shutdown.sh	23 Nov 2008 22:02:17 -0000	1.6
@@ -13,7 +13,7 @@
 
 mins=${WAKEUP_BEFORE_RECORDING:-10}
 
-wakeupfile=/var/lib/vdr/next-wakeup
+wakeupfile=/var/lib/vdr/data/next-wakeup
 rm -f $wakeupfile
 
 if [ ${1:-0} -gt 0 ] ; then


Index: vdr.spec
===================================================================
RCS file: /cvs/pkgs/rpms/vdr/devel/vdr.spec,v
retrieving revision 1.34
retrieving revision 1.35
diff -u -r1.34 -r1.35
--- vdr.spec	22 Nov 2008 20:37:26 -0000	1.34
+++ vdr.spec	23 Nov 2008 22:02:17 -0000	1.35
@@ -6,14 +6,14 @@
 %bcond_with       docs
 %bcond_with       plugins
 
-%define videodir  /srv/vdr
-%define audiodir  /srv/audio
+%define varbase   %{_var}/lib/vdr
+%define videodir  %{varbase}/video
+%define vardir    %{varbase}/data
 %define plugindir %{_libdir}/vdr
 %define configdir %{_sysconfdir}/vdr
 %define datadir   %{_datadir}/vdr
 %define cachedir  %{_var}/cache/vdr
 %define rundir    %{_var}/run/vdr
-%define vardir    %{_var}/lib/vdr
 %define vdr_user  vdr
 %define vdr_group video
 # From APIVERSION in config.h
@@ -21,7 +21,7 @@
 
 Name:           vdr
 Version:        1.6.0
-Release:        8%{?dist}
+Release:        15%{?dist}
 Summary:        Video Disk Recorder
 
 Group:          Applications/Multimedia
@@ -195,7 +195,7 @@
 
 cp -p %{SOURCE5} reccmds.conf
 cp -p %{SOURCE13} timercmds.conf
-sed -e 's|/srv/audio|%{audiodir}|' %{SOURCE6} > commands.conf
+cp -p %{SOURCE6} commands.conf
 # Unfortunately these can't have comments in them, so ship 'em empty.
 cat /dev/null > channels.conf
 cat /dev/null > remote.conf
@@ -254,7 +254,7 @@
 make %{?_smp_mflags} vdr vdr.pc include-dir \
     BINDIR=%{_sbindir} INCLUDEDIR=%{_includedir} CONFDIR=%{configdir} \
     VIDEODIR=%{videodir} PLUGINLIBDIR=%{plugindir} LOCDIR=%{_datadir}/locale \
-    AUDIODIR=%{audiodir} DATADIR=%{datadir} CACHEDIR=%{cachedir} \
+    DATADIR=%{datadir} CACHEDIR=%{cachedir} \
     RUNDIR=%{rundir} VARDIR=%{vardir} VDR_GROUP=%{vdr_group}
 
 make %{?_smp_mflags} i18n LOCALEDIR=./locale
@@ -315,19 +315,18 @@
 chmod 644 $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/vdr
 
 install -dm 755 $RPM_BUILD_ROOT%{videodir}
-install -dm 755 $RPM_BUILD_ROOT%{audiodir}
 
 touch $RPM_BUILD_ROOT%{videodir}/.update
 
 install -dm 755 $RPM_BUILD_ROOT%{plugindir}/bin
-sed -e 's|/var/lib/vdr/|%{vardir}/|' < %{SOURCE14} \
+sed -e 's|/var/lib/vdr/data/|%{vardir}/|' < %{SOURCE14} \
   > $RPM_BUILD_ROOT%{plugindir}/bin/%{name}-shutdown.sh
 chmod 755 $RPM_BUILD_ROOT%{plugindir}/bin/%{name}-shutdown.sh
-sed -e 's|/var/lib/vdr/|%{vardir}/|' \
+sed -e 's|/var/lib/vdr/data/|%{vardir}/|' \
     -e 's|/usr/lib/vdr/bin/|%{plugindir}/bin/|' < %{SOURCE17} \
   > $RPM_BUILD_ROOT%{plugindir}/bin/%{name}-halt.local.sh
 chmod 755 $RPM_BUILD_ROOT%{plugindir}/bin/%{name}-halt.local.sh
-sed -e 's|/srv/vdr|%{videodir}|' -e 's|/etc/vdr/|%{configdir}/|' \
+sed -e 's|/var/lib/vdr/video|%{videodir}|' -e 's|/etc/vdr/|%{configdir}/|' \
   < %{SOURCE15} > $RPM_BUILD_ROOT%{plugindir}/bin/%{name}-moveto.sh
 chmod 755 $RPM_BUILD_ROOT%{plugindir}/bin/%{name}-moveto.sh
 
@@ -397,11 +396,29 @@
 %pre
 getent group %{vdr_group} >/dev/null || groupadd -r %{vdr_group}
 getent passwd %{vdr_user} >/dev/null || \
-useradd -r -g %{vdr_group} -d %{videodir} -s /sbin/nologin -M -n \
+useradd -r -g %{vdr_group} -d %{vardir} -s /sbin/nologin -M -n \
     -c "Video Disk Recorder" %{vdr_user}
 :
 
 %post
+# Migrate stuff in vardir, videodir when upgrading from pre 1.6.0-15 (#443706)
+# TODO: to be removed in F-13
+if [ $1 -gt 1 -a -d /srv/vdr ] ; then
+
+    # Continue to use /srv/vdr as the video dir for old setups
+    f=%{_sysconfdir}/sysconfig/vdr
+    if ! grep -q '^\s*VDR_OPTIONS.* -v' $f ; then
+        sed -i -e 's|^\(\s*VDR_OPTIONS.*(\)\(.*\)|\1-v /srv/vdr \2|' $f
+    fi
+
+    # Move stuff previously in /var/lib/vdr to /var/lib/vdr/data
+    for f in $(find %{varbase} -mindepth 1 -maxdepth 1 -not -name data -not -name "video*") ; do
+        mv $f %{vardir}
+    done
+
+    # Set new home dir
+    usermod -d %{vardir} %{vdr_user}
+fi
 /sbin/chkconfig --add vdr || :
 
 %preun
@@ -436,12 +453,12 @@
 %{plugindir}/bin/%{name}-shutdown.sh
 %{datadir}/
 %{_mandir}/man[58]/vdr.[58]*
+%dir %{varbase}/
 %defattr(-,%{vdr_user},%{vdr_group},-)
 # TODO: tighten ownerships to root:root for some files in %{configdir}
 %config(noreplace) %{configdir}/*.conf
 %dir %{videodir}/
 %ghost %{videodir}/.update
-%dir %{audiodir}/
 %ghost %{vardir}/next-wakeup
 %ghost %{vardir}/themes/*.theme
 %ghost %{cachedir}/epg.data
@@ -494,6 +511,11 @@
 %endif # plugins
 
 %changelog
+* Sun Nov 23 2008 Ville Skyttä <ville.skytta at iki.fi> - 1.6.0-15
+- Reorganize dir structure for better Fedora guidelines compliance (#443706):
+  /var/lib/vdr/* -> /var/lib/vdr/data, /srv/video -> /var/lib/vdr/video.
+- Drop audiodir and ownership of /srv/audio, examples still point to it.
+
 * Sat Nov 22 2008 Ville Skyttä <ville.skytta at iki.fi> - 1.6.0-8
 - Fix setting wakeup time via rtc0 when hardware clock is localtime.
 - Drop remote plugin examples from udev rules, they're in vdr-remote now.




More information about the fedora-extras-commits mailing list