wok-next view gpxe/receipt @ rev 20324

linux-libre-api-headers: update bdeps
author Pascal Bellard <pascal.bellard@slitaz.org>
date Sun Nov 12 00:47:34 2017 +0100 (2017-11-12)
parents 582967b5089b
children 57b2961597ae
line source
1 # SliTaz package receipt v2.
3 PACKAGE="gpxe"
4 VERSION="0.9.3"
5 CATEGORY="system-tools"
6 SHORT_DESC="Ethernet bootloader."
7 MAINTAINER="pascal.bellard@slitaz.org"
8 LICENSE="GPL2"
9 TARBALL="$PACKAGE-$VERSION.tar.bz2"
10 WEB_SITE="http://www.etherboot.org/"
11 WGET_URL="http://kernel.org/pub/software/utils/boot/$PACKAGE/Old/$TARBALL"
13 BUILD_DEPENDS="perl"
14 SPLIT="gpxe gpxe-pxe"
16 # Rules to configure and make the package.
17 compile_rules()
18 {
19 cd $src/src
20 for i in prefix.u default_boot.u cmdline.u url_list.u gcc.u; do
21 [ -f done.$i ] && continue
22 echo "Apply $i..."
23 patch -p2 < $stuff/$i || return 1
24 touch done.$i
25 done
26 sed -i 's/ = ++ns->cur_rx %/++; ns->cur_rx %=/' drivers/net/ns83820.c
27 sed -i 's/ = (++tp->cur_rx) %/++; tp->cur_rx %=/' drivers/net/tulip.c
28 sed -i 's/? s : ___strtok//' core/stringextra.c
29 sed -i '/timer2_running/d' include/timer.h
30 make EXTRA_CFLAGS="-fno-strict-aliasing -Wno-error=unused-but-set-variable" bin/gpxe.lkrn bin/undionly.kpxe 2>&1 | grep -v housekeeping: | grep -v blib.list
31 }
33 # Rules to gen a SliTaz package suitable for Tazpkg.
34 genpkg_rules()
35 {
36 case $PACKAGE in
37 gpxe)
38 mkdir -p $fs/boot
39 cp $src/src/bin/gpxe.lkrn $fs/boot/gpxe
40 # install 255 bytes of forced url at offset 519
41 echo -n "\
42 http://mirror.slitaz.org/pxe/pxelinux.0,\
43 http://mirror.switch.ch/ftp/mirror/pxe/pxelinux.0,\
44 http://download.tuxfamily.org/slitaz/pxe/pxelinux.0" | cat - /dev/zero | \
45 dd bs=1 seek=519 count=255 conv=notrunc of=$fs/boot/gpxe
46 ;;
47 gpxe-pxe)
48 CAT="system-tools|Ethernet bootloader for pxe server."
49 mkdir -p $fs/usr/share/boot
50 cp $src/src/bin/undionly.kpxe $fs/usr/share/boot/gpxe.pxe
51 # install 255 bytes of forced url at offset 5
52 echo -n "\
53 http://mirror.slitaz.org/pxe/pxelinux.0,\
54 http://mirror.switch.ch/ftp/mirror/pxe/pxelinux.0,\
55 http://download.tuxfamily.org/slitaz/pxe/pxelinux.0" | cat - /dev/zero | \
56 dd bs=1 seek=5 count=255 conv=notrunc of=$fs/usr/share/boot/gpxe.pxe
57 ;;
58 esac
59 }