From 972dcfcdbfe75dcfeb777150c136576cf1a71e99 Mon Sep 17 00:00:00 2001 From: Tudor Florea Date: Fri, 9 Oct 2015 22:59:03 +0200 Subject: initial commit for Enea Linux 5.0 arm Signed-off-by: Tudor Florea --- meta/recipes-support/apr/apr-util/configfix.patch | 51 ++++++++++++ .../apr/apr-util/configure_fixes.patch | 31 +++++++ meta/recipes-support/apr/apr-util/run-ptest | 6 ++ meta/recipes-support/apr/apr-util_1.5.3.bb | 67 +++++++++++++++ meta/recipes-support/apr/apr/cleanup.patch | 43 ++++++++++ meta/recipes-support/apr/apr/configfix.patch | 53 ++++++++++++ meta/recipes-support/apr/apr/configure_fixes.patch | 68 ++++++++++++++++ meta/recipes-support/apr/apr/run-ptest | 6 ++ .../apr/apr/upgrade-and-fix-1.5.1.patch | 48 +++++++++++ meta/recipes-support/apr/apr_1.5.1.bb | 95 ++++++++++++++++++++++ 10 files changed, 468 insertions(+) create mode 100644 meta/recipes-support/apr/apr-util/configfix.patch create mode 100644 meta/recipes-support/apr/apr-util/configure_fixes.patch create mode 100644 meta/recipes-support/apr/apr-util/run-ptest create mode 100644 meta/recipes-support/apr/apr-util_1.5.3.bb create mode 100644 meta/recipes-support/apr/apr/cleanup.patch create mode 100644 meta/recipes-support/apr/apr/configfix.patch create mode 100644 meta/recipes-support/apr/apr/configure_fixes.patch create mode 100644 meta/recipes-support/apr/apr/run-ptest create mode 100644 meta/recipes-support/apr/apr/upgrade-and-fix-1.5.1.patch create mode 100644 meta/recipes-support/apr/apr_1.5.1.bb (limited to 'meta/recipes-support/apr') diff --git a/meta/recipes-support/apr/apr-util/configfix.patch b/meta/recipes-support/apr/apr-util/configfix.patch new file mode 100644 index 0000000000..dbb1148809 --- /dev/null +++ b/meta/recipes-support/apr/apr-util/configfix.patch @@ -0,0 +1,51 @@ +Upstream-Status: Inappropriate [configuration] + +Index: apr-util-1.3.4/apu-config.in +=================================================================== +--- apr-util-1.3.4.orig/apu-config.in 2009-01-12 17:08:06.000000000 +0000 ++++ apr-util-1.3.4/apu-config.in 2009-01-12 17:09:00.000000000 +0000 +@@ -134,14 +134,7 @@ + exit 0 + ;; + --includes) +- if test "$location" = "installed"; then + flags="$flags -I$includedir $INCLUDES" +- elif test "$location" = "source"; then +- flags="$flags -I$APU_SOURCE_DIR/include $INCLUDES" +- else +- # this is for VPATH builds +- flags="$flags -I$APU_BUILD_DIR/include -I$APU_SOURCE_DIR/include $INCLUDES" +- fi + ;; + --ldflags) + flags="$flags $LDFLAGS" +@@ -155,28 +148,10 @@ + exit 0 + ;; + --link-ld) +- if test "$location" = "installed"; then +- ### avoid using -L if libdir is a "standard" location like /usr/lib + flags="$flags -L$libdir -l$APRUTIL_LIBNAME" +- else +- flags="$flags -L$APU_BUILD_DIR -l$APRUTIL_LIBNAME" +- fi + ;; + --link-libtool) +- # If the LA_FILE exists where we think it should be, use it. If we're +- # installed and the LA_FILE does not exist, assume to use -L/-l +- # (the LA_FILE may not have been installed). If we're building ourselves, +- # we'll assume that at some point the .la file be created. +- if test -f "$LA_FILE"; then +- flags="$flags $LA_FILE" +- elif test "$location" = "installed"; then +- ### avoid using -L if libdir is a "standard" location like /usr/lib +- # Since the user is specifying they are linking with libtool, we +- # *know* that -R will be recognized by libtool. +- flags="$flags -L$libdir -R$libdir -l$APRUTIL_LIBNAME" +- else +- flags="$flags $LA_FILE" +- fi ++ flags="$flags -l$APRUTIL_LIBNAME" + ;; + --apu-la-file) + if test -f "$LA_FILE"; then diff --git a/meta/recipes-support/apr/apr-util/configure_fixes.patch b/meta/recipes-support/apr/apr-util/configure_fixes.patch new file mode 100644 index 0000000000..91e244ce2c --- /dev/null +++ b/meta/recipes-support/apr/apr-util/configure_fixes.patch @@ -0,0 +1,31 @@ +Upstream-Status: Inappropriate [configuration] + +Index: apr-util-1.4.1/configure.in +=================================================================== +--- apr-util-1.4.1.orig/configure.in 2009-12-18 03:15:19.000000000 +0800 ++++ apr-util-1.4.1/configure.in 2011-12-30 13:32:07.000000000 +0800 +@@ -8,15 +8,15 @@ + AC_CONFIG_HEADER(include/private/apu_config.h) + AC_CONFIG_AUX_DIR(build) + +-sinclude(build/apu-conf.m4) +-sinclude(build/apu-iconv.m4) +-sinclude(build/apu-hints.m4) +-sinclude(build/apr_common.m4) +-sinclude(build/find_apr.m4) +-sinclude(build/crypto.m4) +-sinclude(build/dbm.m4) +-sinclude(build/dbd.m4) +-sinclude(build/dso.m4) ++#sinclude(build/apu-conf.m4) ++#sinclude(build/apu-iconv.m4) ++#sinclude(build/apu-hints.m4) ++#sinclude(build/apr_common.m4) ++#sinclude(build/find_apr.m4) ++#sinclude(build/crypto.m4) ++#sinclude(build/dbm.m4) ++#sinclude(build/dbd.m4) ++#sinclude(build/dso.m4) + + dnl Generate ./config.nice for reproducing runs of configure + dnl diff --git a/meta/recipes-support/apr/apr-util/run-ptest b/meta/recipes-support/apr/apr-util/run-ptest new file mode 100644 index 0000000000..ae19a1d11b --- /dev/null +++ b/meta/recipes-support/apr/apr-util/run-ptest @@ -0,0 +1,6 @@ +#!/bin/sh + +cd test +./testall |sed \ + -e 's|\(.*\): SUCCESS|PASS: \1|' \ + -e 's|\(.*\): FAILED|FAIL: \1|' diff --git a/meta/recipes-support/apr/apr-util_1.5.3.bb b/meta/recipes-support/apr/apr-util_1.5.3.bb new file mode 100644 index 0000000000..063a787396 --- /dev/null +++ b/meta/recipes-support/apr/apr-util_1.5.3.bb @@ -0,0 +1,67 @@ +SUMMARY = "Apache Portable Runtime (APR) companion library" +HOMEPAGE = "http://apr.apache.org/" +SECTION = "libs" +DEPENDS = "apr expat gdbm" + +BBCLASSEXTEND = "native" + +LICENSE = "Apache-2.0" +LIC_FILES_CHKSUM = "file://LICENSE;md5=519e0a18e03f7c023070568c14b077bb \ + file://include/apu_version.h;endline=17;md5=806685a84e71f10c80144c48eb35df42" + +SRC_URI = "${APACHE_MIRROR}/apr/${BPN}-${PV}.tar.gz \ + file://configfix.patch \ + file://configure_fixes.patch \ + file://run-ptest \ +" + +SRC_URI[md5sum] = "71a11d037240b292f824ba1eb537b4e3" +SRC_URI[sha256sum] = "76db34cb508e346e3bf69347c29ed1500bf0b71bcc48d54271ad9d1c25703743" + +EXTRA_OECONF = "--with-apr=${STAGING_BINDIR_CROSS}/apr-1-config \ + --without-odbc \ + --without-pgsql \ + --with-dbm=gdbm \ + --with-gdbm=${STAGING_DIR_HOST}${prefix} \ + --without-sqlite2 \ + --without-sqlite3 \ + --with-expat=${STAGING_DIR_HOST}${prefix}" + + +inherit autotools-brokensep lib_package binconfig + +OE_BINCONFIG_EXTRA_MANGLE = " -e 's:location=source:location=installed:'" + +do_configure_append() { + if [ "${CLASSOVERRIDE}" = "class-target" ]; then + cp ${STAGING_DATADIR}/apr/apr_rules.mk ${S}/build/rules.mk + fi +} +do_configure_prepend_class-native() { + cp ${STAGING_DATADIR_NATIVE}/apr/apr_rules.mk ${S}/build/rules.mk +} +do_configure_append_class-native() { + sed -i "s#LIBTOOL=\$(SHELL) \$(apr_builddir)#LIBTOOL=\$(SHELL) ${STAGING_BINDIR_NATIVE}#" ${S}/build/rules.mk + # sometimes there isn't SHELL + sed -i "s#LIBTOOL=\$(apr_builddir)#LIBTOOL=${STAGING_BINDIR_NATIVE}#" ${S}/build/rules.mk +} + +FILES_${PN} += "${libdir}/apr-util-1/apr_dbm_gdbm-1.so" +FILES_${PN}-dev += "${libdir}/aprutil.exp ${libdir}/apr-util-1/apr_dbm_gdbm.so* ${libdir}/apr-util-1/apr_dbm_gdbm.la" +FILES_${PN}-dbg += "${libdir}/apr-util-1/.debug/*" +FILES_${PN}-staticdev += "${libdir}/apr-util-1/apr_dbm_gdbm.a" + +inherit ptest + +do_compile_ptest() { + cd ${S}/test + oe_runmake +} + +do_install_ptest() { + t=${D}${PTEST_PATH}/test + mkdir $t + for i in testall data; do \ + cp -r ${S}/test/$i $t; \ + done +} diff --git a/meta/recipes-support/apr/apr/cleanup.patch b/meta/recipes-support/apr/apr/cleanup.patch new file mode 100644 index 0000000000..b6784e015d --- /dev/null +++ b/meta/recipes-support/apr/apr/cleanup.patch @@ -0,0 +1,43 @@ +Upstream-Status: Inappropriate [configuration] + +Index: apr-1.4.2/build/buildcheck.sh +=================================================================== +--- apr-1.4.2.orig/build/buildcheck.sh 2009-11-13 08:27:16.000000000 +0800 ++++ apr-1.4.2/build/buildcheck.sh 2010-11-26 15:44:00.000000000 +0800 +@@ -32,35 +32,4 @@ + echo "buildconf: autoconf version $ac_version (ok)" + fi + +-# Sample libtool --version outputs: +-# ltmain.sh (GNU libtool) 1.3.3 (1.385.2.181 1999/07/02 15:49:11) +-# ltmain.sh (GNU libtool 1.1361 2004/01/02 23:10:52) 1.5a +-# output is multiline from 1.5 onwards +- +-# Require libtool 1.4 or newer +-libtool=`build/PrintPath glibtool1 glibtool libtool libtool15 libtool14` +-lt_pversion=`$libtool --version 2>/dev/null|sed -e 's/([^)]*)//g;s/^[^0-9]*//;s/[- ].*//g;q'` +-if test -z "$lt_pversion"; then +-echo "buildconf: libtool not found." +-echo " You need libtool version 1.4 or newer installed" +-echo " to build APR from SVN." +-exit 1 +-fi +-lt_version=`echo $lt_pversion|sed -e 's/\([a-z]*\)$/.\1/'` +-IFS=.; set $lt_version; IFS=' ' +-lt_status="good" +-if test "$1" = "1"; then +- if test "$2" -lt "4"; then +- lt_status="bad" +- fi +-fi +-if test $lt_status = "good"; then +- echo "buildconf: libtool version $lt_pversion (ok)" +- exit 0 +-fi +- +-echo "buildconf: libtool version $lt_pversion found." +-echo " You need libtool version 1.4 or newer installed" +-echo " to build APR from SVN." +- +-exit 1 ++exit 0 diff --git a/meta/recipes-support/apr/apr/configfix.patch b/meta/recipes-support/apr/apr/configfix.patch new file mode 100644 index 0000000000..605c4f632c --- /dev/null +++ b/meta/recipes-support/apr/apr/configfix.patch @@ -0,0 +1,53 @@ +Upstream-Status: Inappropriate [configuration] + +Index: apr-1.3.3/apr-config.in +=================================================================== +--- apr-1.3.3.orig/apr-config.in 2009-01-12 15:16:31.000000000 +0000 ++++ apr-1.3.3/apr-config.in 2009-01-12 15:19:25.000000000 +0000 +@@ -152,14 +152,7 @@ + flags="$flags $LDFLAGS" + ;; + --includes) +- if test "$location" = "installed"; then + flags="$flags -I$includedir $EXTRA_INCLUDES" +- elif test "$location" = "source"; then +- flags="$flags -I$APR_SOURCE_DIR/include $EXTRA_INCLUDES" +- else +- # this is for VPATH builds +- flags="$flags -I$APR_BUILD_DIR/include -I$APR_SOURCE_DIR/include $EXTRA_INCLUDES" +- fi + ;; + --srcdir) + echo $APR_SOURCE_DIR +@@ -181,29 +167,14 @@ + exit 0 + ;; + --link-ld) +- if test "$location" = "installed"; then +- ### avoid using -L if libdir is a "standard" location like /usr/lib +- flags="$flags -L$libdir -l${APR_LIBNAME}" +- else +- ### this surely can't work since the library is in .libs? +- flags="$flags -L$APR_BUILD_DIR -l${APR_LIBNAME}" +- fi ++ flags="$flags -l${APR_LIBNAME}" + ;; + --link-libtool) + # If the LA_FILE exists where we think it should be, use it. If we're + # installed and the LA_FILE does not exist, assume to use -L/-l + # (the LA_FILE may not have been installed). If we're building ourselves, + # we'll assume that at some point the .la file be created. +- if test -f "$LA_FILE"; then +- flags="$flags $LA_FILE" +- elif test "$location" = "installed"; then +- ### avoid using -L if libdir is a "standard" location like /usr/lib +- # Since the user is specifying they are linking with libtool, we +- # *know* that -R will be recognized by libtool. +- flags="$flags -L$libdir -R$libdir -l${APR_LIBNAME}" +- else +- flags="$flags $LA_FILE" +- fi ++ flags="$flags -l${APR_LIBNAME}" + ;; + --shlib-path-var) + echo "$SHLIBPATH_VAR" diff --git a/meta/recipes-support/apr/apr/configure_fixes.patch b/meta/recipes-support/apr/apr/configure_fixes.patch new file mode 100644 index 0000000000..0514000599 --- /dev/null +++ b/meta/recipes-support/apr/apr/configure_fixes.patch @@ -0,0 +1,68 @@ +Upstream-Status: Inappropriate [configuration] + +Index: apr-1.3.3/configure.in +=================================================================== +--- apr-1.3.3.orig/configure.in ++++ apr-1.3.3/configure.in +@@ -794,39 +794,6 @@ AC_CHECK_FUNCS([mmap munmap shm_open shm + create_area]) + + APR_CHECK_DEFINE(MAP_ANON, sys/mman.h) +-AC_CHECK_FILE(/dev/zero) +- +-# Not all systems can mmap /dev/zero (such as HP-UX). Check for that. +-if test "$ac_cv_func_mmap" = "yes" && +- test "$ac_cv_file__dev_zero" = "yes"; then +- AC_MSG_CHECKING(for mmap that can map /dev/zero) +- AC_TRY_RUN([ +-#include +-#include +-#include +-#ifdef HAVE_SYS_MMAN_H +-#include +-#endif +- int main() +- { +- int fd; +- void *m; +- fd = open("/dev/zero", O_RDWR); +- if (fd < 0) { +- return 1; +- } +- m = mmap(0, sizeof(void*), PROT_READ|PROT_WRITE, MAP_SHARED, fd, 0); +- if (m == (void *)-1) { /* aka MAP_FAILED */ +- return 2; +- } +- if (munmap(m, sizeof(void*)) < 0) { +- return 3; +- } +- return 0; +- }], [], [ac_cv_file__dev_zero=no], [ac_cv_file__dev_zero=no]) +- +- AC_MSG_RESULT($ac_cv_file__dev_zero) +-fi + + # Now we determine which one is our anonymous shmem preference. + haveshmgetanon="0" +@@ -1518,13 +1485,14 @@ else + bigendian=0 + fi + +-APR_CHECK_SIZEOF_EXTENDED([#include +-#include ],struct iovec,0) +-if test "$ac_cv_sizeof_struct_iovec" = "0"; then +- have_iovec=0 +-else +- have_iovec=1 +-fi ++#APR_CHECK_SIZEOF_EXTENDED([#include ++##include ],struct iovec,0) ++#if test "$ac_cv_sizeof_struct_iovec" = "0"; then ++# have_iovec=0 ++#else ++# have_iovec=1 ++#fi ++have_iovec=1 + + AC_SUBST(voidp_size) + AC_SUBST(short_value) diff --git a/meta/recipes-support/apr/apr/run-ptest b/meta/recipes-support/apr/apr/run-ptest new file mode 100644 index 0000000000..ae19a1d11b --- /dev/null +++ b/meta/recipes-support/apr/apr/run-ptest @@ -0,0 +1,6 @@ +#!/bin/sh + +cd test +./testall |sed \ + -e 's|\(.*\): SUCCESS|PASS: \1|' \ + -e 's|\(.*\): FAILED|FAIL: \1|' diff --git a/meta/recipes-support/apr/apr/upgrade-and-fix-1.5.1.patch b/meta/recipes-support/apr/apr/upgrade-and-fix-1.5.1.patch new file mode 100644 index 0000000000..4bca38494b --- /dev/null +++ b/meta/recipes-support/apr/apr/upgrade-and-fix-1.5.1.patch @@ -0,0 +1,48 @@ +Makefile.in: fix cross compiling failed + +The tools/gen_test_char was invoked at build time, +and it didn't work for the cross compiling, so we +compile it with $BUILD_CC. + +Remove the 'tools' dir creation, it always existed. +And it caused gen_test_char unexpected rebuilt at +do_install time. + +Upstream-Status: inappropriate [oe specific] + +Signed-off-by: Hongxu Jia +--- + Makefile.in | 10 ++-------- + 1 file changed, 2 insertions(+), 8 deletions(-) + +diff --git a/Makefile.in b/Makefile.in +index 6f99733..5fe028f 100644 +--- a/Makefile.in ++++ b/Makefile.in +@@ -46,7 +46,6 @@ LT_VERSION = @LT_VERSION@ + + CLEAN_TARGETS = apr-config.out apr.exp exports.c export_vars.c .make.dirs \ + build/apr_rules.out tools/gen_test_char@EXEEXT@ \ +- tools/gen_test_char.o tools/gen_test_char.lo \ + include/private/apr_escape_test_char.h + DISTCLEAN_TARGETS = config.cache config.log config.status \ + include/apr.h include/arch/unix/apr_private.h \ +@@ -129,13 +128,8 @@ check: $(TARGET_LIB) + etags: + etags `find . -name '*.[ch]'` + +-make_tools_dir: +- $(APR_MKDIR) tools +- +-OBJECTS_gen_test_char = tools/gen_test_char.lo $(LOCAL_LIBS) +-tools/gen_test_char.lo: make_tools_dir +-tools/gen_test_char@EXEEXT@: $(OBJECTS_gen_test_char) +- $(LINK_PROG) $(OBJECTS_gen_test_char) $(ALL_LIBS) ++tools/gen_test_char@EXEEXT@: tools/gen_test_char.c ++ $(BUILD_CC) $(CFLAGS_FOR_BUILD) $< -o $@ + + include/private/apr_escape_test_char.h: tools/gen_test_char@EXEEXT@ + $(APR_MKDIR) include/private +-- +1.8.1.2 + diff --git a/meta/recipes-support/apr/apr_1.5.1.bb b/meta/recipes-support/apr/apr_1.5.1.bb new file mode 100644 index 0000000000..a27b2338d1 --- /dev/null +++ b/meta/recipes-support/apr/apr_1.5.1.bb @@ -0,0 +1,95 @@ +SUMMARY = "Apache Portable Runtime (APR) library" +HOMEPAGE = "http://apr.apache.org/" +SECTION = "libs" +DEPENDS = "util-linux" + +LICENSE = "Apache-2.0" +LIC_FILES_CHKSUM = "file://LICENSE;md5=4dfd4cd216828c8cae5de5a12f3844c8 \ + file://include/apr_lib.h;endline=17;md5=ee42fa7575dc40580a9e01c1b75fae96" + +BBCLASSEXTEND = "native" + +SRC_URI = "${APACHE_MIRROR}/apr/${BPN}-${PV}.tar.bz2 \ + file://configure_fixes.patch \ + file://cleanup.patch \ + file://configfix.patch \ + file://run-ptest \ + file://upgrade-and-fix-1.5.1.patch \ +" + +SRC_URI[md5sum] = "5486180ec5a23efb5cae6d4292b300ab" +SRC_URI[sha256sum] = "e94abe431d4da48425fcccdb27b469bd0f8151488f82e5630a56f26590e198ac" + +inherit autotools-brokensep lib_package binconfig multilib_header ptest + +OE_BINCONFIG_EXTRA_MANGLE = " -e 's:location=source:location=installed:'" + +# Added to fix some issues with cmake. Refer to https://github.com/bmwcarit/meta-ros/issues/68#issuecomment-19896928 +CACHED_CONFIGUREVARS += "apr_cv_mutex_recursive=yes" + +# Also suppress trying to use sctp. +# +CACHED_CONFIGUREVARS += "ac_cv_header_netinet_sctp_h=no ac_cv_header_netinet_sctp_uio_h=no" + +do_configure_prepend() { + # Avoid absolute paths for grep since it causes failures + # when using sstate between different hosts with different + # install paths for grep. + export GREP="grep" + + cd ${S} + ./buildconf +} + +FILES_${PN}-dev += "${libdir}/apr.exp ${datadir}/build-1/*" +RDEPENDS_${PN}-dev += "bash" + +#for some reason, build/libtool.m4 handled by buildconf still be overwritten +#when autoconf, so handle it again. +do_configure_append() { + sed -i -e 's/LIBTOOL=\(.*\)top_build/LIBTOOL=\1apr_build/' ${S}/build/libtool.m4 + sed -i -e 's/LIBTOOL=\(.*\)top_build/LIBTOOL=\1apr_build/' ${S}/build/apr_rules.mk +} + +do_install_append() { + oe_multilib_header apr.h + install -d ${D}${datadir}/apr + cp ${S}/${HOST_SYS}-libtool ${D}${datadir}/build-1/libtool +} + +SSTATE_SCAN_FILES += "apr_rules.mk libtool" + +SYSROOT_PREPROCESS_FUNCS += "apr_sysroot_preprocess" + +apr_sysroot_preprocess () { + d=${SYSROOT_DESTDIR}${datadir}/apr + install -d $d/ + cp ${S}/build/apr_rules.mk $d/ + sed -i s,apr_builddir=.*,apr_builddir=,g $d/apr_rules.mk + sed -i s,apr_builders=.*,apr_builders=,g $d/apr_rules.mk + sed -i s,LIBTOOL=.*,LIBTOOL=${HOST_SYS}-libtool,g $d/apr_rules.mk + sed -i s,\$\(apr_builders\),${STAGING_DATADIR}/apr/,g $d/apr_rules.mk + cp ${S}/build/mkdir.sh $d/ + cp ${S}/build/make_exports.awk $d/ + cp ${S}/build/make_var_export.awk $d/ +} + +do_compile_ptest() { + cd ${S}/test + oe_runmake +} + +do_install_ptest() { + t=${D}${PTEST_PATH}/test + mkdir -p $t/.libs + cp -r ${S}/test/data $t/ + cp -r ${S}/test/.libs/*.so $t/.libs/ + cp ${S}/test/proc_child $t/ + cp ${S}/test/readchild $t/ + cp ${S}/test/sockchild $t/ + cp ${S}/test/sockperf $t/ + cp ${S}/test/testall $t/ + cp ${S}/test/tryread $t/ +} + +export CONFIG_SHELL="/bin/bash" -- cgit v1.2.3-54-g00ecf