# when updating, please rebuild ldetect as it is compiled against this static library %define build_diet 1 Name: pciutils Version: 2.2.6 Release: %mkrel 3 Source0: ftp://atrey.karlin.mff.cuni.cz/pub/linux/pci/%{name}-%{version}.tar.bz2 URL: http://atrey.karlin.mff.cuni.cz/~mj/pciutils.html Patch0: pciutils-2.2.1-use-stdint.patch Patch10: pciutils-2.2.4-pcimodules.patch Patch11: pciutils-2.2.1-cardbus-only-when-root.patch # allow build with dietlibc, using sycall() and sys/io.h Patch20: pciutils-2.2.6-noglibc.patch License: GPL Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-buildroot Requires: pciids %if %{build_diet} BuildRequires: dietlibc-devel %endif #- previous libldetect was requiring file /usr/share/pci.ids, hence a urpmi issue (cf #29299) Conflicts: %{mklibname ldetect 0.7} < 0.7.0-5mdv2007.1 Summary: PCI bus related utilities Group: System/Kernel and hardware %description This package contains various utilities for inspecting and setting devices connected to the PCI bus. The utilities provided require kernel version 2.1.82 or newer (supporting the /proc/bus/pci interface). %package devel Summary: Linux PCI development library Group: Development/C %description devel This package contains a library for inspecting and setting devices connected to the PCI bus. %prep %setup -q %patch0 -p1 %patch11 -p1 %patch10 -p1 %patch20 -p1 %build %if %{build_diet} %make PREFIX=%{_prefix} ZLIB=no OPT="-Os" CC="diet gcc" lib/libpci.a cp lib/libpci.a libpci.a.diet make clean %endif # do not build with zlib support since it's useless (only needed if we compress # pci.ids which we cannot do since hal mmaps it for memory saving reason) %make PREFIX=%{_prefix} OPT="$RPM_OPT_FLAGS -fPIC" ZLIB=no %install rm -rf $RPM_BUILD_ROOT install -d $RPM_BUILD_ROOT{%_bindir,%_mandir/man8,%_libdir,%_includedir/pci} install pcimodules lspci setpci $RPM_BUILD_ROOT%_bindir install -m 644 pcimodules.man lspci.8 setpci.8 $RPM_BUILD_ROOT%_mandir/man8 install -m 644 lib/libpci.a $RPM_BUILD_ROOT%_libdir %if %{build_diet} install -d $RPM_BUILD_ROOT%{_prefix}/lib/dietlibc/lib-%{_arch} install libpci.a.diet $RPM_BUILD_ROOT%{_prefix}/lib/dietlibc/lib-%{_arch}/libpci.a %endif install -m 644 lib/{pci.h,header.h,config.h,types.h} $RPM_BUILD_ROOT%_includedir/pci install -m 755 update-pciids.sh $RPM_BUILD_ROOT%_bindir/ %multiarch_includes $RPM_BUILD_ROOT%{_includedir}/pci/config.h %clean rm -rf $RPM_BUILD_ROOT %files %defattr(-, root, root) %doc README ChangeLog pciutils.lsm %{_mandir}/man8/* %{_bindir}/lspci %{_bindir}/pcimodules %{_bindir}/setpci %files devel %defattr(-, root, root) %doc TODO %{_bindir}/update-pciids.sh %{_libdir}/*.a %if %{build_diet} %{_prefix}/lib/dietlibc/lib-%{_arch}/libpci.a %endif %{_includedir}/pci %{_includedir}/*/pci %multiarch %{_includedir}/multiarch-*/pci/config.h %changelog * Wed Aug 15 2007 Olivier Blin <oblin@mandriva.com> 2.2.6-3mdv2008.0 + Revision: 63511 - build dietlibc library with -Os * Tue Aug 14 2007 Olivier Blin <oblin@mandriva.com> 2.2.6-2mdv2008.0 + Revision: 63367 - build dietlibc static library - add patch to be able to build with dietlibc + Thierry Vignaud <tvignaud@mandriva.com> - add a note asking for rebuilding ldetect on update * Wed Jun 27 2007 Thierry Vignaud <tvignaud@mandriva.com> 2.2.6-1mdv2008.0 + Revision: 45028 - new release + Pixel <pixel@mandriva.com> - replace BuildConflicts on zlib-devel with flag ZLIB=no * Mon May 14 2007 Thierry Vignaud <tvignaud@mandriva.com> 2.2.4-12mdv2008.0 + Revision: 26643 - build w/ozlib support since it's useless * Mon May 07 2007 Per Ãyvind Karlsen <pkarlsen@mandriva.com> 2.2.4-11mdv2008.0 + Revision: 23932 - add zlib-devel to buildrequires to ensure building with zlib support - do not strip binaries with 'install', otherwise rpm won't be able to create -debug package - do parallell build * Fri Mar 09 2007 Pixel <pixel@mandriva.com> 2.2.4-10mdv2007.1 + Revision: 138807 - add a conflict to help workaround urpmi #29299 (the other part of the fix is libldetect 0.7.0-5mdv now requiring pciids directly) - don't requires kernel (it was meant to be a conflict, and conflicting on kernel < 2.1.82 is useless nowadays) - requires pciids (otherwise lspci will fail) - remove BuildRequires needed by update-pciids (since it is called in pciids now) - remove pciutils-devel requiring pciutils, it's useless and help breaking the loop below: - move update-pciids.sh inside pciutils-devel (it's a little ugly, but it allows pciids to buildrequire pciutils-devel without introducing a loop (when bootstrapping distro)) * Thu Mar 08 2007 Thierry Vignaud <tvignaud@mandriva.com> 2.2.4-8mdv2007.1 + Revision: 138536 - package update-pciids.sh (for pciids package) - stop packaging pci.ids (now in pciids package) * Thu Mar 08 2007 Thierry Vignaud <tvignaud@mandriva.com> 2.2.4-7mdv2007.1 + Revision: 138525 - reenable updating pci.ids * Mon Feb 26 2007 Thierry Vignaud <tvignaud@mandriva.com> 2.2.4-6mdv2007.1 + Revision: 125875 - bump release * Mon Feb 26 2007 Thierry Vignaud <tvignaud@mandriva.com> 2.2.4-4mdv2007.1 + Revision: 125855 - bump release - fix library on x86_64 * Fri Feb 23 2007 Thierry Vignaud <tvignaud@mandriva.com> 2.2.4-3mdv2007.1 + Revision: 124846 - rebuild in order to update pci.ids - buildrequire curl for update-pciids.sh * Fri Jan 26 2007 Thierry Vignaud <tvignaud@mandriva.com> 2.2.4-2mdv2007.1 + Revision: 113897 - update pci.ids * Fri Nov 24 2006 Pixel <pixel@mandriva.com> 2.2.4-1mdv2007.1 + Revision: 86875 - new release - adapt patch10 - add /usr/include/multiarch-i386-linux/pci to file list (what's this?) - Import pciutils * Fri Jun 23 2006 Pixel <pixel@mandriva.com> 2.2.3-1mdv2007.0 - new release * Mon Jan 09 2006 Pixel <pixel@mandriva.com> 2.2.1-3mdk - use uint* & stdin.h instead of u_int* & sys/types.h (u_int* is not available in diet libc) * Thu Jan 05 2006 Pixel <pixel@mandriva.com> 2.2.1-2mdk - types.h is needed in pciutils-devel * Sun Dec 18 2005 Pixel <pixel@mandriva.com> 2.2.1-1mdk - new release - update pci.ids - redo patch11, patch10 - drop patch1, patch12 (applied upstream) - drop patch13 (seems to be useless) * Mon Dec 12 2005 Thierry Vignaud <tvignaud@mandriva.com> 2.1.11-21mdk - update pci.ids * Thu Nov 24 2005 Thierry Vignaud <tvignaud@mandriva.com> 2.1.11-20mdk - update pci.ids * Mon Nov 07 2005 Thierry Vignaud <tvignaud@mandriva.com> 2.1.11-19mdk - update pci.ids * Wed Oct 19 2005 Thierry Vignaud <tvignaud@mandriva.com> 2.1.11-18mdk - update pci.ids * Wed Sep 07 2005 Thierry Vignaud <tvignaud@mandriva.com> 2.1.11-17mdk - update pci.ids * Fri Aug 26 2005 Thierry Vignaud <tvignaud@mandriva.com> 2.1.11-16mdk - update pci.ids * Sat Jun 25 2005 Thierry Vignaud <tvignaud@mandrakesoft.com> 2.1.11-15mdk - update pci.ids * Wed May 25 2005 Thierry Vignaud <tvignaud@mandrakesoft.com> 2.1.11-14mdk - update pci.ids * Sat May 14 2005 Thierry Vignaud <tvignaud@mandrakesoft.com> 2.1.11-13mdk - update pci.ids * Tue May 10 2005 Thierry Vignaud <tvignaud@mandrakesoft.com> 2.1.11-12mdk - update pci.ids * Tue Apr 26 2005 Thierry Vignaud <tvignaud@mandrakesoft.com> 2.1.11-11mdk - update pci.ids * Tue Mar 08 2005 Thierry Vignaud <tvignaud@mandrakesoft.com> 2.1.11-10mdk - update pci.ids * Tue Feb 08 2005 Thierry Vignaud <tvignaud@mandrakesoft.com> 2.1.11-9mdk - update pci.ids * Fri Jan 21 2005 Gwenole Beauchesne <gbeauchesne@mandrakesoft.com> 2.1.11-8mdk - multiarch capable * Thu Dec 02 2004 Thierry Vignaud <tvignaud@mandrakesoft.com> 2.1.11-7mdk - update pci.ids * Wed Aug 04 2004 Thierry Vignaud <tvignaud@mandrakesoft.com> 2.1.11-6mdk - update pci.ids * Sat Jul 24 2004 Per Øyvind Karlsen <peroyvind@linux-mandrake.com> 2.1.11-5mdk - rebuild (to update pciids) - cosmetics