wok view memtest/receipt @ rev 24051

Add veracrypt
author Pascal Bellard <pascal.bellard@slitaz.org>
date Mon May 24 11:24:29 2021 +0000 (2021-05-24)
parents c4968381aed9
children ee53899c6189
line source
1 # SliTaz package receipt.
3 PACKAGE="memtest"
4 VERSION="5.01"
5 CATEGORY="base-system"
6 SHORT_DESC="Memory failures detection tool."
7 MAINTAINER="pascal.bellard@slitaz.org"
8 LICENSE="GPL2"
9 SOURCE="memtest86+"
10 TARBALL="$SOURCE-$VERSION.tar.gz"
11 WEB_SITE="http://www.memtest.org/"
12 WGET_URL="${WEB_SITE}download/$VERSION/$TARBALL"
14 BUILD_DEPENDS="xz"
16 tune_lzma()
17 {
18 cp $stuff/*.S $stuff/pack .
19 sed "s/VERSION/$VERSION/;s|lzma1=|&nice=$1,|" -i pack
20 while [ -n "$2" ]; do
21 sed "s|^#define PROP_$2 .*|#define PROP_$2 $3|" -i unlzma.S
22 shift 2
23 done
24 for i in bootloader unpack ; do
25 cc -o $i.o -Wa,-a=$i.lst -c $i.S
26 objcopy -O binary $i.o $i.bin
27 done
28 ./pack --build bootloader.bin unpack.bin
29 }
31 # Rules to configure and make the package.
32 compile_rules()
33 {
34 ls $stuff/memtest*-$VERSION-*.patch &&
35 for i in $stuff/memtest*-$VERSION-*.patch ; do
36 patch -p1 < $i
37 done
38 make
39 tune_lzma 218,mf=bt2 LC 2
40 ./pack memtest.bin memtest.packed
41 mv memtest.bin memtest.bin.console
42 sed -i -e 's/SERIAL_CONSOLE_DEFAULT 0/SERIAL_CONSOLE_DEFAULT 1/' \
43 -e 's/SERIAL_BAUD_RATE 9600/SERIAL_BAUD_RATE 115200/' config.h
44 make clean
45 make
46 tune_lzma 179,mf=bt2 LC 2
47 ./pack memtest.bin memtest.packed-115200
48 mv memtest.bin memtest.bin.serial
49 }
52 # Rules to gen a SliTaz package suitable for Tazpkg.
53 genpkg_rules()
54 {
55 mkdir -p $fs/boot $install/usr/share/doc
56 cp $src/README* $install/usr/share/doc
57 cp $src/FAQ $install/usr/share/doc
58 cp $src/memtest.packed $fs/boot/memtest.exe
59 }
61 # Pre and post install commands for Tazpkg.
62 post_install()
63 {
64 [ -s $1/boot/isolinux/isolinux.cfg ] &&
65 ! grep -qs 'Check memory' $1/boot/isolinux/isolinux.cfg && sed -i \
66 's|LABEL md5|LABEL memtest mem ram\
67 MENU LABEL Check memory\
68 KERNEL /boot/memtest.exe\
69 \n&|' $1/boot/isolinux/isolinux.cfg
70 true
71 }