aboutsummaryrefslogtreecommitdiffstats
path: root/meta/classes/sdl.bbclass
diff options
context:
space:
mode:
authorRichard Purdie <richard@openedhand.com>2006-07-21 10:10:31 +0000
committerRichard Purdie <richard@openedhand.com>2006-07-21 10:10:31 +0000
commitb2f192faabe412adce79534e22efe9fb69ee40e2 (patch)
tree7076c49d4286f8a1733650bd8fbc7161af200d57 /meta/classes/sdl.bbclass
parent2cf0eadf9f730027833af802d7e6c90b44248f80 (diff)
downloadopenembedded-core-contrib-b2f192faabe412adce79534e22efe9fb69ee40e2.tar.gz
Rename /openembedded/ -> /meta/
git-svn-id: https://svn.o-hand.com/repos/poky/trunk@530 311d38ba-8fff-0310-9ca6-ca027cbcb966
Diffstat (limited to 'meta/classes/sdl.bbclass')
-rw-r--r--meta/classes/sdl.bbclass44
1 files changed, 44 insertions, 0 deletions
diff --git a/meta/classes/sdl.bbclass b/meta/classes/sdl.bbclass
new file mode 100644
index 0000000000..c0b21427a4
--- /dev/null
+++ b/meta/classes/sdl.bbclass
@@ -0,0 +1,44 @@
+#
+# (C) Michael 'Mickey' Lauer <mickey@Vanille.de>
+#
+
+DEPENDS += "virtual/libsdl libsdl-mixer libsdl-image"
+
+APPDESKTOP ?= "${PN}.desktop"
+APPNAME ?= "${PN}"
+APPIMAGE ?= "${PN}.png"
+
+sdl_do_sdl_install() {
+ install -d ${D}${palmtopdir}/bin
+ install -d ${D}${palmtopdir}/pics
+ install -d ${D}${palmtopdir}/apps/Games
+ ln -sf ${bindir}/${APPNAME} ${D}${palmtopdir}/bin/${APPNAME}
+ install -m 0644 ${APPIMAGE} ${D}${palmtopdir}/pics/${PN}.png
+
+ if [ -e "${APPDESKTOP}" ]
+ then
+ echo ${APPDESKTOP} present, installing to palmtopdir...
+ install -m 0644 ${APPDESKTOP} ${D}${palmtopdir}/apps/Games/${PN}.desktop
+ else
+ echo ${APPDESKTOP} not present, creating one on-the-fly...
+ cat >${D}${palmtopdir}/apps/Games/${PN}.desktop <<EOF
+[Desktop Entry]
+Note=Auto Generated... this may be not what you want
+Comment=${DESCRIPTION}
+Exec=${APPNAME}
+Icon=${APPIMAGE}
+Type=Application
+Name=${PN}
+EOF
+ fi
+}
+
+EXPORT_FUNCTIONS do_sdl_install
+addtask sdl_install after do_compile before do_populate_staging
+
+SECTION = "x11/games"
+SECTION_${PN}-opie = "opie/games"
+
+PACKAGES += "${PN}-opie"
+RDEPENDS_${PN}-opie += "${PN}"
+FILES_${PN}-opie = "${palmtopdir}"