diff options
Diffstat (limited to 'meta/packages/puzzles/puzzles_r6915.bb')
-rw-r--r-- | meta/packages/puzzles/puzzles_r6915.bb | 47 |
1 files changed, 47 insertions, 0 deletions
diff --git a/meta/packages/puzzles/puzzles_r6915.bb b/meta/packages/puzzles/puzzles_r6915.bb new file mode 100644 index 0000000000..f8ffcb7d01 --- /dev/null +++ b/meta/packages/puzzles/puzzles_r6915.bb | |||
@@ -0,0 +1,47 @@ | |||
1 | |||
2 | DEPENDS = "gtk+" | ||
3 | PR = "r2" | ||
4 | |||
5 | SRC_URI = "http://www.chiark.greenend.org.uk/~sgtatham/puzzles/puzzles-${PV}.tar.gz \ | ||
6 | file://game.png" | ||
7 | |||
8 | do_compile_prepend = " \ | ||
9 | export XLDFLAGS='${LDFLAGS} `${STAGING_BINDIR}/pkg-config gtk+-2.0 --libs`'; \ | ||
10 | export CFLAGS='${CFLAGS} -I./ `${STAGING_BINDIR}/pkg-config gtk+-2.0 --cflags`'; " | ||
11 | |||
12 | FILES_${PN} = "${prefix}/games/* ${datadir}/applications/* ${datadir}/pixmaps" | ||
13 | FILES_${PN}-dbg += "${prefix}/games/.debug" | ||
14 | |||
15 | do_install () { | ||
16 | rm -rf ${D}/* | ||
17 | export prefix=${D} | ||
18 | export DESTDIR=${D} | ||
19 | install -d ${D}/${prefix}/ | ||
20 | install -d ${D}/${prefix}/games/ | ||
21 | oe_runmake install | ||
22 | |||
23 | install -d ${D}/${datadir}/ | ||
24 | install -d ${D}/${datadir}/applications/ | ||
25 | install -d ${D}/${datadir}/pixmaps/ | ||
26 | |||
27 | install ${WORKDIR}/game.png ${D}/${datadir}/pixmaps/ | ||
28 | |||
29 | cd ${D}/${prefix}/games | ||
30 | for prog in *; do | ||
31 | if [ -x $prog ]; then | ||
32 | echo "making ${D}/${datadir}/applications/$prog.desktop" | ||
33 | cat <<STOP > ${D}/${datadir}/applications/$prog.desktop | ||
34 | [Desktop Entry] | ||
35 | Encoding=UTF-8 | ||
36 | Name=$prog | ||
37 | Exec=${prefix}/games/$prog | ||
38 | Icon=game.png | ||
39 | Terminal=false | ||
40 | Type=Application | ||
41 | Categories=Game | ||
42 | StartupNotify=true | ||
43 | SingleInstance=true | ||
44 | STOP | ||
45 | fi | ||
46 | done | ||
47 | } | ||