%define name kernel-uml %define branch 2.6 %define minor 10 # Do we use a pre version %define ispre 0 %define prepatch test5 %define umlver 1 # the rpm-release %define rpmrel 1mdk %if %ispre %define ver %branch.%minor %define rel 0.%prepatch.%rpmrel %else %define ver %branch.%minor %define rel %rpmrel %endif %define version %ver %define release %rel %if %ispre %define kernel_source linux-%{ver}-%prepatch.tar.bz2 %define uml_patch uml-patch-%{ver}-%{prepatch}-%{umlver}.bz2 %else %define kernel_source linux-%{ver}.tar.bz2 %define uml_patch uml-patch-%{ver}-%{umlver}.bz2 %endif Summary: The user mode linux kernel Name: %{name} Version: %{version} Release: %{release} Group: Emulators Source0: %kernel_source #Patch0: %uml_patch Patch1: kernel-uml-2.6.10-fix-build.patch.bz2 Source1: %name-config.bz2 License: GPL Url: http://user-mode-linux.sourceforge.net/ BuildRoot: %{_tmppath}/%{name}-buildroot BuildRequires: glibc-static-devel %description User-Mode Linux is a safe, secure way of running Linux versions and Linux processes. Run buggy software, experiment with new Linux kernels or distributions, and poke around in the internals of Linux, all without risking your main Linux setup. User-Mode Linux gives you a virtual machine that may have more hardware and software virtual resources than your actual, physical computer. Disk storage for the virtual machine is entirely contained inside a single file on your physical machine. You can assign your virtual machine only the hardware access you want it to have. With properly limited access, nothing you do on the virtual machine can change or damage your real computer, or its software. %package -n %name-%ver-%rel Summary: The user mode linux kernel Group: Emulators Version: 1 Release: %rpmrel Provides: kernel-uml Requires: uml-utilities %description -n %name-%ver-%rel User-Mode Linux is a safe, secure way of running Linux versions and Linux processes. Run buggy software, experiment with new Linux kernels or distributions, and poke around in the internals of Linux, all without risking your main Linux setup. User-Mode Linux gives you a virtual machine that may have more hardware and software virtual resources than your actual, physical computer. Disk storage for the virtual machine is entirely contained inside a single file on your physical machine. You can assign your virtual machine only the hardware access you want it to have. With properly limited access, nothing you do on the virtual machine can change or damage your real computer, or its software. %prep %if %ispre %setup -q -n linux-%{ver}-%prepatch %else %setup -q -n linux-%{ver} %endif #%patch0 -p1 %patch1 -p1 bzcat %SOURCE1 > .config %build %make oldconfig ARCH=um make all ARCH=um make linux ARCH=um %install rm -rf $RPM_BUILD_ROOT %__mkdir_p %buildroot/%_bindir %__cp linux %buildroot/%_bindir/linux-%ver-%rel cd %buildroot/%_bindir %__ln_s linux-%ver-%rel linux %clean rm -rf $RPM_BUILD_ROOT %files -n %name-%ver-%rel %defattr(-,root,root) %doc Documentation/uml %_bindir/linux %_bindir/linux-%ver-%rel %changelog * Tue Feb 15 2005 Thierry Vignaud <tvignaud@mandrakesoft.com> 2.6.10-1mdk - new release - patch 1: fix build - source 1: o update o do not automatically mount devfs - add doc * Tue Sep 7 2004 Tibor Pittich <Tibor.Pittich@mandrake.org> 2.6.8.1-1mdk - 2.6.8.1 * Wed Aug 11 2004 Tibor Pittich <Tibor.Pittich@mandrake.org> 2.6.7-1mdk - 2.6.7 * Mon Jul 19 2004 Tibor Pittich <Tibor.Pittich@mandrake.org> 2.6.6-1mdk - updated to 2.6.6 - regenerated .config - some macroszification - redesigned symlink creation, removed from post * Thu Oct 09 2003 Olivier Thauvin <thauvin@aerov.jussieu.fr> 2.6.0-0.test5.3mdk - reupload * Wed Oct 08 2003 Olivier Thauvin <thauvin@aerov.jussieu.fr> 2.6.0-0.test5.2mdk - cleanup * Tue Oct 07 2003 Olivier Thauvin <thauvin@aerov.jussieu.fr> 2.6.0-0.test5.1mdk - First mdk spec