wok-next view syslinux/receipt @ rev 20002
Up qps, avidemux, tea
author | Xander Ziiryanoff <psychomaniak@xakep.ru> |
---|---|
date | Fri Oct 20 23:49:15 2017 +0200 (2017-10-20) |
parents | d4a1a09fab2c |
children | dc31e6ee45f0 |
line source
1 # SliTaz package receipt.
3 PACKAGE="syslinux"
4 VERSION="4.06"
5 CATEGORY="base-system"
6 SHORT_DESC="LiveCD ISO bootloader (isolinux)"
7 MAINTAINER="pankso@slitaz.org"
8 LICENSE="GPL2"
9 TARBALL="$PACKAGE-$VERSION.tar.xz"
10 WEB_SITE="http://syslinux.zytor.com/"
11 WGET_URL="https://www.kernel.org/pub/linux/utils/boot/syslinux/$TARBALL"
12 LINLD="$WOK/linld/source"
13 CONFIG_FILES="/boot/isolinux/*.cfg /boot/isolinux/kbd"
14 TAGS="boot"
16 DEPENDS="ipxe memtest"
17 BUILD_DEPENDS="kbd-base perl nasm dev86 lzma mingw32-gcc upx posixovl \
18 util-linux-uuid-dev advancecomp libidn linld python"
20 # Rules to gen a SliTaz package suitable for Tazpkg.
21 compile_rules()
22 {
23 rm -f $src/core/isolinux.bin
24 patch -p 0 < $stuff/extra/loadhigh.u
25 patch -p 0 < $stuff/extra/iso9660.u
26 patch -p 0 < $stuff/extra/readconfig.u
27 patch -p 0 < $stuff/extra/keytab-lilo.u
28 cp -f $stuff/slitaz-next/miniacc.h $src/lzo/src/ # use latest https://raw.githubusercontent.com/upx/upx/master/src/miniacc.h
29 cp $stuff/tools/isohybrid.sh .
30 cp $stuff/extra/md5sum.c com32/modules
31 grep -q md5sum.c32 com32/modules/Makefile ||
32 sed -i 's/ifcpu64.c32/ifcpu64.c32 md5sum.c32/' com32/modules/Makefile
33 export LDFLAGS=''
34 make clean
35 echo "make all: LDFLAGS=$LDFLAGS"
36 make all 2>&1 | sed 's/NO_WERROR=1/NO_Werror=1/;/syslinux64.exe/d'
37 echo "make core: LDFLAGS=$LDFLAGS"
38 make -C core
39 make -C com32
40 ./isohybrid.sh --build
41 sed -i 's/loadkeys -m/loadkeys -u -m/' utils/keytab-lilo # for ru.kbd
42 mkdir kbd
43 for i in /usr/share/kbd/keymaps/i386/*/*.map.gz; do
44 [ "$(basename $(dirname $i))" == 'include' ] && continue
45 utils/keytab-lilo /usr/share/kbd/keymaps/i386/qwerty/us.map.gz \
46 $i > kbd/$(basename $i .map.gz)
47 done
48 cp -a $stuff/iso2exe .
49 cp $LINLD/*/tazboot.com iso2exe/boot.com
50 make -C iso2exe
51 }
53 # Rules to gen a SliTaz package suitable for Tazpkg.
54 genpkg_rules()
55 {
56 mkdir -p $fs/boot/isolinux $install/usr/share/doc
57 cp $stuff/iso2exe/README* $install/usr/share/doc
58 cp $stuff/iso2exe/init.custom $install/usr/share/doc
59 cp $LINLD/*/linld.com $fs/boot
60 cp -a $src/core/isolinux.bin $fs/boot/isolinux
61 lzma e $src/com32/modules/md5sum.c32 $fs/boot/isolinux/c32box.c32
62 lzma e $src/com32/menu/vesamenu.c32 $fs/boot/isolinux/vesamenu.c32
63 # $stuff/isolinux.msg is the old way the have a splash image.
64 cp $stuff/*.cfg $stuff/*.txt $stuff/help.* $stuff/opts.* $fs/boot/isolinux
65 rm -f $fs/boot/isolinux/common.cfg $fs/boot/isolinux/default.cfg
66 rm -f $fs/boot/isolinux/display.txt
67 while read label kbd loc tz menu; do
68 for i in ${kbd/,/ }; do
69 [ -e $src/kbd/$i ] || continue
70 cat >> $fs/boot/isolinux/i18n.cfg <<EOT
71 LABEL $label
72 MENU LABEL $menu
73 com32 c32box.c32
74 append kbdmap kbd $i lang=$loc kmap=${kbd#*,} tz=$tz
76 EOT
77 break
78 done
79 done <<EOT
80 br br-abnt2 pt_BR America/Sao_Paulo Brasil (abnt2)
81 br_ac\ brac us-acentos pt_BR America/Sao_Paulo Brasil (us-acentos)
82 cz cz-lat2 cs_CZ Europe/Prague Cesky
83 dk dk-latin1 da_DK Europe/Copenhagen Dansk
84 de de-latin1 de_DE Europe/Berlin Deutsch
85 de_CH\ deCH de_CH-latin1 de_CH Europe/Zurich Deutsch Schweiz
86 gr gr el_GR Europe/Helsinki Ellinika
87 en uk en_GB Europe/London English UK
88 us us en_US America/New_York English US
89 us_ac\ usac us-acentos en_US America/New_York English US (acentos)
90 us_dv\ usdv dvorak en_US America/New_York English US (dvorak)
91 us_dl\ usdl dvorak-l en_US America/New_York English US (dvorak-l)
92 us_dr\ usdr dvorak-r en_US America/New_York English US (dvorak-r)
93 es es es_ES Europe/Madrid Espanol
94 fr fr-latin1 fr_FR Europe/Paris Francais
95 be be-latin1 fr_BE Europe/Brussels Francais Belgique
96 ca cf fr_CA America/Montreal Francais Canada
97 fr_CH\ frCH fr_CH-latin1 fr_CH Europe/Zurich Francais Suisse
98 cr hr,croat hr_HR Europe/Zagreb Hrvatski
99 is is-latin1 is_IS Atlantic/Reykjavik Islenska
100 it it it_IT Europe/Rome Italiano
101 hu hu hu_HU Europe/Budapest Magyar
102 nl nl2 nl_NL Europe/Amsterdam Nederlands
103 no\ nb no-latin1 nb_NO Europe/Oslo Norsk (Bokmal)
104 nn no-latin1 nn_NO Europe/Oslo Norsk (Nynorsk)
105 po pl2 pl_PL Europe/Warsaw Polski
106 pt pt-latin1 pt_PT Europe/Lisbon Portugues
107 ru ru ru_RU Europe/Moscow Russian
108 sl slovene sl_SI Europe/Ljubljana Slovenski
109 fi fi fi_FI Europe/Helsinki Suomi
110 se se-lat6 sv_SE Europe/Stockholm Svenska
111 tr trq tr_TR Asia/Istanbul Turkce
112 EOT
113 #hr croat hr_HR Europe/Zagreb Hrvatski
114 #grpc gr-pc el_GR Europe/Helsinki Ellinika
115 #jp jp106 ja_JP Asia/Tokyo Japanese
116 #sg sg-latin1 de_CH Europe/Zurich Deutsch Schweiz (sg)
117 #tr5 tr_q-latin5 tr_TR Asia/Istanbul Turkce (latin5)
119 cat >> $fs/boot/isolinux/i18n.cfg <<EOT
120 LABEL exit
121 MENU LABEL Back to main menu
123 MENU EXIT
124 MENU END
125 EOT
126 sed -i 's/^LABEL us$/&\n MENU DEFAULT/' $fs/boot/isolinux/i18n.cfg
127 chown root.root $src/kbd/*
128 touch -r $src $src/kbd/*
129 for kbd in $(cd $src/kbd; ls | tee ../kbd.l); do
130 msg="Invalid file kbd/$kbd"
131 [ -s $src/kbd/$kbd ] && msg="Unused: file kbd/$kbd" &&
132 grep -q " $kbd " $fs/boot/isolinux/i18n.cfg && continue
133 sed -i "/^$kbd\$/d" $src/kbd.l
134 echo "$msg"
135 done
136 ( cd $src/kbd; cat ../kbd.l | cpio -o -H newc ) >$fs/boot/isolinux/kbd
137 lzma e $fs/boot/isolinux/kbd $fs/boot/isolinux/kbd.lzma
138 mv -f $fs/boot/isolinux/kbd.lzma $fs/boot/isolinux/kbd
139 chown root.root $fs/boot/isolinux/*
140 }
142 # Pre and post install commands for Tazpkg.
143 post_install()
144 {
145 sed -i "/MENU TITLE SliTaz GNU\/Linux/ s| [0-9X]*$| $(date +%Y%m%d)|" \
146 "$1/boot/isolinux/isolinux.cfg"
147 sed '/MENU TITLE/!d;s/MENU TITLE //' > $1/etc/slitaz-version \
148 < "$1/boot/isolinux/isolinux.cfg"
149 }