aboutsummaryrefslogtreecommitdiffstats
path: root/classes/sdl.bbclass
diff options
context:
space:
mode:
authorPaul Eggleton <paul.eggleton@linux.intel.com>2011-07-24 17:57:24 +0100
committerPaul Eggleton <paul.eggleton@linux.intel.com>2011-07-30 02:35:12 +0100
commite9b45ff67d32fdc27950a51135b6dabada8334e7 (patch)
treede99cd760c8292ee1dd334e23e1e5cc43e90dfbd /classes/sdl.bbclass
downloadmeta-opie-e9b45ff67d32fdc27950a51135b6dabada8334e7.tar.gz
meta-opie-e9b45ff67d32fdc27950a51135b6dabada8334e7.tar.bz2
meta-opie-e9b45ff67d32fdc27950a51135b6dabada8334e7.zip
initial commit of meta-opie
Populate the repository with files from OpenEmbedded at revision 45edf621296daf150c72b876d720861235e5762e - no changes, only rearranged the directory structure to match the new oe-core style and added COPYING.MIT and README. Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com>
Diffstat (limited to 'classes/sdl.bbclass')
-rw-r--r--classes/sdl.bbclass46
1 files changed, 46 insertions, 0 deletions
diff --git a/classes/sdl.bbclass b/classes/sdl.bbclass
new file mode 100644
index 0000000..dc4cd8f
--- /dev/null
+++ b/classes/sdl.bbclass
@@ -0,0 +1,46 @@
+#
+# (C) Michael 'Mickey' Lauer <mickey@Vanille.de>
+#
+
+DEPENDS += "virtual/libsdl libsdl-mixer libsdl-image"
+
+APPDESKTOP ?= "${WORKDIR}/${PN}.desktop"
+APPNAME ?= "${PN}"
+APPIMAGE ?= "${WORKDIR}/${PN}.png"
+
+export SDL_CONFIG = "${STAGING_BINDIR_CROSS}/sdl-config"
+
+sdl_do_sdl_install() {
+ install -d ${D}${datadir}/applications
+ install -d ${D}${datadir}/pixmaps
+
+ install -m 0644 ${APPIMAGE} ${D}${datadir}/pixmaps/${PN}.png
+
+ if [ -e "${APPDESKTOP}" ]
+ then
+ echo ${APPDESKTOP} present, using it...
+ install -m 0644 ${APPDESKTOP} ${D}${datadir}/applications/
+ else
+ echo ${APPDESKTOP} not present, creating one on-the-fly...
+ cat >${D}${datadir}/applications/${PN}.desktop <<EOF
+[Desktop Entry]
+Name=${PN}
+Comment=${DESCRIPTION}
+Note=Auto Generated by OE SDL bbclass
+Exec=${APPNAME}
+Icon=${PN}.png
+Type=Application
+Categories=Games
+EOF
+ fi
+}
+
+EXPORT_FUNCTIONS do_sdl_install
+addtask sdl_install after do_install before do_package
+
+#SECTION = "x11/games"
+#SECTION_${PN}-opie = "opie/games"
+
+#PACKAGES += "${PN}-opie"
+#RDEPENDS_${PN}-opie += "${PN}"
+#FILES_${PN}-opie = "${palmtopdir}"