wok-next view fltk/receipt @ rev 21017
Some maintenance
author | Aleksej Bobylev <al.bobylev@gmail.com> |
---|---|
date | Tue Oct 16 16:46:05 2018 +0300 (2018-10-16) |
parents | 757d032c55c7 |
children | d5aab818505e |
line source
1 # SliTaz package receipt v2.
3 PACKAGE="fltk"
4 VERSION="1.3.4"
5 CATEGORY="system-tools"
6 SHORT_DESC="Fast Light Tool Kit"
7 MAINTAINER="pankso@slitaz.org"
8 LICENSE="LGPL2"
9 WEB_SITE="http://www.fltk.org/"
10 LFS="http://www.linuxfromscratch.org/blfs/view/svn/x/fltk.html"
12 TARBALL="$PACKAGE-$VERSION-source.tar.gz"
13 WGET_URL="http://fltk.org/pub/fltk/$VERSION/$TARBALL"
15 BUILD_DEPENDS_arm="jpeg-dev libpng16-dev xorg-libXft-dev"
16 BUILD_DEPENDS="alsa-lib-dev libjpeg-turbo-dev zlib-dev libpng16-dev \
17 xorg-libX11-dev xorg-libICE-dev xorg-libSM-dev mesa-dev xorg-libXinerama-dev \
18 freetype-dev xorg-libXft-dev xorg-libXcursor-dev xorg-xprop"
19 SPLIT="fltk-blocks fltk-checkers fltk-sudoku fltk-colbrowser fltk-editor \
20 fltk-doc fltk fltk-dev"
21 COOKOPTS="!menus"
23 compile_rules() {
24 case "$ARCH" in
25 arm) ARCH_ARGS="--x-includes=/cross/$ARCH/sysroot/usr/include \
26 --x-libraries=/cross/$ARCH/sysroot/usr/lib";;
27 *) ARCH_ARGS='';;
28 esac
30 sed -i -e '/cat./d' documentation/Makefile
32 ./configure \
33 --enable-shared \
34 --enable-xft \
35 --enable-threads \
36 $ARCH_ARGS \
37 $CONFIGURE_ARGS &&
38 sed -i 's| -shared | -Wl,-Os,--as-needed\0|g' makeinclude &&
39 sed -i s'#"rgb.txt"#"/usr/share/fltk/rgb.txt"#' test/colbrowser.cxx &&
40 make $MAKEFLAGS &&
41 make DESTDIR=$DESTDIR install || return 1
43 sed -i '/mimelnk/d' fluid/Makefile
44 make -C fluid install-linux || return 1
46 make -C test install-linux || return 1
48 for game in blocks checkers sudoku; do
49 for file in \
50 /usr/bin/$game \
51 /usr/share/icons/hicolor/128x128/apps/$game.png \
52 /usr/share/icons/hicolor/32x32/apps/$game.png \
53 /usr/share/applications/$game.desktop; do
54 mv $install$file $install${file/$game/fltk-$game}
55 done
56 sed -i 's|Exec=|Exec=fltk-|; s|Icon=|Icon=fltk-|; /TryExec/d' \
57 $install/usr/share/applications/fltk-$game.desktop
58 done
60 install -m755 $src/test/colbrowser $install/usr/bin/fltk-colbrowser
61 install -m755 $src/test/editor $install/usr/bin/fltk-editor
62 install -Dm644 $src/test/rgb.txt $install/usr/share/fltk/rgb.txt
63 }
65 genpkg_rules() {
66 case $PACKAGE in
67 fltk-blocks)
68 copy $PACKAGE*
69 CAT="games|FLTK Blocks game"
70 DEPENDS="alsa-lib fontconfig xorg-libX11 xorg-libXcursor \
71 xorg-libXext xorg-libXfixes xorg-libXft xorg-libXinerama \
72 xorg-libXrender"
73 ;;
74 fltk-checkers)
75 copy $PACKAGE*
76 CAT="games|FLTK Checkers game"
77 DEPENDS="fontconfig xorg-libX11 xorg-libXcursor xorg-libXext \
78 xorg-libXfixes xorg-libXft xorg-libXinerama xorg-libXrender"
79 ;;
80 fltk-sudoku)
81 copy $PACKAGE*
82 CAT="games|FLTK Sudoku game"
83 DEPENDS="alsa-lib fontconfig libjpeg-turbo libpng16 xorg-libX11 \
84 xorg-libXcursor xorg-libXext xorg-libXfixes xorg-libXft \
85 xorg-libXinerama xorg-libXrender"
86 ;;
87 fltk-colbrowser)
88 copy $PACKAGE* rgb.txt
89 CAT="graphics|FLTK Color browser"
90 DEPENDS="fontconfig xorg-libX11 xorg-libXcursor xorg-libXext \
91 xorg-libXfixes xorg-libXft xorg-libXinerama xorg-libXrender"
92 ;;
93 fltk-editor)
94 copy $PACKAGE*
95 CAT="development|FLTK text editor"
96 DEPENDS="fontconfig xorg-libX11 xorg-libXcursor xorg-libXext \
97 xorg-libXfixes xorg-libXft xorg-libXinerama xorg-libXrender"
98 ;;
99 fltk-doc)
100 copy doc/
101 CAT="development|FLTK documentation and examples"
102 ;;
103 fltk)
104 copy @std @rm
105 case "$SLITAZ_ARCH" in
106 arm*)
107 DEPENDS="expat fontconfig freetype jpeg libpng16 \
108 xorg-libXft" ;;
109 *)
110 DEPENDS="fontconfig libjpeg-turbo libpng16 mesa \
111 xorg-libX11 xorg-libXcursor xorg-libXext xorg-libXfixes \
112 xorg-libXft xorg-libXinerama xorg-libXrender"
113 esac
114 ;;
115 fltk-dev)
116 copy @dev @rm # remove examples in doc
117 DEPENDS="fltk"
118 ;;
119 esac
120 }