diff options
author | Frans Meulenbroeks <fransmeulenbroeks@gmail.com> | 2009-03-19 20:56:09 +0100 |
---|---|---|
committer | Frans Meulenbroeks <fransmeulenbroeks@gmail.com> | 2009-03-19 20:56:09 +0100 |
commit | 6a21d65d2840c58cfa7cd749a04669d8f7980646 (patch) | |
tree | 00b1aa153b69cda8cf9406c4700fd7730c34d3a5 /recipes/kaffe/kaffe.inc | |
parent | dcfe7349b369a87881cf1fa43085d9e9c5609fcf (diff) | |
parent | 6f854d71c347475d53d5080a5490625345d95d12 (diff) |
Merge branch 'org.openembedded.dev' of git@git.openembedded.net:openembedded into org.openembedded.dev
Diffstat (limited to 'recipes/kaffe/kaffe.inc')
-rw-r--r-- | recipes/kaffe/kaffe.inc | 86 |
1 files changed, 86 insertions, 0 deletions
diff --git a/recipes/kaffe/kaffe.inc b/recipes/kaffe/kaffe.inc new file mode 100644 index 0000000000..7863f733c0 --- /dev/null +++ b/recipes/kaffe/kaffe.inc @@ -0,0 +1,86 @@ +DESCRIPTION = "Kaffe is a clean room implementation of the Java Virtual Machine" +HOMEPAGE = "http://www.kaffe.org/" +LICENSE = "GPL LGPL W3C Classpath BSD" + +DEPENDS = "virtual/javac-native fastjar-native libffi zip-native libart-lgpl" +RDEPENDS_${PN} = "${PN}-common (>= ${PV})" + +SRC_URI += "file://disable-automake-checks.patch;patch=1" + +inherit autotools gettext + +EXTRA_OECONF = "--with-engine=intrp \ + --with-libffi \ + --with-threads=unix-pthreads \ + --disable-alsatest \ + --disable-esdtest \ + --disable-sound \ + --with-jikes" + +CFLAGS += "-D_GNU_SOURCE" + +# kaffe installs to non-standard locations. apply a similar workaround to +# the one used in debian. i.e. override prefix +oe_runconf () { + if [ -x ${S}/configure ] ; then + cfgcmd="${S}/configure \ + --build=${BUILD_SYS} \ + --host=${HOST_SYS} \ + --target=${TARGET_SYS} \ + --prefix=${libdir}/${PN} \ + --datadir=${datadir} \ + --sysconfdir=${sysconfdir} \ + --sharedstatedir=${sharedstatedir}/${PN} \ + --includedir=${includedir} \ + --oldincludedir=${oldincludedir} \ + --infodir=${infodir} \ + --mandir=${mandir} \ + ${EXTRA_OECONF} \ + $@" + oenote "Running $cfgcmd..." + $cfgcmd || oefatal "oe_runconf failed" + else + oefatal "no configure script found" + fi +} + +do_install () { + autotools_do_install + + # move partially duplicate stuff to a single location + mv -f ${D}${libdir}/${PN}/bin/* ${D}${libdir}/${PN}/jre/bin + rmdir ${D}${libdir}/${PN}/bin + cd ${D}${libdir}/${PN} && ln -s jre/bin +} + +# use update-alternatives for the various wrapper scripts +alternative_names = "appletviewer \ +install-jar \ +jar \ +java \ +javac \ +javadoc \ +javah \ +javap \ +kaffe \ +kaffeh \ +native2ascii \ +rmic \ +rmiregistry \ +serialver" + +pkg_postinst_${PN} () { + for name in ${alternative_names}; do + update-alternatives --install ${bindir}/$name $name ${libdir}/${PN}/jre/bin/$name 300 + done +} + +pkg_postrm_${PN} () { + for name in ${alternative_names}; do + update-alternatives --remove $name ${libdir}/${PN}/jre/bin/$name + done +} + +PACKAGES =+ "${PN}-common" +FILES_${PN} += "${libdir}/${PN}" +FILES_${PN}-common = "${libdir}/${PN}/jre/lib/*.jar" |