wok-6.x view hp15c/receipt @ rev 24491
Add some current_version
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Fri Feb 18 22:59:06 2022 +0000 (2022-02-18) |
parents | 19ad77dc1d71 |
children | 6b3ebe448683 |
line source
1 # SliTaz package receipt.
3 PACKAGE="hp15c"
4 SOURCE="HP-15C"
5 VERSION="4.0.00"
6 CATEGORY="office"
7 SHORT_DESC="HP-15C emulator."
8 MAINTAINER="pascal.bellard@slitaz.org"
9 LICENSE="GPL3"
10 WEB_SITE="http://hp-15c.homepage.t-online.de/content_web.htm"
11 TARBALL="${SOURCE}_${VERSION}_Source.zip"
12 WGET_URL="http://bit.ly/2FQ82VL"
14 DEPENDS="tk tcl"
15 BUILD_DEPENDS="wget"
17 # What is the latest version available today?
18 current_version()
19 {
20 wget -O - http://hp-15c.homepage.t-online.de/download.htm 2>/dev/null | \
21 sed '/version is/!d;s|.*<strong>||;s|,.*||;q'
22 }
24 # Rules to gen a SliTaz package suitable for Tazpkg.
25 genpkg_rules()
26 {
27 mkdir -p $fs/usr/share/hp15c $fs/usr/share/applications \
28 $fs/usr/share/fonts/truetype/ttf-dejavu
29 cp -a $src/* $fs/usr/share/hp15c
30 sed -i 's|firefox|tazweb midori &|' \
31 $fs/usr/share/hp15c/HP-15C.tcl \
32 $fs/usr/share/hp15c/doc/preferences.htm
33 sed -i 's|url_open \$helpfile|url_open file:///$helpfile|' \
34 $fs/usr/share/hp15c/HP-15C.tcl
35 mv $fs/usr/share/hp15c/HP-15C_Simulator_Font.ttf \
36 $fs/usr/share/fonts/truetype/ttf-dejavu
37 cat > $fs/usr/share/hp15c/HP-15C.sh <<EOT
38 #!/bin/sh
40 cd /usr/share/hp15c
41 tclsh HP-15C.tcl
42 EOT
43 chmod +x $fs/usr/share/hp15c/HP-15C.sh
44 cat > $fs/usr/share/applications/hp15c.desktop <<EOT
45 [Desktop Entry]
46 Encoding=UTF-8
47 Name=HP-15C Calculator
48 Name[fr]=Calculatrice HP-15C
49 Name[pt]=Calculadora HP-15C
50 Exec=/usr/share/hp15c/HP-15C.sh
51 Icon=/usr/share/hp15c/HP-15C.gif
52 Terminal=false
53 Type=Application
54 Categories=Application;Utility;
55 EOT
56 }