wok annotate syslinux/receipt @ rev 24920
updated mp (5.2.10 -> 5.58)
author | Hans-G?nter Theisgen |
---|---|
date | Sun Apr 10 07:48:27 2022 +0100 (2022-04-10) |
parents | f95bb62ba57c |
children | 73f36875e5a7 |
rev | line source |
---|---|
pankso@4 | 1 # SliTaz package receipt. |
pankso@4 | 2 |
pankso@4 | 3 PACKAGE="syslinux" |
pascal@13546 | 4 VERSION="4.06" |
pankso@4 | 5 CATEGORY="base-system" |
pankso@4 | 6 SHORT_DESC="LiveCD ISO bootloader (isolinux)" |
pankso@4 | 7 MAINTAINER="pankso@slitaz.org" |
pascal@14658 | 8 LICENSE="GPL2" |
pascal@11579 | 9 TARBALL="$PACKAGE-$VERSION.tar.xz" |
pankso@4 | 10 WEB_SITE="http://syslinux.zytor.com/" |
pascal@17923 | 11 WGET_URL="https://www.kernel.org/pub/linux/utils/boot/syslinux/$TARBALL" |
pascal@19516 | 12 LINLD="$WOK/linld/source" |
pascal@19304 | 13 CONFIG_FILES="/boot/isolinux/*.cfg /boot/isolinux/kbd" |
al@18471 | 14 TAGS="boot" |
pascal@17157 | 15 |
pascal@17923 | 16 BUILD_DEPENDS="wget kbd-base perl nasm dev86 lzma mingw32-gcc upx posixovl \ |
pascal@24180 | 17 util-linux-uuid-dev advancecomp libidn linld e2fsprogs" |
pascal@786 | 18 |
pascal@24076 | 19 current_version() |
pascal@24076 | 20 { |
pascal@24076 | 21 wget -O - $(dirname $WGET_URL) 2>/dev/null | \ |
pascal@24076 | 22 sed "/$PACKAGE-[0-9]/!d;/tar/!d;s|.*$PACKAGE-\\(.*\\).tar.*\".*|\\1|" | sort -Vr | sed q |
pascal@24076 | 23 } |
pascal@24076 | 24 |
pascal@786 | 25 # Rules to gen a SliTaz package suitable for Tazpkg. |
pascal@786 | 26 compile_rules() |
pascal@786 | 27 { |
al@18471 | 28 rm -f $src/core/isolinux.bin |
pascal@20056 | 29 for i in loadhigh iso9660 readconfig keytab-lilo lzop-1.03-gcc6 fixes-4.07 ; do |
pascal@20056 | 30 patch -p 0 < $stuff/extra/$i.u |
pascal@20056 | 31 done |
al@18471 | 32 cp $stuff/tools/isohybrid.sh . |
al@18471 | 33 cp $stuff/extra/md5sum.c com32/modules |
al@18471 | 34 grep -q md5sum.c32 com32/modules/Makefile || |
al@18471 | 35 sed -i 's/ifcpu64.c32/ifcpu64.c32 md5sum.c32/' com32/modules/Makefile |
al@18471 | 36 export LDFLAGS='' |
al@18471 | 37 make clean |
al@18471 | 38 echo "make all: LDFLAGS=$LDFLAGS" |
al@18471 | 39 make all 2>&1 | sed 's/NO_WERROR=1/NO_Werror=1/;/syslinux64.exe/d' |
al@18471 | 40 echo "make core: LDFLAGS=$LDFLAGS" |
al@18471 | 41 make -C core |
al@18471 | 42 make -C com32 |
al@18471 | 43 ./isohybrid.sh --build |
al@18471 | 44 sed -i 's/loadkeys -m/loadkeys -u -m/' utils/keytab-lilo # for ru.kbd |
pascal@18754 | 45 mkdir kbd |
al@18471 | 46 for i in /usr/share/kbd/keymaps/i386/*/*.map.gz; do |
pascal@20892 | 47 [ "$(basename $(dirname $i))" = 'include' ] && continue |
pascal@18754 | 48 utils/keytab-lilo /usr/share/kbd/keymaps/i386/qwerty/us.map.gz \ |
pascal@18754 | 49 $i > kbd/$(basename $i .map.gz) |
al@18471 | 50 done |
al@18471 | 51 cp -a $stuff/iso2exe . |
pascal@23998 | 52 cp $LINLD/*/linld.com iso2exe |
al@18471 | 53 make -C iso2exe |
pascal@786 | 54 } |
pankso@4 | 55 |
pankso@4 | 56 # Rules to gen a SliTaz package suitable for Tazpkg. |
pankso@4 | 57 genpkg_rules() |
pankso@4 | 58 { |
pascal@19517 | 59 mkdir -p $fs/boot/isolinux $install/usr/share/doc |
pascal@19517 | 60 cp $stuff/iso2exe/README* $install/usr/share/doc |
pascal@19517 | 61 cp $stuff/iso2exe/init.custom $install/usr/share/doc |
pascal@20057 | 62 cp $src/doc/*.txt $install/usr/share/doc |
pascal@20057 | 63 cp -a $src/man $install/usr/share/ |
pascal@19516 | 64 cp $LINLD/*/linld.com $fs/boot |
al@18471 | 65 cp -a $src/core/isolinux.bin $fs/boot/isolinux |
pascal@18757 | 66 lzma e $src/com32/modules/md5sum.c32 $fs/boot/isolinux/c32box.c32 |
pascal@18757 | 67 lzma e $src/com32/menu/vesamenu.c32 $fs/boot/isolinux/vesamenu.c32 |
al@18471 | 68 # $stuff/isolinux.msg is the old way the have a splash image. |
al@18471 | 69 cp $stuff/*.cfg $stuff/*.txt $stuff/help.* $stuff/opts.* $fs/boot/isolinux |
al@18471 | 70 rm -f $fs/boot/isolinux/common.cfg $fs/boot/isolinux/default.cfg |
al@18471 | 71 rm -f $fs/boot/isolinux/display.txt |
pascal@18783 | 72 while read label kbd loc tz menu; do |
al@18471 | 73 for i in ${kbd/,/ }; do |
pascal@20073 | 74 [ -e $src/kbd/$i ] || continue |
pascal@20073 | 75 map=" $i" |
pascal@20892 | 76 [ ${kbd#*,} = $i ] && map= |
al@18471 | 77 cat >> $fs/boot/isolinux/i18n.cfg <<EOT |
pascal@12287 | 78 LABEL $label |
pascal@12287 | 79 MENU LABEL $menu |
pascal@12287 | 80 com32 c32box.c32 |
pascal@20073 | 81 append kbd$map lang=$loc kmap=${kbd#*,} tz=$tz |
pascal@18754 | 82 |
pascal@1721 | 83 EOT |
al@18471 | 84 break |
al@18471 | 85 done |
al@18471 | 86 done <<EOT |
pascal@18783 | 87 br br-abnt2 pt_BR America/Sao_Paulo Brasil (abnt2) |
pascal@18783 | 88 br_ac\ brac us-acentos pt_BR America/Sao_Paulo Brasil (us-acentos) |
pascal@18783 | 89 cz cz-lat2 cs_CZ Europe/Prague Cesky |
pascal@18783 | 90 dk dk-latin1 da_DK Europe/Copenhagen Dansk |
pascal@18783 | 91 de de-latin1 de_DE Europe/Berlin Deutsch |
pascal@18783 | 92 de_CH\ deCH de_CH-latin1 de_CH Europe/Zurich Deutsch Schweiz |
pascal@18783 | 93 gr gr el_GR Europe/Helsinki Ellinika |
pascal@18783 | 94 en uk en_GB Europe/London English UK |
pascal@18783 | 95 us us en_US America/New_York English US |
pascal@18783 | 96 us_ac\ usac us-acentos en_US America/New_York English US (acentos) |
pascal@18783 | 97 us_dv\ usdv dvorak en_US America/New_York English US (dvorak) |
pascal@18783 | 98 us_dl\ usdl dvorak-l en_US America/New_York English US (dvorak-l) |
pascal@18783 | 99 us_dr\ usdr dvorak-r en_US America/New_York English US (dvorak-r) |
pascal@18783 | 100 es es es_ES Europe/Madrid Espanol |
pascal@18783 | 101 fr fr-latin1 fr_FR Europe/Paris Francais |
pascal@18783 | 102 be be-latin1 fr_BE Europe/Brussels Francais Belgique |
pascal@18783 | 103 ca cf fr_CA America/Montreal Francais Canada |
pascal@18783 | 104 fr_CH\ frCH fr_CH-latin1 fr_CH Europe/Zurich Francais Suisse |
pascal@18783 | 105 cr hr,croat hr_HR Europe/Zagreb Hrvatski |
pascal@18783 | 106 is is-latin1 is_IS Atlantic/Reykjavik Islenska |
pascal@18783 | 107 it it it_IT Europe/Rome Italiano |
pascal@18783 | 108 hu hu hu_HU Europe/Budapest Magyar |
pascal@18783 | 109 nl nl2 nl_NL Europe/Amsterdam Nederlands |
pascal@18783 | 110 no\ nb no-latin1 nb_NO Europe/Oslo Norsk (Bokmal) |
pascal@18783 | 111 nn no-latin1 nn_NO Europe/Oslo Norsk (Nynorsk) |
pascal@18783 | 112 po pl2 pl_PL Europe/Warsaw Polski |
pascal@18783 | 113 pt pt-latin1 pt_PT Europe/Lisbon Portugues |
pascal@18783 | 114 ru ru ru_RU Europe/Moscow Russian |
pascal@20055 | 115 ru_uk\ uk ru ru_UA Europe/Kiev Russian Ukraine |
pascal@18873 | 116 sl slovene sl_SI Europe/Ljubljana Slovenski |
pascal@18783 | 117 fi fi fi_FI Europe/Helsinki Suomi |
pascal@18783 | 118 se se-lat6 sv_SE Europe/Stockholm Svenska |
pascal@18783 | 119 tr trq tr_TR Asia/Istanbul Turkce |
pascal@12287 | 120 EOT |
pascal@18783 | 121 #grpc gr-pc el_GR Europe/Helsinki Ellinika |
pascal@18783 | 122 #jp jp106 ja_JP Asia/Tokyo Japanese |
pascal@18783 | 123 #sg sg-latin1 de_CH Europe/Zurich Deutsch Schweiz (sg) |
pascal@18783 | 124 #tr5 tr_q-latin5 tr_TR Asia/Istanbul Turkce (latin5) |
al@18471 | 125 |
al@18471 | 126 cat >> $fs/boot/isolinux/i18n.cfg <<EOT |
pascal@12287 | 127 LABEL exit |
pascal@12287 | 128 MENU LABEL Back to main menu |
pascal@18754 | 129 |
pascal@12287 | 130 MENU EXIT |
pascal@12287 | 131 MENU END |
pascal@1721 | 132 EOT |
al@18471 | 133 sed -i 's/^LABEL us$/&\n MENU DEFAULT/' $fs/boot/isolinux/i18n.cfg |
pascal@18754 | 134 chown root.root $src/kbd/* |
pascal@21786 | 135 touch -t 197001010100.00 $src/kbd/* |
pascal@18754 | 136 for kbd in $(cd $src/kbd; ls | tee ../kbd.l); do |
pascal@18754 | 137 msg="Invalid file kbd/$kbd" |
pascal@18754 | 138 [ -s $src/kbd/$kbd ] && msg="Unused: file kbd/$kbd" && |
pascal@20074 | 139 grep -q "[= ]$kbd " $fs/boot/isolinux/i18n.cfg && continue |
pascal@18754 | 140 sed -i "/^$kbd\$/d" $src/kbd.l |
pascal@18754 | 141 echo "$msg" |
al@18471 | 142 done |
pascal@21819 | 143 ( cd $src/kbd; cpio -o -H newc < ../kbd.l ) > $fs/boot/isolinux/kbd |
pascal@21819 | 144 lzma e $fs/boot/isolinux/kbd $fs/boot/isolinux/kbd.lzma # Add size field |
pascal@21819 | 145 mv -f $fs/boot/isolinux/kbd.lzma $fs/boot/isolinux/kbd |
al@18471 | 146 chown root.root $fs/boot/isolinux/* |
pankso@4 | 147 } |
pascal@786 | 148 |
pascal@1687 | 149 # Pre and post install commands for Tazpkg. |
pascal@1687 | 150 post_install() |
pascal@1687 | 151 { |
al@18640 | 152 sed -i "/MENU TITLE SliTaz GNU\/Linux/ s| [0-9X]*$| $(date +%Y%m%d)|" \ |
al@18480 | 153 "$1/boot/isolinux/isolinux.cfg" |
pascal@19509 | 154 sed '/MENU TITLE/!d;s/MENU TITLE //' > $1/etc/slitaz-version \ |
pascal@19509 | 155 < "$1/boot/isolinux/isolinux.cfg" |
pascal@20210 | 156 for i in $(grep -ls boot/isolinux/isolinux.cfg \ |
pascal@20217 | 157 $1/var/lib/tazpkg/installed/*/receipt); do |
pascal@20217 | 158 pkg=$(basename ${i%/*}) |
pascal@24276 | 159 [ "$pkg" != "$PACKAGE" ] && |
pascal@24276 | 160 echo "Reconfigue $pkg ..." && |
pascal@20355 | 161 root=/ chroot "$1/" tazpkg reconfigure $pkg |
pascal@20210 | 162 done |
pascal@1687 | 163 } |