wok-6.x view gpxe/receipt @ rev 25511
memtest: 386 support
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Mon Feb 13 17:17:56 2023 +0000 (21 months ago) |
parents | 22471cbea549 |
children | 3e8af413f00c |
line source
1 # SliTaz package receipt.
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 SOURCE="ipxe"
10 TARBALL="$SOURCE-$VERSION.tar.bz2"
11 WEB_SITE="http://etherboot.org/wiki/"
12 WGET_URL="https://git.ipxe.org/release/$SOURCE/$TARBALL"
14 BUILD_DEPENDS="perl"
16 # What is the latest version available today?
17 current_version()
18 {
19 wget -O - http://etherboot.org/wiki/ 2>/dev/null | \
20 sed '/released/!d;s|.*gPXE-||;s| rel.*||;q'
21 }
23 # Rules to configure and make the package.
24 compile_rules()
25 {
26 cd $src/src
27 sed -i 's|uname -m|echo i486|' Makefile
28 for i in prefix.u default_boot.u cmdline.u url_list.u gcc.u; do
29 [ -f done.$i ] && continue
30 echo "Apply $i..."
31 patch -p2 < $stuff/$i || return 1
32 touch done.$i
33 done
34 sed -i 's/ = ++ns->cur_rx %/++; ns->cur_rx %=/' drivers/net/ns83820.c
35 sed -i 's/ = (++tp->cur_rx) %/++; tp->cur_rx %=/' drivers/net/tulip.c
36 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
37 }
39 # Rules to gen a SliTaz package suitable for Tazpkg.
40 genpkg_rules()
41 {
42 mkdir -p $fs/boot
43 cp $src/src/bin/gpxe.lkrn $fs/boot/gpxe
44 # install 255 bytes of forced url at offset 519
45 echo -n "\
46 http://mirror.slitaz.org/pxe/pxelinux.0,\
47 http://mirror.switch.ch/ftp/mirror/pxe/pxelinux.0,\
48 http://download.tuxfamily.org/slitaz/pxe/pxelinux.0" | cat - /dev/zero | \
49 dd bs=1 seek=519 count=255 conv=notrunc of=$fs/boot/gpxe
50 }
52 # Pre and post install commands for Tazpkg.
53 post_install()
54 {
55 [ -s $1/boot/isolinux/isolinux.cfg ] &&
56 ! grep -qs 'Web Boot' $1/boot/isolinux/isolinux.cfg &&
57 sed -i 's|i18n.cfg|&\n\
58 LABEL web zeb\
59 MENU LABEL Web Boot\
60 KERNEL /boot/gpxe|' $1/boot/isolinux/isolinux.cfg
61 true
62 }