blob: 0bf878fc969e69d4219aa7f89c25335327d90c0e [file] [log] [blame]
Patrick Williamsc124f4f2015-09-15 14:41:29 -05001SUMMARY = "Simon Tatham's Portable Puzzle Collection"
Andrew Geissler90fd73c2021-03-05 15:25:55 -06002DESCRIPTION = "Collection of small computer programs which implement one-player puzzle games."
Patrick Williamsc124f4f2015-09-15 14:41:29 -05003HOMEPAGE = "http://www.chiark.greenend.org.uk/~sgtatham/puzzles/"
Brad Bishop1a4b7ee2018-12-16 17:11:34 -08004LICENSE = "MIT"
Andrew Geissler09036742021-06-25 14:25:14 -05005LIC_FILES_CHKSUM = "file://LICENCE;md5=6e7d24cf1c949887ee9447a1e2a4a24c"
Patrick Williamsc124f4f2015-09-15 14:41:29 -05006
William A. Kennington IIIac69b482021-06-02 12:28:27 -07007# gtk support includes a bunch of x11 headers
Patrick Williamsc124f4f2015-09-15 14:41:29 -05008REQUIRED_DISTRO_FEATURES = "x11"
9
Andrew Geissler595f6302022-01-24 19:11:47 +000010SRC_URI = "git://git.tartarus.org/simon/puzzles.git;branch=main"
Brad Bishop1a4b7ee2018-12-16 17:11:34 -080011
Brad Bishop316dfdd2018-06-25 12:45:53 -040012UPSTREAM_CHECK_COMMITS = "1"
Andrew Geissler595f6302022-01-24 19:11:47 +000013SRCREV = "229d062d6ce63f0a5e00d2de62ee0fb389ccfdb6"
Brad Bishop316dfdd2018-06-25 12:45:53 -040014PE = "2"
Patrick Williamsc124f4f2015-09-15 14:41:29 -050015PV = "0.0+git${SRCPV}"
16
17S = "${WORKDIR}/git"
18
William A. Kennington IIIac69b482021-06-02 12:28:27 -070019inherit cmake features_check pkgconfig
Patrick Williamsd8c66bc2016-06-20 12:57:21 -050020
William A. Kennington IIIac69b482021-06-02 12:28:27 -070021DEPENDS += "gtk+3"
Patrick Williamsc124f4f2015-09-15 14:41:29 -050022
Patrick Williams213cb262021-08-07 19:21:33 -050023do_install:append () {
Patrick Williamsc0f7c042017-02-23 20:41:17 -060024 # net conflicts with Samba, so rename it
25 mv ${D}${bindir}/net ${D}${bindir}/puzzles-net
Patrick Williamsc124f4f2015-09-15 14:41:29 -050026
27 # Create desktop shortcuts
Patrick Williamsc0f7c042017-02-23 20:41:17 -060028 install -d ${D}/${datadir}/applications/
Patrick Williamsc124f4f2015-09-15 14:41:29 -050029 cd ${D}/${prefix}/bin
30 for prog in *; do
31 if [ -x $prog ]; then
32 # Convert prog to Title Case
Patrick Williamsc0f7c042017-02-23 20:41:17 -060033 title=$(echo $prog | sed 's/puzzles-//' | sed 's/\(^\| \)./\U&/g')
Patrick Williamsc124f4f2015-09-15 14:41:29 -050034 echo "making ${D}/${datadir}/applications/$prog.desktop"
35 cat <<STOP > ${D}/${datadir}/applications/$prog.desktop
36[Desktop Entry]
37Name=$title
Patrick Williamsc0f7c042017-02-23 20:41:17 -060038Exec=${bindir}/$prog
Patrick Williamsc124f4f2015-09-15 14:41:29 -050039Icon=applications-games
40Terminal=false
41Type=Application
42Categories=Game;
43StartupNotify=true
Patrick Williamsc124f4f2015-09-15 14:41:29 -050044STOP
45 fi
46 done
47}
Brad Bishop1a4b7ee2018-12-16 17:11:34 -080048