Blame SPECS/syslinux.spec

b837a6
Summary: Simple kernel loader which boots from a FAT filesystem
b837a6
Name: syslinux
b837a6
Version: 4.05
b837a6
%define tarball_version 4.05
b837a6
Release: 15%{?dist}
b837a6
License: GPLv2+
b837a6
Group: Applications/System
b837a6
URL: http://syslinux.zytor.com/wiki/index.php/The_Syslinux_Project
b837a6
Source0: http://www.kernel.org/pub/linux/utils/boot/syslinux/%{name}-%{tarball_version}.tar.bz2
b837a6
ExclusiveArch: x86_64
b837a6
Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
b837a6
BuildRequires: nasm >= 0.98.38-1, perl, netpbm-progs, git
b837a6
BuildRequires: libuuid-devel
b837a6
BuildRequires: /usr/include/gnu/stubs-32.h
b837a6
BuildRequires: cpio, findutils
b837a6
%ifarch x86_64
b837a6
Requires: mtools, libc.so.6()(64bit), libuuid
b837a6
%endif
b837a6
b837a6
Patch0001: syslinux-isohybrid-fix-mbr.patch
b837a6
Patch0002: syslinux-4.05-avoid-ext2_fs.h.patch
b837a6
Patch0003: syslinux-4.05-man-pages.patch
b837a6
Patch0006: 0003-Fixes-for-problems-discovered-by-coverity-scan.-8120.patch
b837a6
Patch0007: 0004-Make-some-more-mingw-paths-work.patch
b837a6
Patch0008: 0001-Don-t-use-strict-aliasing-because-not-everything-her.patch
b837a6
Patch0009: 0001-relocs-Move-stop-to-the-end.patch
b837a6
Patch0010: 0005-Save-Dell-BIOS-chunk-in-PXELINUX.patch
b837a6
b837a6
%description
b837a6
SYSLINUX is a suite of bootloaders, currently supporting DOS FAT
b837a6
filesystems, Linux ext2/ext3 filesystems (EXTLINUX), PXE network boots
b837a6
(PXELINUX), or ISO 9660 CD-ROMs (ISOLINUX).
b837a6
b837a6
%package perl
b837a6
Summary: Syslinux tools written in perl
b837a6
Group: Applications/System
b837a6
b837a6
%description perl
b837a6
Syslinux tools written in perl
b837a6
b837a6
%package extlinux
b837a6
Summary: The EXTLINUX bootloader, for booting the local system.
b837a6
Group: System/Boot
b837a6
Requires: syslinux
b837a6
b837a6
%description extlinux
b837a6
The EXTLINUX bootloader, for booting the local system, as well as all
b837a6
the SYSLINUX/PXELINUX modules in /boot.
b837a6
b837a6
%package devel
b837a6
Summary: Headers and libraries for syslinux development.
b837a6
Group: Development/Libraries
b837a6
b837a6
%description devel
b837a6
Headers and libraries for syslinux development.
b837a6
b837a6
%package tftpboot
b837a6
Summary: SYSLINUX modules in /var/lib/tftpboot, available for network booting
b837a6
Group: Applications/Internet
b837a6
BuildArch: noarch
b837a6
b837a6
%description tftpboot
b837a6
All the SYSLINUX/PXELINUX modules directly available for network
b837a6
booting in the /var/lib/tftpboot directory.
b837a6
b837a6
%prep
b837a6
%setup -q -n syslinux-%{tarball_version}
b837a6
git init
b837a6
git config user.email "nobody@example.com"
b837a6
git config user.name "RHEL Ninjas"
b837a6
git add .
b837a6
git commit -a -q -m "%{version} baseline."
b837a6
git am %{patches} 
b837a6
b837a6
%build
b837a6
CFLAGS="-Werror -Wno-unused -finline-limit=2000"
b837a6
export CFLAGS
b837a6
b837a6
# If you make clean here, we lose the provided syslinux.exe
b837a6
find . -name '*.exe' | cpio -H newc --quiet -o -F %{_tmppath}/%{name}-%{version}-%{release}.cpio
b837a6
make clean
b837a6
# There's an x86_64 image here that shouldn't be, and it makes i686 builds fail.
b837a6
rm -vf diag/geodsp/mk-lba-img
b837a6
make all
b837a6
make installer
b837a6
make -C sample tidy
b837a6
b837a6
%install
b837a6
rm -rf %{buildroot}
b837a6
b837a6
mkdir -p %{buildroot}%{_bindir}
b837a6
mkdir -p %{buildroot}%{_sbindir}
b837a6
mkdir -p %{buildroot}%{_prefix}/lib/syslinux
b837a6
mkdir -p %{buildroot}%{_includedir}
b837a6
cat %{_tmppath}/%{name}-%{version}-%{release}.cpio | cpio -di
b837a6
make install-all \
b837a6
	INSTALLROOT=%{buildroot} BINDIR=%{_bindir} SBINDIR=%{_sbindir} \
b837a6
       	LIBDIR=%{_prefix}/lib DATADIR=%{_datadir} \
b837a6
	MANDIR=%{_mandir} INCDIR=%{_includedir} \
b837a6
	TFTPBOOT=/var/lib/tftpboot EXTLINUXDIR=/boot/extlinux
b837a6
b837a6
mkdir -p %{buildroot}/%{_docdir}/%{name}-%{version}/sample
b837a6
install -m 644 sample/sample.* %{buildroot}/%{_docdir}/%{name}-%{version}/sample/
b837a6
mkdir -p %{buildroot}/etc
b837a6
( cd %{buildroot}/etc && ln -s ../boot/extlinux/extlinux.conf . )
b837a6
b837a6
# don't ship libsyslinux, at least, not for now
b837a6
rm -f %{buildroot}%{_prefix}/lib/libsyslinux*
b837a6
rm -f %{buildroot}%{_includedir}/syslinux.h
b837a6
b837a6
mkdir -p %{buildroot}/%{_libdir}/syslinux/com32/
b837a6
mv %{buildroot}/%{_datadir}/syslinux/com32/*.a %{buildroot}/%{_libdir}/syslinux/com32/
b837a6
b837a6
%clean
b837a6
rm -rf %{buildroot}
b837a6
b837a6
%files
b837a6
%defattr(-,root,root)
b837a6
%doc NEWS README* COPYING 
b837a6
%doc doc/* 
b837a6
%doc sample
b837a6
%{_mandir}/man1/gethostip*
b837a6
%{_mandir}/man1/isohybrid*
b837a6
%{_mandir}/man1/memdiskfind*
b837a6
%{_mandir}/man1/syslinux*
b837a6
%{_bindir}/gethostip
b837a6
%{_bindir}/isohybrid
b837a6
%{_bindir}/memdiskfind
b837a6
%{_bindir}/syslinux
b837a6
%dir %{_datadir}/syslinux
b837a6
%dir %{_datadir}/syslinux/dosutil
b837a6
%{_datadir}/syslinux/dosutil/*
b837a6
%dir %{_datadir}/syslinux/diag
b837a6
%{_datadir}/syslinux/diag/*
b837a6
%{_datadir}/syslinux/memdisk
b837a6
%{_datadir}/syslinux/*.com
b837a6
%{_datadir}/syslinux/*.exe
b837a6
%{_datadir}/syslinux/*.c32
b837a6
%{_datadir}/syslinux/*.bin
b837a6
%{_datadir}/syslinux/*.0
b837a6
b837a6
%files perl
b837a6
%defattr(-,root,root)
b837a6
%{_mandir}/man1/lss16toppm*
b837a6
%{_mandir}/man1/ppmtolss16*
b837a6
%{_mandir}/man1/syslinux2ansi*
b837a6
%{_bindir}/keytab-lilo
b837a6
%{_bindir}/lss16toppm
b837a6
%{_bindir}/md5pass
b837a6
%{_bindir}/mkdiskimage
b837a6
%{_bindir}/ppmtolss16
b837a6
%{_bindir}/pxelinux-options
b837a6
%{_bindir}/sha1pass
b837a6
%{_bindir}/syslinux2ansi
b837a6
%{_bindir}/isohybrid.pl
b837a6
b837a6
%files extlinux
b837a6
%defattr(-,root,root)
b837a6
%{_sbindir}/extlinux
b837a6
%{_mandir}/man1/extlinux*
b837a6
%config /etc/extlinux.conf
b837a6
/boot/extlinux
b837a6
b837a6
%files devel
b837a6
%defattr(-,root,root)
b837a6
%dir %{_datadir}/syslinux/com32
b837a6
%{_datadir}/syslinux/com32
b837a6
%dir %{_libdir}/syslinux/com32
b837a6
%{_libdir}/syslinux/com32/*
b837a6
b837a6
%files tftpboot
b837a6
%defattr(-,root,root)
b837a6
%{_sharedstatedir}/tftpboot
b837a6
b837a6
%post extlinux
b837a6
# If we have a /boot/extlinux.conf file, assume extlinux is our bootloader
b837a6
# and update it.
b837a6
if [ -f /boot/extlinux/extlinux.conf ]; then \
b837a6
	extlinux --update /boot/extlinux ; \
b837a6
elif [ -f /boot/extlinux.conf ]; then \
b837a6
	mkdir -p /boot/extlinux && \
b837a6
	mv /boot/extlinux.conf /boot/extlinux/extlinux.conf && \
b837a6
	extlinux --update /boot/extlinux ; \
b837a6
fi
b837a6
b837a6
%changelog
b837a6
* Thu Sep 20 2018 Javier Martinez Canillas <javierm@redhat.com> - 4.05-15
b837a6
- Drop x86_64 ExclusiveArch for tftpboot subpackage.
b837a6
  Resolves: rhbz#1588578
b837a6
b837a6
* Wed Sep 12 2018 Javier Martinez Canillas <javierm@redhat.com> - 4.05-14
b837a6
- Make tftpboot package noarch
b837a6
  Resolves: rhbz#1588578
b837a6
b837a6
* Tue May 10 2016 Peter Jones <pjones@redhat.com> - - 4.05-13
b837a6
- Try to work around firmware bugs in the PXE stack.
b837a6
  Resolves: rhbz#1254615
b837a6
b837a6
* Fri Sep 26 2014 Peter Jones <pjones@redhat.com> - 4.05-12
b837a6
- Toolchain changes between when this originally got built and 4.05-9 means
b837a6
  4.05-9 - 4.05-11 don't actually work.
b837a6
  Related: rhbz#1085434
b837a6
b837a6
* Tue Sep 23 2014 Peter Jones <pjones@redhat.com> - 4.05-11
b837a6
- Fix some rpmdiff problems.
b837a6
  Related: rhbz#1085434
b837a6
b837a6
* Tue Sep 23 2014 Peter Jones <pjones@redhat.com> - 4.05-10
b837a6
- Fix some aliasing errors rpmdiff complains about.
b837a6
  Related: rhbz#1085434
b837a6
b837a6
* Tue Sep 02 2014 Peter Jones <pjones@redhat.com> - 4.05-9
b837a6
- Try harder to build everything correctly.
b837a6
  Resolves: rhbz#1085434
b837a6
b837a6
* Thu Feb 27 2014 David Cantrell <dcantrell@redhat.com> - 4.05-8
b837a6
- Only build for x86_64
b837a6
  Resolves: rhbz#1070659
b837a6
b837a6
* Mon Jan 20 2014 Peter Jones <pjones@redhat.com> - 4.05-7
b837a6
- Improve documentation.
b837a6
  Resolves: rhbz#948852
b837a6
b837a6
* Fri Dec 27 2013 Daniel Mach <dmach@redhat.com> - 4.05-6
b837a6
- Mass rebuild 2013-12-27
b837a6
b837a6
* Fri Feb 15 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.05-5
b837a6
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
b837a6
b837a6
* Mon Aug 06 2012 Peter Jones <pjones@redhat.com> - 4.05-4
b837a6
- Fix build problem from kernel-headers' removeal of ext2_fs.h
b837a6
  (fix backported from as-yet-unreleased upstream version.)
b837a6
b837a6
* Sat Jul 21 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.05-3
b837a6
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
b837a6
b837a6
* Wed Apr 18 2012 Michael Schwendt <mschwendt@fedoraproject.org> - 4.05-2
b837a6
- Remove old Obsoletes/Provides for syslinux-devel as such a subpkg
b837a6
  was introduced with 3.83-2 (#756733).
b837a6
b837a6
* Wed Feb 15 2012 Matthew Garrett <mjg@redhat.com> - 4.05-1
b837a6
- New upstream release
b837a6
- syslinux-isohybrid-fix-mbr.patch: generate a full MBR for UEFI images
b837a6
b837a6
* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.02-6
b837a6
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
b837a6
b837a6
* Wed Aug 24 2011 Matthew Garrett <mjg@redhat.com> - 4.02-5
b837a6
- Add support for building Mac and GPT bootable hybrid images
b837a6
b837a6
* Wed Feb 09 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 4.02-4
b837a6
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
b837a6
b837a6
* Fri Aug 20 2010 Matt Domsch <mdomsch@fedoraproject.org> - 4.02-2
b837a6
- add perl subpackage, move perl apps there
b837a6
b837a6
* Fri Aug 06 2010 Peter Jones <pjones@redhat.com> - 4.02-2
b837a6
- Split out extlinux and tftpboot.
b837a6
- remove duplicate syslinux/com32/ left in base package after 3.83-2
b837a6
b837a6
* Thu Aug 05 2010 Peter Jones <pjones@redhat.com> - 4.02-1
b837a6
- Update to 4.02