%define mitver 3.0-pre10 %define module_init_tools 1 Summary: Kernel module management utilities. Name: modutils Version: 2.4.26 Release: 16.fdr.1 Copyright: GPL Group: System Environment/Kernel Source: ftp://ftp.kernel.org/pub/linux/utils/kernel/modutils/v2.4/modutils-%{version}.tar.bz2 Source1: ftp://ftp.kernel.org/pub/linux/people/rusty/modules/module-init-tools-%{mitver}.tar.bz2 Source2: modprobe.conf.dist Patch1: modutils-2.4.10-systemmap.patch Patch2: modutils-2.4.2-prepost.patch Patch3: modutils-2.4.6-silence.patch Patch4: modutils-2.4.18-versions.patch Patch5: modutils-2.4.12-ppc3264.patch Patch6: modutils-2.4.14-kallsyms.patch Patch7: modutils-2.4.25-s390.patch Patch9: modutils-2.4.25-alias.patch Patch10: modutils-2.4.22-genksyms.patch Patch11: modutils-2.4.25-config.patch Patch12: modutils-2.4.25-updates.patch Patch13: modutils-2.4.25-trampoline.patch Patch101: modutils-2.4.18-small.patch Patch1000: modutils-module-init-tools.patch Patch1001: module-init-tools-0.9.14-combined-man.patch Patch1002: module-init-tools-defconfig.patch Patch1003: module-init-tools-updates.patch Exclusiveos: Linux Prereq: /sbin/chkconfig sh-utils Obsoletes: modules modutils-devel %if %{module_init_tools} Provides: module-init-tools = %{mitver} %endif BuildPrereq: bison flex zlib-devel autoconf BuildRoot: %{_tmppath}/%{name}-root %description The modutils package includes various programs needed for automatic loading and unloading of modules under 2.2 and later kernels, as well as other module management programs. Device drivers and filesystems are two examples of loaded and unloaded modules. %prep %setup -q -a 1 %patch1 -p1 -b .systemmap %patch2 -p1 -b .prepost %patch3 -p1 -b .silence %patch4 -p1 -b .versions %patch5 -p1 -b .ppc3264 %patch6 -p1 -b .kallsyms #%patch7 -p1 -b .s390 %patch9 -p1 -b .alias %patch10 -p1 %patch11 -p1 %patch12 -p1 -b .updates %patch13 -p1 -b .trampoline ln -s module-init-tools-%{mitver} module-init-tools %patch1001 -p0 %patch1002 -p0 %patch1003 -p1 %build autoconf %ifarch i386 if [ -x /usr/bin/diet ]; then export CC="diet gcc" fi %endif # insmod.static (diet) export CFLAGS="-Os -g" %if %{module_init_tools} patch -p1 < %{PATCH1000} ( cd module-init-tools-%{mitver} %configure --enable-zlib make combined CFLAGS="-Os -g -D_COMBINED_MODUTILS_=1" ) %endif %configure --disable-compat-2-0 --disable-kerneld --enable-insmod-static \ --exec_prefix=/ --disable-combined --enable-zlib --disable-strip make -C obj libobj.a make -C util libutil.a make -C insmod insmod.static cp insmod/insmod.static ./insmod.static make distclean # normal export CC=gcc export CFLAGS="$RPM_OPT_FLAGS" %if %{module_init_tools} ( make -C module-init-tools-%{mitver} distclean cd module-init-tools-%{mitver} %configure --enable-zlib make combined CFLAGS="$RPM_OPT_FLAGS -D_COMBINED_MODUTILS_=1" cp -p modprobe.conf.5 ../man/ ) %endif %configure --disable-compat-2-0 --disable-kerneld --exec_prefix=/ \ --enable-zlib --disable-strip make dep all %install rm -rf $RPM_BUILD_ROOT mkdir -p $RPM_BUILD_ROOT/sbin mkdir -p $RPM_BUILD_ROOT/%{_libdir} %makeinstall sbindir=$RPM_BUILD_ROOT/sbin %if %{module_init_tools} install -m 755 module-init-tools/generate-modprobe.conf \ $RPM_BUILD_ROOT/sbin for tool in lsmod modprobe rmmod depmod insmod modinfo; do if [ -f $RPM_BUILD_ROOT/%{_mandir}/man8/$tool.8 ] ; then mv $RPM_BUILD_ROOT/%{_mandir}/man8/$tool.8 \ $RPM_BUILD_ROOT/%{_mandir}/man8/$tool.old.8 fi done cd module-init-tools make install-man DESTDIR=$RPM_BUILD_ROOT mandir=%{_mandir} cd .. mkdir -p $RPM_BUILD_ROOT/etc install -m 644 %{SOURCE2} $RPM_BUILD_ROOT/etc/modprobe.conf.dist %endif rm -f $RPM_BUILD_ROOT/%{_mandir}/man8/{kdstat,kerneld}.8 find $RPM_BUILD_ROOT/sbin/ -name '*.static' -exec rm {} \; install -m 755 insmod.static $RPM_BUILD_ROOT/sbin %clean rm -rf $RPM_BUILD_ROOT %post # get rid of the old installations on upgrade if [ -x /etc/rc.d/init.d/kerneld ] ; then /sbin/chkconfig --del kerneld fi if [ -f /etc/conf.modules -a ! -f /etc/modules.conf ] ; then mv -f /etc/conf.modules /etc/modules.conf fi %if %{module_init_tools} if [ -f /etc/modules.conf -a ! -f /etc/modprobe.conf ] ; then echo "# Note: for use under 2.4, changes must also be made to modules.conf!" >/etc/modprobe.conf /sbin/generate-modprobe.conf --stdin < /etc/modules.conf >> /etc/modprobe.conf 2>/dev/null chmod 644 /etc/modprobe.conf echo "# Note: for use under 2.6, changes must also be made to modprobe.conf!" >> /etc/modules.conf fi %endif %files %defattr(-,root,root) %if %{module_init_tools} /etc/modprobe.conf.dist %endif /sbin/* %{_mandir}/*/* %changelog * Wed Jun 16 2004 Thomas Vander Stichele 2.4.26-16.fdr.1 - make modinfo and depmod prefer modules living under updates/ unconditionally (same as 2.4 behaviour) * Wed May 5 2004 Bill Nottingham 2.4.26-16 - fix sound restoring on module load when done via OSS compat * Thu Apr 15 2004 Bill Nottingham 2.4.26-15 - don't buildreq autoconf-2.13 (#116770) - sound-slot-0/snd-card-0 hacking-around * Mon Mar 29 2004 Bill Nottingham 2.4.26-14 - modinfo: use new modinfo if passed .ko * Tue Mar 23 2004 Steve Dickson - Added the mounting of /proc/fs/nfsd to modprobe.conf.dist so it gets mounted when nfsd is loaded. * Tue Mar 16 2004 Steve Dickson - /var/lib/nfs/rpc_pipefs not /var/lib/rpc_pipes should be mounted when sunrpc is loaded. * Fri Mar 12 2004 Steve Dickson - umount rpc_pipefs when sunrpc is unloaded * Thu Mar 11 2004 Bill Nottingham 2.4.26-9 - add nfsv4 aliases to modprobe.conf.dist - clean out upstreamed aliases in modprobe.conf.dist - mount rpc_pipefs when sunrpc is loaded * Fri Mar 5 2004 Bill Nottingham 2.4.26-7 - blacklist eth1394 (#117383) * Mon Feb 23 2004 Bill Nottingham 2.4.26-6 - update module-init-tools to 3.0pre10 - fix modinfo (#116305) - always include /etc/modprobe.conf.dist (don't require the line in modprobe.conf) - ship a static modprobe.conf.dist, don't generate it at build time - clean up modprobe.conf.dist a little (#113772, #113768) * Fri Feb 13 2004 Elliot Lee - rebuilt * Wed Feb 11 2004 Bill Nottingham - don't use trampolines in insmod, working around #106005 * Thu Jan 29 2004 Bill Nottingham 2.4.26-3 - fix irda (#114268), bluetooth (#114019) and alsa aliases * Tue Dec 16 2003 Bill Nottingham 2.4.26-2 - add OSS compat ALSA module aliases for 2.6 * Mon Dec 15 2003 Bill Nottingham 2.4.26-1 - update to 2.4.26 - switch around man pages; the module-init-tools man pages are now the default - add backwards compat usb aliases for the simple case - add some commentary to modules.conf/modprobe.conf on conversion - modutils-devel goes away * Tue Oct 7 2003 Bill Nottingham 2.4.25-13 - fix handling of updates path (#106482) * Tue Sep 30 2003 Bill Nottingham 2.4.25-12 - add modprobe.conf(5) (#105760, ) * Tue Sep 30 2003 Bill Nottingham 2.4.25-11 - update to module-init-tools-0.9.14, enable zlib, adjust patches * Thu Sep 25 2003 Bill Nottingham 2.4.25-10 - provide module-init-tools * Mon Sep 8 2003 Bill Nottingham 2.4.25-9 - fix bluetooth typo (#88859) - add viocd alias (#89232) * Mon Jul 7 2003 Bill Nottingham 2.4.25-8 - fix leak in module-init-tools-depmod () - look in /lib/modules/`uname -r`/updates for modules * Fri Jun 20 2003 Bill Nottingham 2.4.25-6 - fix modprobe -C when there is no modules.dep file * Mon Jun 9 2003 Bill Nottingham 2.4.25-5 - add IPSEC encryption & auth aliases - fix alias * Wed Jun 04 2003 Elliot Lee - rebuilt * Wed May 28 2003 Bill Nottingham 2.4.25-2 - add joystick alias (#91309) - add alias for af_key for IPSEC - update module-init-tools to 0.9.12 - ship a modprobe.conf.dist with the aliases that are built into 2.4 modutils - generate a modprobe.conf if needed on install * Fri Apr 25 2003 Bill Nottingham 2.4.25-1 - update to 2.4.25 - add floppy alias back (#89097) - add bluetooth aliases (#88859) * Tue Apr 3 2003 Bill Nottingham 2.4.22-10 - quick hack fix for depmod so the installer will work * Wed Apr 2 2003 Bill Nottingham 2.4.22-9 - include support for 2.5/2.6 kernels * Tue Feb 11 2003 Bill Nottingham 2.4.22-8 - alias block-major-2 off, we never ship it as a module (#71036) * Mon Feb 3 2003 Bill Nottingham 2.4.22-7 - make sure we don't use diet anywhere but x86, even if it's lying around - fix zlib linkage, for real - switch ftape alias (#7674) * Fri Jan 31 2003 Florian La Roche - add patch for genksyms to not segfault in drivers/char/joystick for mainframe kernel builds * Wed Jan 22 2003 Tim Powers - rebuilt * Thu Jan 16 2003 Bill Nottingham 2.4.22-4 - fix zlib static linkage patch * Tue Dec 31 2002 Bill Nottingham 2.4.22-3 - add alias for tun/tap (#80491) * Mon Dec 30 2002 Florian La Roche - add an IBM patch to also load 64bit kernel modules via a 31bit compiled app * Mon Nov 25 2002 Bill Nottingham 2.4.22-1 - update to 2.4.22 - don't link zlib dynamically * Tue Nov 19 2002 Bill Nottingham 2.4.21-1 - update to 2.4.21 - enable zlib for insmod.static, normal * Fri Aug 16 2002 Bill Nottingham 2.4.18-2 - add check for gcc version mismatch between kernel/modules () * Tue Jul 23 2002 Bill Nottingham 2.4.18-1 - update to 2.4.18 - add some more default aliases - fix checking of kernel version * Mon Jun 24 2002 Bill Nottingham 2.4.16-1 - update to 2.4.16 * Fri Jun 21 2002 Tim Powers - automated rebuild * Thu May 23 2002 Tim Powers - automated rebuild * Tue Apr 16 2002 Bill Nottingham 2.4.14-3 - force kallsyms on modules * Mon Apr 1 2002 Bill Nottingham 2.4.14-2 - fix support for symbols that contain _R () * Sat Mar 2 2002 Bill Nottingham 2.4.14-1 - update to 2.4.14 - take out genksyms.old, no more buildprereq for gperf * Thu Feb 28 2002 Bill Nottingham 2.4.13-7/8 - rebuild against diet - reenable rmmod in the library version, shrink it too * Wed Feb 27 2002 Bill Nottingham 2.4.13-5 - rebuild in earlier environments * Sun Feb 10 2002 Bill Nottingham 2.4.13-4 - various space shavings in -devel * Fri Feb 8 2002 Bill Nottingham 2.4.13-3 - bump rev - buildprereq gperf * Mon Feb 4 2002 Bill Nottingham 2.4.13-1 - update to 2.4.13 - fix GPL symbol export * Wed Jan 30 2002 Bill Nottingham 2.4.12-9 - shrink insmod.static * Thu Jan 24 2002 Bill Nottingham 2.4.12-8 - fix installation of extra libraries (#58427) * Thu Jan 17 2002 Bill Nottingham 2.4.12-7 - hack to allow depmod of 64bit kernels on 32bit PPC * Tue Jan 15 2002 Bill Nottingham 2.4.12-6 - more ppc64 fixes * Thu Jan 10 2002 Bill Nottingham 2.4.12-5 - fix build on combined 32/64 targets (ppc/sparc) * Tue Dec 11 2001 Matt Wilson - added a -devel subpackage that contains libraries that apps can use to implement insmod and rmmod * Tue Dec 4 2001 Bill Nottingham - get rid of some obsolete patches, other tweaks * Thu Nov 29 2001 Florian La Roche - update to 2.4.12 * Sat Nov 17 2001 Florian La Roche - update to 2.4.11 * Tue Oct 2 2001 Bill Nottingham - update to 2.4.10 - deprecate -i, -m arguments to depmod * Tue Sep 25 2001 Bill Nottingham - update to 2.4.9 * Wed Aug 29 2001 Bill Nottingham - replace modutils-2.4.6-error patch with version that was integrated upstream * Sat Aug 18 2001 Florian La Roche - disable char-major-4 for s390/s390x * Mon Jul 8 2001 Bill Nottingham - remove /etc/cron.d/kmod * Fri Jul 6 2001 Bill Nottingham - update to 2.4.6 - alias binfmt-0000 off (#9709) - turn off 'modules.conf is more recent than modules.dep' message (#14276, others) - return nonzero from depmod if there are errors (#40935) - fix manpage typo (#33123) * Thu Jul 05 2001 Karsten Hopp - new S390 patch from IBM * Tue Jun 26 2001 Elliot Lee 2.4.5-3 - Add modutils-2.4.5-stblocal.patch from Jakub. See the e-mail message inside the patch file for details. - Use smp_mflags macro * Thu Jun 21 2001 Florian La Roche - add s390/s390x support * Tue Apr 24 2001 Bill Nottingham - update to 2.4.5 * Tue Mar 6 2001 Bill Nottingham - add default post/preun for binfmt_misc * Mon Feb 19 2001 Bill Nottingham - change ipv6 alias to 'alias net-pf-10 off' * Tue Feb 13 2001 Bill Nottingham - add 'net-pf-10 ipv6' alias (#25405) * Sun Jan 28 2001 Florian La Roche - change "#ifdef s390" -> "#if defined(__s390__) || defined(__s390x__)" * Tue Jan 23 2001 Bill Nottingham - update to 2.4.2 - ship a genksyms.old * Fri Jan 19 2001 Bill Nottingham - fix ppp aliases * Tue Jan 9 2001 Bill Nottingham - oops, I blew away other people's changes. Fix that. - only have tty-ldisc-11 in the aliases once * Mon Jan 8 2001 Bill Nottingham - update to 2.4.0 - tweak irda aliases - remove vixie-cron dependency (it's not *required*) - add missing %build (where did that go?) * Sun Jan 7 2001 Bernhard Rosenkraenzer - 2.4.0 - Get rid of obsolete char-major-60==ircom-tty patch (moved to 161) * Sat Jan 06 2001 Florian La Roche - add "ctc{0,1,2} -> ctc" alias for s390 * Sat Dec 23 2000 Bill Nottingham - add missing comma in alias list - add irda aliases * Tue Dec 12 2000 Bill Nottingham - add char-major-108 ppp_async alias * Mon Dec 11 2000 Bill Nottingham - fix ide-probe aliases (now ide-probe-mod) * Wed Nov 22 2000 Matt Wilson - 2.3.21, fixes more security problems. * Thu Nov 16 2000 Bernhard Rosenkraenzer - 2.3.20, fixes security holes * Tue Oct 31 2000 Bernhard Rosenkraenzer - 2.3.19 - add IrDA devices to alias patch - update source URL * Thu Oct 26 2000 Bill Nottingham - fix ia64 module loading * Mon Oct 2 2000 Bill Nottingham - stupid ia64 tricks * Fri Sep 29 2000 Jeff Johnson - upgrade to 2.3.17. - sparc64 ELF hacks. * Mon Aug 21 2000 Michael K. Johnson - Use %{_mandir} for removing kerneld-related man pages. * Wed Aug 9 2000 Jakub Jelinek - fix build on SPARC * Tue Aug 8 2000 Jakub Jelinek - update to 2.3.14 * Tue Jul 25 2000 Bill Nottingham - update to 2.3.13 - turn psaux off again - remove sound patch; it's obsolete * Wed Jul 19 2000 Jakub Jelinek - rebuild to cope with glibc locale binary incompatibility * Thu Jul 13 2000 Bernhard Rosenkraenzer - 2.3.12 - fix up ia64 * Wed Jul 12 2000 Prospector - automatic rebuild * Sat Jul 1 2000 Florian La Roche - add aliases for cipcb[0-3] * Wed Jun 14 2000 Matt Wilson - fix build on combined 32/64 bit sparc * Thu Jun 1 2000 Bill Nottingham - modules.confiscation * Wed May 17 2000 Bill Nottingham - add ia64 patch from Intel * Wed May 17 2000 Jakub Jelinek - fix build with glibc 2.2 * Tue May 09 2000 Doug Ledford - Correct %description to reflect that we don't build kerneld by default * Fri Apr 21 2000 Bernhard Rosenkraenzer - 2.3.11 * Mon Apr 3 2000 Bill Nottingham - fix net-pf-* aliases for ipx, appletalk * Fri Mar 17 2000 Bernhard Rosenkraenzer - 2.3.10 * Thu Feb 17 2000 Matt Wilson - added alias for agpgart * Mon Feb 14 2000 Bill Nottingham - hardcode psaux alias to off everywhere * Thu Feb 3 2000 Bill Nottingham - add a symlink from conf.modules.5 to modules.conf.5 * Fri Jan 29 2000 Bill Nottingham - fix breakage *correctly* * Sat Jan 22 2000 Bill Nottingham - fix breakage of our own cause w.r.t sound modules * Thu Jan 06 2000 Jakub Jelinek - update to 2.3.9. - port RH patches from 2.1.121 to 2.3.9 where needed. - disable warning about conf.modules for now, in 7.0 we should move to modules.conf. * Wed Oct 13 1999 Jakub Jelinek - hardcode psaux alias on sparc to off. * Tue Oct 05 1999 Bill Nottingham - hardcode parport aliases.... * Mon Oct 04 1999 Cristian Gafton - rebuild against new glibc in the sparc tree * Wed Sep 15 1999 Jakub Jelinek - rewrite sparckludge so that separate *64 binaries are not needed anymore. * Sat Sep 11 1999 Cristian Gafton - apply the last patch in the %%prep section (doh!) * Mon Apr 19 1999 Cristian Gafton - add support for the ppp compression modules by default * Tue Apr 13 1999 Michael K. Johnson - add cron.d file to run rmmod -as * Fri Apr 09 1999 Cristian Gafton - take out kerneld * Mon Apr 05 1999 Cristian Gafton - add patch to make all raid personalities recognized * Sun Mar 21 1999 Cristian Gafton - auto rebuild in the new build environment (release 7) * Thu Mar 18 1999 Cristian Gafton - obsoletes modules - get rid of the /lib/modules/preferred hack * Mon Mar 15 1999 Bill Nottingham - added support for /lib/modules/foo/pcmcia - make kerneld initscript not start by default * Tue Feb 23 1999 Matt Wilson - added sparc64 support from UltraPenguin * Tue Jan 12 1999 Cristian Gafton - call libtoolize to allow it to compile on the arm * Wed Dec 23 1998 Jeff Johnson - search /lib/modules/preferred before defaults but after specified paths. * Tue Nov 17 1998 Cristian Gafton - upgraded to version 2.1.121 * Thu Nov 05 1998 Erik Troan - added -m, -i options * Thu Oct 01 1998 Michael K. Johnson - fix syntax error I introduced when enhancing initscript * Wed Sep 30 1998 Michael K. Johnson - enhance initscript * Fri Aug 28 1998 Jeff Johnson - recompile statically linked binary for 5.2/sparc * Tue Jul 28 1998 Jeff Johnson - pick up ultrapenguin patches (not applied for now). - pre-generate keyword.c so gperf doesn't have to be present (not applied). - util/sys_cm.c: fix create_module syscall (signed return on sparc too) * Wed Jul 15 1998 Jeff Johnson - correct %postun typos * Fri May 01 1998 Erik Troan - added /lib/modules/preferred to search path * Fri Apr 24 1998 Prospector System - translations modified for de, fr, tr * Tue Apr 07 1998 Cristian Gafton - updated to 2.1.85 - actually make use of the BuildRoot * Fri Apr 3 1998 Jakub Jelinek - Fix sparc64, add modinfo64 on sparc. * Wed Mar 23 1998 Jakub Jelinek - Handle EM_SPARCV9, kludge to support both 32bit and 64bit kernels from the same package on sparc/sparc64. * Fri Nov 7 1997 Michael Fulbright - removed warning message when conf.modules exists and is a empty * Tue Oct 28 1997 Erik Troan - patched to honor -k in options - added modprobe.1 - added init script * Thu Oct 23 1997 Erik Troan - removed bogus strip of lsmod (which is a script) * Mon Oct 20 1997 Erik Troan - updated to 2.1.55 - builds in a buildroot * Mon Aug 25 1997 Erik Troan - added insmod.static * Sun Aug 24 1997 Erik Troan - built on Intel - combined rmmod and insmod