SPEC: udev-0.27-2.spec
Cezary Krzyżanowski
dhubleizh at o2.pl
Mon Jun 21 14:23:00 CEST 2004
WItam
Poprawiłem tego cholernego speca, bo głupoty wyczyniał.
To jest mój zupełnie pierwszy spec w życiu, więc nie bijce za bardzo.
Żeby automatycznie ruszał, trzeba dodać do rc.sysinit:
#set up udev
if [ -e /sbin/start_udev]; then
run_cmd "Starting Udev Filesystem Daemon" /sbin/start_udev
fi
Proponuję to dorzucić do speca rc-scripts, commitnąć i dodać do mojego
speca Req od nowszego rc-scripts.
Poprawcie wszystko co się da i wyjaśnijcie mi dlaczego tak, a nie inaczej :D
Zdroofka
Cz at rny
--
__________________________________________________
"Fear leads to anger, anger leads to hate, hate leads to The Dark Side"
- Yoda
-------------- next part --------------
# $Revision: 1.34 $, $Date: 2004/06/19 21:03:51 $
#
# Conditional build:
%bcond_with initrd # build udev-initrd
#
%define dev_ver 3.0.0
Summary: A userspace implementation of devfs
Summary(pl): Implementacja devfs w przestrzeni użytkownika
Name: udev
Version: 027
Release: 2
License: GPL
Group: Base
Source0: http://www.kernel.org/pub/linux/utils/kernel/hotplug/%{name}-%{version}.tar.bz2
# Source0-md5: 2c3eb9345d839013d560992cb6cf7222
BuildRequires: sed >= 4.0
Requires: coreutils
Requires: hotplug >= 2003_08_05
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
%define _sbindir /sbin
%description
A userspace implementation of devfs for 2.5 and higher kernels.
%description -l pl
Implementacja devfs w przestrzeni użytkownika dla jąder 2.5 i
wyższych.
%package initrd
Summary: A userspace implementation of devfs - static binary for initrd
Summary(pl): Implementacja devfs w przestrzeni użytkownika - statyczna binarka dla initrd
Group: Base
Requires: %{name} = %{version}-%{release}
%description initrd
A userspace implementation of devfs - static binary for initrd.
%description initrd -l pl
Implementacja devfs w przestrzeni użytkownika - statyczna binarka dla
initrd.
%prep
%setup -q
%build
EXTRAS="extras/scsi_id extras/volume_id"
%if %{with initrd}
%{__make} \
%ifarch athlon
ARCH=i386 \
%endif
udevdir=/udev \
CC="%{__cc}" \
%{!?debug:DEBUG=false} \
OPTIMIZATION="%{rpmcflags}" \
USE_KLIBC=true \
udev
cp -a udev udev-initrd
%{__make} clean
%endif
%{__make} \
udevdir=/udev \
CC="%{__cc}" \
%{!?debug:DEBUG=false} \
OPTIMIZATION="%{rpmcflags}" \
USE_LOG=true \
EXTRAS="$EXTRAS"
%install
rm -rf $RPM_BUILD_ROOT
EXTRAS="extras/scsi_id extras/volume_id"
install -d $RPM_BUILD_ROOT{%{_prefix}%{_sbindir},/udev}
%{__make} install \
DESTDIR=$RPM_BUILD_ROOT \
initdir=%{_initrddir} \
EXTRAS="$EXTRAS"
%if %{with initrd}
install -m755 udev-initrd $RPM_BUILD_ROOT%{_sbindir}
%endif
install -m755 extras/start_udev $RPM_BUILD_ROOT%{_sbindir}
mawk '\
/udev_root=\"\/udev\/\"/ { sub(/udev_root=\"\/udev\/\"/, "udev_root=\"/dev/\"") } \
/udev_db=\"\/udev/ { sub(/udev_db=\"\/udev/, "udev_db=\"/dev" ) } \
{ print }' \
$RPM_BUILD_ROOT%{_sysconfdir}/udev/udev.conf >> $RPM_BUILD_ROOT%{_sysconfdir}/udev/udev.conf.tmp
mv $RPM_BUILD_ROOT%{_sysconfdir}/udev/udev.conf.tmp $RPM_BUILD_ROOT%{_sysconfdir}/udev/udev.conf
mawk '\
/#run_udev/ {sub(/#run_udev/, "run_udev")} \
/\/sbin\/udevstart/ { sub(/\/sbin\/udevstart/, "#/sbin/udevstart") } \
{ print } ' \
$RPM_BUILD_ROOT%{_sbindir}/start_udev >> $RPM_BUILD_ROOT%{_sbindir}/start_udev.tmp
mv $RPM_BUILD_ROOT%{_sbindir}/start_udev.tmp $RPM_BUILD_ROOT%{_sbindir}/start_udev
%clean
rm -rf $RPM_BUILD_ROOT
%files
%defattr(644,root,root,755)
%doc ChangeLog FAQ HOWTO-udev_for_dev README TODO
%doc docs/{overview,udev_vs_devfs,libsysfs.txt,udev-*.pdf,RFC-dev.d}
%attr(755,root,root) %{_sbindir}/*
%attr(755,root,root) %{_prefix}%{_sbindir}/udev*
%if %{with initrd}
%exclude %{_sbindir}/udev-initrd
%endif
%attr(755,root,root) %{_bindir}/*
%attr(750,root,root) %dir %{_sysconfdir}/udev
%attr(640,root,root) %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/udev/*
%attr(750,root,root) %{_sysconfdir}/dev.d
%attr(755,root,root) %{_sysconfdir}/hotplug.d/default/*.hotplug
%config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/scsi_id.config
%attr(755,root,root) %{_sbindir}/scsi_id
%{_mandir}/man8/*
%if %{with initrd}
%files initrd
%defattr(644,root,root,755)
%attr(755,root,root) %{_sbindir}/udev-initrd
%endif
%define date %(echo `LC_ALL="C" date +"%a %b %d %Y"`)
%changelog
* %{date} PLD Team <feedback at pld-linux.org>
All persons listed below can be reached at <cvs_login>@pld-linux.org
$Log: udev.spec,v $
Revision 1.35 %{date} czarny
- removed dev subpackage - udev installs on ramfs at /dev
- added starting script
- start_udev runs a script, not the binary - allows to add there devices,
that udev doesn't recognize
Revision 1.34 2004/06/19 21:03:51 arekm
- dev subpackage
Revision 1.33 2004/06/15 00:16:53 arekm
- updated to 0.27; udev dir is /udev and it stays this way
Revision 1.32 2004/06/09 16:01:12 grzegol
- removed dbus and selinux extra packages - both are removed from sources
- removed scsi_id bcond - scsi_id extra package will always be built
- build also volume_id extra package
Revision 1.31 2004/06/08 10:19:35 pluto
- updated to 026.
Revision 1.30 2004/05/20 23:04:25 saq
- fix the selinux symlink
Revision 1.29 2004/05/20 22:48:16 arekm
- selinux builds
Revision 1.28 2004/05/20 22:37:18 saq
- up to 025
- dbus is now optional
Revision 1.27 2004/03/14 12:17:15 qboosh
- updated to 022
Revision 1.26 2004/03/12 22:29:48 orzech
- BR: pkgconfig
Revision 1.25 2004/03/11 10:33:00 wiget
- reverted initrd bcond (need more work)
Revision 1.24 2004/03/03 22:05:48 grzegol
- updated to 021
Revision 1.23 2004/02/29 21:36:09 grzegol
- updated to 019
Revision 1.22 2004/02/21 13:38:40 qboosh
- pl for -initrd
Revision 1.21 2004/02/21 13:37:35 qboosh
- patch not present in repo... so replaced by make option
Revision 1.20 2004/02/20 17:28:19 grzegol
- updated to 018
- more docs
Revision 1.19 2004/02/15 16:07:42 wiget
- updated to 017
- added initrd subpackage with static binary (builded against klibc)
Revision 1.18 2004/02/06 12:59:30 grzegol
- updated to 016
- removed outdated dbus patch
- added more docs
Revision 1.17 2004/01/31 19:16:34 grzegol
- R: dbus >= 0.20-2
Revision 1.16 2004/01/31 19:15:08 grzegol
- enabled dbus support
- added dbus patch (fix building with dbus support enabled)
- rel. 2
Revision 1.15 2004/01/27 00:19:43 qboosh
- updated to 015
Revision 1.14 2004/01/15 20:37:07 qboosh
- updated to 013, shared glibc again
Revision 1.13 2004/01/03 00:29:17 qboosh
- updated to 012
Revision 1.12 2003/12/26 14:16:08 qboosh
- updated to 011
Revision 1.11 2003/12/24 01:39:23 qboosh
- updated to 010
Revision 1.10 2003/12/17 22:02:16 qboosh
- updated to 009, use make install
Revision 1.9 2003/12/04 21:37:37 qboosh
- updated to 008
Revision 1.8 2003/11/28 22:31:50 qboosh
- updated to 007, added man page, BR: glibc-static
Revision 1.7 2003/10/21 17:05:20 arekm
- add FAQ to docs
Revision 1.6 2003/10/21 17:04:39 arekm
- updated to 004
Revision 1.5 2003/08/26 23:08:28 deejay1
- typo
Revision 1.4 2003/08/20 20:48:02 qboosh
- really use optflags, typo, BR: new sed
Revision 1.3 2003/08/17 12:14:45 arekm
- add hotplug script
Revision 1.2 2003/08/16 17:31:10 ankry
- pl description fix
Revision 1.1 2003/08/16 12:39:03 arekm
- initial pld release
More information about the pld-devel-pl
mailing list