diff options
author | Otavio Salvador <otavio@ossystems.com.br> | 2009-10-07 19:29:36 -0300 |
---|---|---|
committer | Otavio Salvador <otavio@ossystems.com.br> | 2009-10-29 20:43:50 -0200 |
commit | 7afc325ab1fac79e1eaba65383bfed12d705d7bc (patch) | |
tree | 9a238963ef0aa1001d4832ad261850e827d3e9d4 /recipes/chicken | |
parent | bbe9ae502bf711a30197ddf26dd91bc91f4cf421 (diff) |
chicken: revamp recipes
To allow easy usage of chicken, in embedded environments, we have done
some refactoring in the packages:
- split it up to chicken, libchicken and libuchickenl
- drop 2.6 version since no distro depends on that and is not
commonly used anymore;
- generalize .inc file to be usable for 3.x and 4.x versions;
- add new 4.2.0 release,
- use INC_PR.
Signed-off-by: Otavio Salvador <otavio@ossystems.com.br>
Diffstat (limited to 'recipes/chicken')
-rw-r--r-- | recipes/chicken/chicken.inc | 71 | ||||
-rw-r--r-- | recipes/chicken/chicken2.inc | 19 | ||||
-rw-r--r-- | recipes/chicken/chicken3.inc | 36 | ||||
-rw-r--r-- | recipes/chicken/chicken_2.6.bb | 1 | ||||
-rw-r--r-- | recipes/chicken/chicken_3.3.0.bb | 4 | ||||
-rw-r--r-- | recipes/chicken/chicken_4.2.0.bb | 3 |
6 files changed, 77 insertions, 57 deletions
diff --git a/recipes/chicken/chicken.inc b/recipes/chicken/chicken.inc new file mode 100644 index 0000000000..ff8da65683 --- /dev/null +++ b/recipes/chicken/chicken.inc @@ -0,0 +1,71 @@ +ESCRIPTION = "A compiler that translates Scheme source files to C, and an interpreter" +HOMEPAGE = "http://www.call-with-current-continuation.org/" +SECTION = "interpreters" +PRIORITY = "optional" +LICENSE = "BSD" +INC_PR = "r1" + +SRC_URI = "http://chicken.wiki.br/releases/${PV}/chicken-${PV}.tar.gz" + +inherit autotools + +# Parallel building is not supported +PARALLEL_MAKE = "" + +# Required environment values +export PLATFORM="linux" +export PREFIX="${prefix}" +export C_COMPILER="${TARGET_PREFIX}gcc ${LDFLAGS} " +export LIBRARIAN="${TARGET_PREIX}ar " +export TARGETSYSTEM="${TARGET_SYS}" + +SONAME = "${@bb.data.getVar("PV", d, 1)[0]}" +ASSUME_SHLIBS += "libchicken.so.${SONAME}:libchicken libuchicken.so.${SONAME}:libuchicken" + +do_compile() { + case ${TARGET_ARCH} in + i*86) + ARCH=x86 + ;; + *) + echo "Check ARCH value for ${TARGET_ARCH}" + exit 1 + ;; + esac + + make ARCH=${ARCH} +} + +do_install() { + case ${TARGET_ARCH} in + i*86) + ARCH=x86 + ;; + *) + echo "Check ARCH value for ${TARGET_ARCH}" + exit 1 + ;; + esac + + make ARCH=${ARCH} DESTDIR=${D} install +} + +do_install_append() { + # Handle lacking of soname is some versions + if [ ! -e ${D}${libdir}/libchicken.so.${SONAME} ]; then + (cd ${D}${libdir} + mv libchicken.so libchicken.so.${SONAME} + ln -s libchicken.so.${SONAME} libchicken.so + mv libuchicken.so libuchicken.so.${SONAME} + ln -s libuchicken.so.${SONAME} libuchicken.so) + fi +} + +PACKAGES += "chicken-bin libchicken libuchicken" + +FILES_${PN} = "" +FILES_libchicken = "${libdir}/libchicken.so.${SONAME}" +FILES_libuchicken = "${libdir}/libuchicken.so.${SONAME}*" +FILES_${PN}-bin = "${bindir}/* ${datadir}/chicken/*.* ${libdir}/chicken/${SONAME}/*.so" +FILES_${PN}-doc += "${datadir}/chicken/doc" +FILES_${PN}-dbg += "${libdir}/chicken/*/.debug" diff --git a/recipes/chicken/chicken2.inc b/recipes/chicken/chicken2.inc deleted file mode 100644 index fbaf971f88..0000000000 --- a/recipes/chicken/chicken2.inc +++ /dev/null @@ -1,19 +0,0 @@ -DESCRIPTION = "A compiler that translates Scheme source files to C, and an interpreter" -HOMEPAGE = "http://www.call-with-current-continuation.org/" -SECTION = "interpreters" -PRIORITY = "optional" -LICENSE = "BSD" - -SRC_URI = "http://www.call-with-current-continuation.org/chicken-${PV}.tar.gz" - -inherit autotools - -do_install_append() { - install -d ${D}${docdir}/${P} - mv ${D}/${datadir}/chicken/doc ${D}${docdir}/${P} -} - -do_stage() { - autotools_stage_all -} - diff --git a/recipes/chicken/chicken3.inc b/recipes/chicken/chicken3.inc deleted file mode 100644 index 2feebfb48a..0000000000 --- a/recipes/chicken/chicken3.inc +++ /dev/null @@ -1,36 +0,0 @@ -DESCRIPTION = "A compiler that translates Scheme source files to C, and an interpreter" -HOMEPAGE = "http://www.call-with-current-continuation.org/" -SECTION = "interpreters" -PRIORITY = "optional" -LICENSE = "BSD" - -SRC_URI = "http://chicken.wiki.br/releases/${PV}/chicken-${PV}.tar.gz" - -inherit autotools - -do_compile() { - export PLATFORM=linux - export PREFIX=${prefix} - export HOST=${TARGET_ARCH}-${DISTRO}-${TARGET_OS} - export C_COMPILER=${HOST}-gcc - export LIBRARIAN=${HOST}-ar - # ARCH= is weird... but it's not enough to export this variable. - # If ARCH is not set to empty-string, then the Makefile will try to - # use the apply-hack.s file applicable to the machine doing the compiling. - # There is no such apply-hack assembler code for arm, at least not yet. - make ARCH= -} - -do_install() { - export PLATFORM=linux - export PREFIX=${prefix} - export HOST=${TARGET_ARCH}-${DISTRO}-${TARGET_OS} - export C_COMPILER=${HOST}-gcc - export LIBRARIAN=${HOST}-ar - make ARCH= DESTDIR=${D} install -} - -FILES_${PN} = "${bindir}/csi ${bindir}/chicken-bug" -FILES_${PN} += "${libdir}/lib*.so.* ${libdir}/chicken" -FILES_${PN} += "${datadir}/chicken/*.*" -FILES_${PN}-dev += "${bindir}" diff --git a/recipes/chicken/chicken_2.6.bb b/recipes/chicken/chicken_2.6.bb deleted file mode 100644 index 934ef4a218..0000000000 --- a/recipes/chicken/chicken_2.6.bb +++ /dev/null @@ -1 +0,0 @@ -require chicken2.inc diff --git a/recipes/chicken/chicken_3.3.0.bb b/recipes/chicken/chicken_3.3.0.bb index 7d9fc69419..c61d655ab5 100644 --- a/recipes/chicken/chicken_3.3.0.bb +++ b/recipes/chicken/chicken_3.3.0.bb @@ -1 +1,3 @@ -require chicken3.inc +require chicken.inc + +PR = "${INC_PR}.1" diff --git a/recipes/chicken/chicken_4.2.0.bb b/recipes/chicken/chicken_4.2.0.bb new file mode 100644 index 0000000000..c61d655ab5 --- /dev/null +++ b/recipes/chicken/chicken_4.2.0.bb @@ -0,0 +1,3 @@ +require chicken.inc + +PR = "${INC_PR}.1" |