diff options
author | ToshikazuOhiwa <toshikazu_ohiwa@mail.toyota.co.jp> | 2020-03-30 09:24:26 +0900 |
---|---|---|
committer | ToshikazuOhiwa <toshikazu_ohiwa@mail.toyota.co.jp> | 2020-03-30 09:24:26 +0900 |
commit | 5b80bfd7bffd4c20d80b7c70a7130529e9a755dd (patch) | |
tree | b4bb18dcd1487dbf1ea8127e5671b7bb2eded033 /meta-agl/meta-agl-profile-core/recipes-support | |
parent | 706ad73eb02caf8532deaf5d38995bd258725cb8 (diff) |
agl-basesystem
Diffstat (limited to 'meta-agl/meta-agl-profile-core/recipes-support')
12 files changed, 347 insertions, 0 deletions
diff --git a/meta-agl/meta-agl-profile-core/recipes-support/curl/curl/0001-replace-krb5-config-with-pkg-config.patch b/meta-agl/meta-agl-profile-core/recipes-support/curl/curl/0001-replace-krb5-config-with-pkg-config.patch new file mode 100644 index 00000000..a7db1b3c --- /dev/null +++ b/meta-agl/meta-agl-profile-core/recipes-support/curl/curl/0001-replace-krb5-config-with-pkg-config.patch @@ -0,0 +1,44 @@ +From ed70f0623708b8a6c1f58a5d243d87c5ff45b24d Mon Sep 17 00:00:00 2001 +From: Roy Li <rongqing.li@windriver.com> +Date: Tue, 26 Apr 2016 13:13:01 +0800 +Subject: [PATCH] replace krb5-config with pkg-config + +Upstream-Status: Pending + +Signed-off-by: Roy Li <rongqing.li@windriver.com> + +--- + configure.ac | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +diff --git a/configure.ac b/configure.ac +index 5569a26..56b0380 100755 +--- a/configure.ac ++++ b/configure.ac +@@ -1290,7 +1290,7 @@ AC_ARG_WITH(gssapi, + fi + ]) + +-: ${KRB5CONFIG:="$GSSAPI_ROOT/bin/krb5-config"} ++KRB5CONFIG=`which pkg-config` + + save_CPPFLAGS="$CPPFLAGS" + AC_MSG_CHECKING([if GSS-API support is requested]) +@@ -1301,7 +1301,7 @@ if test x"$want_gss" = xyes; then + if test -n "$host_alias" -a -f "$GSSAPI_ROOT/bin/$host_alias-krb5-config"; then + GSSAPI_INCS=`$GSSAPI_ROOT/bin/$host_alias-krb5-config --cflags gssapi` + elif test -f "$KRB5CONFIG"; then +- GSSAPI_INCS=`$KRB5CONFIG --cflags gssapi` ++ GSSAPI_INCS=`$KRB5CONFIG --cflags mit-krb5-gssapi` + elif test "$GSSAPI_ROOT" != "yes"; then + GSSAPI_INCS="-I$GSSAPI_ROOT/include" + fi +@@ -1394,7 +1394,7 @@ if test x"$want_gss" = xyes; then + elif test -f "$KRB5CONFIG"; then + dnl krb5-config doesn't have --libs-only-L or similar, put everything + dnl into LIBS +- gss_libs=`$KRB5CONFIG --libs gssapi` ++ gss_libs=`$KRB5CONFIG --libs mit-krb5-gssapi` + LIBS="$gss_libs $LIBS" + else + case $host in diff --git a/meta-agl/meta-agl-profile-core/recipes-support/curl/curl_%.bbappend b/meta-agl/meta-agl-profile-core/recipes-support/curl/curl_%.bbappend new file mode 100644 index 00000000..fc24cea1 --- /dev/null +++ b/meta-agl/meta-agl-profile-core/recipes-support/curl/curl_%.bbappend @@ -0,0 +1,5 @@ +# Cannot just append to PACKAGECONFIG, as nghttp2's dependencies do not build +# for native/nativesdk, and appending class-target does not work because of +# the weak definition of PACKAGECONFIG in the recipe, so need to copy the +# definition to add nghttp2... +PACKAGECONFIG = "${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)} gnutls libidn proxy threaded-resolver verbose zlib nghttp2" diff --git a/meta-agl/meta-agl-profile-core/recipes-support/curl/curl_7.66.0.bb b/meta-agl/meta-agl-profile-core/recipes-support/curl/curl_7.66.0.bb new file mode 100644 index 00000000..d1975f24 --- /dev/null +++ b/meta-agl/meta-agl-profile-core/recipes-support/curl/curl_7.66.0.bb @@ -0,0 +1,80 @@ +SUMMARY = "Command line tool and library for client-side URL transfers" +HOMEPAGE = "http://curl.haxx.se/" +BUGTRACKER = "http://curl.haxx.se/mail/list.cgi?list=curl-tracker" +SECTION = "console/network" +LICENSE = "MIT" +LIC_FILES_CHKSUM = "file://COPYING;md5=be5d9e1419c4363f4b32037a2d3b7ffa" + +SRC_URI = "http://curl.haxx.se/download/curl-${PV}.tar.bz2 \ + file://0001-replace-krb5-config-with-pkg-config.patch \ +" + +SRC_URI[md5sum] = "c238aa394e3aa47ca4fcb0491774149f" +SRC_URI[sha256sum] = "6618234e0235c420a21f4cb4c2dd0badde76e6139668739085a70c4e2fe7a141" + +CVE_PRODUCT = "curl libcurl" +inherit autotools pkgconfig binconfig multilib_header + +PACKAGECONFIG ??= "${@bb.utils.filter('DISTRO_FEATURES', 'ipv6', d)} gnutls libidn proxy threaded-resolver verbose zlib" +PACKAGECONFIG_class-native = "ipv6 proxy ssl threaded-resolver verbose zlib" +PACKAGECONFIG_class-nativesdk = "ipv6 proxy ssl threaded-resolver verbose zlib" + +# 'ares' and 'threaded-resolver' are mutually exclusive +PACKAGECONFIG[ares] = "--enable-ares,--disable-ares,c-ares" +PACKAGECONFIG[brotli] = "--with-brotli,--without-brotli,brotli" +PACKAGECONFIG[builtinmanual] = "--enable-manual,--disable-manual" +PACKAGECONFIG[dict] = "--enable-dict,--disable-dict," +PACKAGECONFIG[gnutls] = "--with-gnutls,--without-gnutls,gnutls" +PACKAGECONFIG[gopher] = "--enable-gopher,--disable-gopher," +PACKAGECONFIG[imap] = "--enable-imap,--disable-imap," +PACKAGECONFIG[ipv6] = "--enable-ipv6,--disable-ipv6," +PACKAGECONFIG[krb5] = "--with-gssapi,--without-gssapi,krb5" +PACKAGECONFIG[ldap] = "--enable-ldap,--disable-ldap," +PACKAGECONFIG[ldaps] = "--enable-ldaps,--disable-ldaps," +PACKAGECONFIG[libidn] = "--with-libidn2,--without-libidn2,libidn2" +PACKAGECONFIG[libssh2] = "--with-libssh2,--without-libssh2,libssh2" +PACKAGECONFIG[mbedtls] = "--with-mbedtls=${STAGING_DIR_TARGET},--without-mbedtls,mbedtls" +PACKAGECONFIG[nghttp2] = "--with-nghttp2,--without-nghttp2,nghttp2" +PACKAGECONFIG[pop3] = "--enable-pop3,--disable-pop3," +PACKAGECONFIG[proxy] = "--enable-proxy,--disable-proxy," +PACKAGECONFIG[rtmpdump] = "--with-librtmp,--without-librtmp,rtmpdump" +PACKAGECONFIG[rtsp] = "--enable-rtsp,--disable-rtsp," +PACKAGECONFIG[smb] = "--enable-smb,--disable-smb," +PACKAGECONFIG[smtp] = "--enable-smtp,--disable-smtp," +PACKAGECONFIG[ssl] = "--with-ssl --with-random=/dev/urandom,--without-ssl,openssl" +PACKAGECONFIG[nss] = "--with-nss,--without-nss,nss" +PACKAGECONFIG[telnet] = "--enable-telnet,--disable-telnet," +PACKAGECONFIG[tftp] = "--enable-tftp,--disable-tftp," +PACKAGECONFIG[threaded-resolver] = "--enable-threaded-resolver,--disable-threaded-resolver" +PACKAGECONFIG[verbose] = "--enable-verbose,--disable-verbose" +PACKAGECONFIG[zlib] = "--with-zlib=${STAGING_LIBDIR}/../,--without-zlib,zlib" + +EXTRA_OECONF = " \ + --disable-libcurl-option \ + --disable-ntlm-wb \ + --enable-crypto-auth \ + --with-ca-bundle=${sysconfdir}/ssl/certs/ca-certificates.crt \ + --without-libmetalink \ + --without-libpsl \ +" + +do_install_append_class-target() { + # cleanup buildpaths from curl-config + sed -i \ + -e 's,--sysroot=${STAGING_DIR_TARGET},,g' \ + -e 's,--with-libtool-sysroot=${STAGING_DIR_TARGET},,g' \ + -e 's|${DEBUG_PREFIX_MAP}||g' \ + ${D}${bindir}/curl-config +} + +PACKAGES =+ "lib${BPN}" + +FILES_lib${BPN} = "${libdir}/lib*.so.*" +RRECOMMENDS_lib${BPN} += "ca-certificates" + +FILES_${PN} += "${datadir}/zsh" + +inherit multilib_script +MULTILIB_SCRIPTS = "${PN}-dev:${bindir}/curl-config" + +BBCLASSEXTEND = "native nativesdk" diff --git a/meta-agl/meta-agl-profile-core/recipes-support/libmicrohttpd/libmicrohttpd_0.9.63.bb b/meta-agl/meta-agl-profile-core/recipes-support/libmicrohttpd/libmicrohttpd_0.9.63.bb new file mode 100644 index 00000000..ab6f681d --- /dev/null +++ b/meta-agl/meta-agl-profile-core/recipes-support/libmicrohttpd/libmicrohttpd_0.9.63.bb @@ -0,0 +1,28 @@ +DESCRIPTION = "A small C library that is supposed to make it easy to run an HTTP server as part of another application" +HOMEPAGE = "http://www.gnu.org/software/libmicrohttpd/" +LICENSE = "LGPL-2.1+" +LIC_FILES_CHKSUM = "file://COPYING;md5=9331186f4f80db7da0e724bdd6554ee5" +SECTION = "net" +DEPENDS = "file" + +SRC_URI = "http://ftp.gnu.org/gnu/libmicrohttpd/${BPN}-${PV}.tar.gz" +SRC_URI[md5sum] = "1c10de049608fca46941cbc790e3ab00" +SRC_URI[sha256sum] = "37c36f1be177f0e37ef181a645cd3baac1000bd322a01c2eff70f3cc8c91749c" + +inherit autotools lib_package pkgconfig gettext + +CFLAGS += "-pthread -D_REENTRANT" + +EXTRA_OECONF += "--disable-static --with-gnutls=${STAGING_LIBDIR}/../" + +PACKAGECONFIG ?= "curl https" +PACKAGECONFIG_append_class-target = "\ + ${@bb.utils.filter('DISTRO_FEATURES', 'largefile', d)} \ +" +PACKAGECONFIG[largefile] = "--enable-largefile,--disable-largefile,," +PACKAGECONFIG[curl] = "--enable-curl,--disable-curl,curl," +PACKAGECONFIG[https] = "--enable-https,--disable-https,libgcrypt gnutls," + +do_compile_append() { + sed -i s:-L${STAGING_LIBDIR}::g libmicrohttpd.pc +} diff --git a/meta-agl/meta-agl-profile-core/recipes-support/libsoup/libsoup-2.4_%.bbappend b/meta-agl/meta-agl-profile-core/recipes-support/libsoup/libsoup-2.4_%.bbappend new file mode 100644 index 00000000..06651fc1 --- /dev/null +++ b/meta-agl/meta-agl-profile-core/recipes-support/libsoup/libsoup-2.4_%.bbappend @@ -0,0 +1 @@ +EXTRA_OECONF_append_class-native = " --disable-tls-check" diff --git a/meta-agl/meta-agl-profile-core/recipes-support/nghttp2/nghttp2_1.39.1.bb b/meta-agl/meta-agl-profile-core/recipes-support/nghttp2/nghttp2_1.39.1.bb new file mode 100644 index 00000000..6077daf7 --- /dev/null +++ b/meta-agl/meta-agl-profile-core/recipes-support/nghttp2/nghttp2_1.39.1.bb @@ -0,0 +1,15 @@ +SUMMARY = "HTTP/2 C Library and tools" +HOMEPAGE = "https://nghttp2.org/" +SECTION = "libs" +LICENSE = "MIT" +LIC_FILES_CHKSUM = "file://COPYING;md5=764abdf30b2eadd37ce47dcbce0ea1ec" + ++UPSTREAM_CHECK_URI = "https://github.com/nghttp2/nghttp2/releases" + +SRC_URI = "https://github.com/nghttp2/nghttp2/releases/download/v${PV}/nghttp2-${PV}.tar.xz" +SRC_URI[md5sum] = "02b015cb178c46f27dd87228e33db35f" +SRC_URI[sha256sum] = "679160766401f474731fd60c3aca095f88451e3cc4709b72306e4c34cf981448" + +DEPENDS = "libxml2 openssl zlib jansson cunit c-ares" + +inherit cmake pythonnative python-dir diff --git a/meta-agl/meta-agl-profile-core/recipes-support/opencv/opencv_3.%.bbappend b/meta-agl/meta-agl-profile-core/recipes-support/opencv/opencv_3.%.bbappend new file mode 100644 index 00000000..8656abf0 --- /dev/null +++ b/meta-agl/meta-agl-profile-core/recipes-support/opencv/opencv_3.%.bbappend @@ -0,0 +1 @@ +PACKAGECONFIG ?= "jpeg png v4l libv4l gstreamer" diff --git a/meta-agl/meta-agl-profile-core/recipes-support/udisks/files/automount.service b/meta-agl/meta-agl-profile-core/recipes-support/udisks/files/automount.service new file mode 100644 index 00000000..64c36e76 --- /dev/null +++ b/meta-agl/meta-agl-profile-core/recipes-support/udisks/files/automount.service @@ -0,0 +1,9 @@ +[Unit] +Description=Automount Disk Manager +After=udisks.service + +[Service] +ExecStart=/usr/libexec/automount.sh + +[Install] +WantedBy=multi-user.target diff --git a/meta-agl/meta-agl-profile-core/recipes-support/udisks/files/automount.sh b/meta-agl/meta-agl-profile-core/recipes-support/udisks/files/automount.sh new file mode 100644 index 00000000..23679191 --- /dev/null +++ b/meta-agl/meta-agl-profile-core/recipes-support/udisks/files/automount.sh @@ -0,0 +1,93 @@ +#!/bin/sh + +MOUNT_OPTIONS_DEFAULT="ro,noexec" +MOUNT_OPTIONS_VFAT="umask=0022" +MOUNT_OPTIONS_EXT="" +MOUNT_OPTIONS_NTFS="" +MOUNT_OPTIONS_ISO9660="" + +VERBOSE=false + +# Source a configuration file that can override mount options if exists +[ -f /etc/automount.conf ] && . /etc/automount.conf + +mount_device() { + MOUNT_OPTIONS="" + FSTYPE="$( udevadm info "${1}" "${2}" | awk -v FS== '/ID_FS_TYPE/ {print $2}' )" + DEVNAME="$( udevadm info "${1}" "${2}" | awk -v FS== '/DEVNAME/ {print $2}' )" + case $FSTYPE in + vfat) + MOUNT_OPTIONS="${MOUNT_OPTIONS_VFAT}" + ;; + ext[2-4]) + MOUNT_OPTIONS="${MOUNT_OPTIONS_EXT}" + ;; + ntfs) + MOUNT_OPTIONS="${MOUNT_OPTIONS_NTFS}" + ;; + iso9660) + MOUNT_OPTIONS="${MOUNT_OPTIONS_ISO9660}" + ;; + "") + if $VERBOSE; then + echo "[INFO][${DEVNAME}] Not a partition with a filesystem!" + fi + return + ;; + *) + echo "[WARNING][${DEVNAME}] The filesystem '${FSTYPE}' is not supported!" + return + ;; + esac + + if [ -n "${MOUNT_OPTIONS_DEFAULT}" ]; then + if [ -z "${MOUNT_OPTIONS}" ]; then + MOUNT_OPTIONS="${MOUNT_OPTIONS_DEFAULT}" + else + MOUNT_OPTIONS="${MOUNT_OPTIONS_DEFAULT},${MOUNT_OPTIONS}" + fi + fi + if $VERBOSE; then + echo "[INFO][${DEVNAME}] Mounting a ${FSTYPE}'s filesystem with options: ${MOUNT_OPTIONS}" + fi + + if command -v udisksctl > /dev/null 2>&1; then + if [ -n "${MOUNT_OPTIONS}" ]; then + MOUNT_OPTIONS="-o ${MOUNT_OPTIONS}" + fi + udisksctl mount -t "${FSTYPE}" -b "${DEVNAME}" ${MOUNT_OPTIONS} + elif command -v udisks >/dev/null 2>&1; then + if [ -n "${MOUNT_OPTIONS}" ]; then + MOUNT_OPTIONS="--mount-options ${MOUNT_OPTIONS}" + fi + udisks --mount-fstype "${FSTYPE}" --mount "${DEVNAME}" ${MOUNT_OPTIONS} + else + echo "[ERROR] Unable to find binary for mounting ${DEVNAME}" >&2 + return + fi + if [ "$?" -ne "0" ]; then + echo "[ERROR] Failed to mount the device ${DEVNAME} of type ${FSTYPE} with options ${MOUNT_OPTIONS}" >&2 + fi +} + +# At startup, remove empty directories that may exists +rmdir /media/* > /dev/null 2>&1 + +# Mount already plugged devices +for DEVICE in $( lsblk -dn | cut -d' ' -f1 ); do + REMOVABLE=$( cat "/sys/block/${DEVICE}/removable" ) + if [ "${REMOVABLE}" -eq "1" ]; then + for PART in "/dev/${DEVICE}"*; do + mount_device -n "${PART}" + done + fi +done + +# Wait for plug events and mount devices +stdbuf -oL -- udevadm monitor --udev -s block | +while read -r -- _ _ EVENT DEVPATH _ +do + if [ "${EVENT}" = "add" ]; then + mount_device -p "/sys/${DEVPATH}" + fi +done diff --git a/meta-agl/meta-agl-profile-core/recipes-support/udisks/files/org.freedesktop.UDisks.conf b/meta-agl/meta-agl-profile-core/recipes-support/udisks/files/org.freedesktop.UDisks.conf new file mode 100644 index 00000000..0098b94e --- /dev/null +++ b/meta-agl/meta-agl-profile-core/recipes-support/udisks/files/org.freedesktop.UDisks.conf @@ -0,0 +1,32 @@ +<?xml version="1.0" encoding="UTF-8"?> <!-- -*- XML -*- --> + +<!DOCTYPE busconfig PUBLIC + "-//freedesktop//DTD D-BUS Bus Configuration 1.0//EN" + "http://www.freedesktop.org/standards/dbus/1.0/busconfig.dtd"> +<busconfig> + <!-- Only root can own the service --> + <policy user="root"> + <allow own="org.freedesktop.UDisks"/> + </policy> + + <policy context="default"> + <allow send_destination="org.freedesktop.UDisks"/> + + <allow send_destination="org.freedesktop.UDisks" + send_interface="org.freedesktop.DBus.Properties"/> + <allow send_destination="org.freedesktop.UDisks" + send_interface="org.freedesktop.DBus.Introspectable"/> + <allow send_destination="org.freedesktop.UDisks" + send_interface="org.freedesktop.UDisks"/> + <allow send_destination="org.freedesktop.UDisks" + send_interface="org.freedesktop.UDisks.Device"/> + <allow send_destination="org.freedesktop.UDisks" + send_interface="org.freedesktop.UDisks.Adapter"/> + <allow send_destination="org.freedesktop.UDisks" + send_interface="org.freedesktop.UDisks.Expander"/> + <allow send_destination="org.freedesktop.UDisks" + send_interface="org.freedesktop.UDisks.Port"/> + <allow receive_sender="org.freedesktop.UDisks" receive_type="signal" + receive_interface="org.freedesktop.UDisks"/> + </policy> +</busconfig> diff --git a/meta-agl/meta-agl-profile-core/recipes-support/udisks/files/udisks.service b/meta-agl/meta-agl-profile-core/recipes-support/udisks/files/udisks.service new file mode 100644 index 00000000..4bd55844 --- /dev/null +++ b/meta-agl/meta-agl-profile-core/recipes-support/udisks/files/udisks.service @@ -0,0 +1,11 @@ +[Unit] +Description=Disk Manager (legacy version) +Documentation=man:udisks(7) + +[Service] +Type=dbus +BusName=org.freedesktop.UDisks +ExecStart=/usr/libexec/udisks-daemon --no-debug + +[Install] +WantedBy=multi-user.target diff --git a/meta-agl/meta-agl-profile-core/recipes-support/udisks/udisks_1.0.5.bbappend b/meta-agl/meta-agl-profile-core/recipes-support/udisks/udisks_1.0.5.bbappend new file mode 100644 index 00000000..d55a167a --- /dev/null +++ b/meta-agl/meta-agl-profile-core/recipes-support/udisks/udisks_1.0.5.bbappend @@ -0,0 +1,28 @@ +SRC_URI += "file://org.freedesktop.UDisks.conf \ + file://udisks.service \ + file://automount.service \ + file://automount.sh \ + " +FILESEXTRAPATHS_prepend := "${THISDIR}/files:" + +FILES_${PN} += "${base_libdir}/systemd/system/automount.service \ + ${base_libdir}/systemd/system/udisks.service \ + ${libexecdir}/automount.sh \ + " + +SYSTEMD_AUTO_ENABLE = "enable" +SYSTEMD_SERVICE_${PN} = "udisks.service automount.service" + +do_install_append () { + install -d ${D}${sysconfdir}/dbus-1/system.d + install -m 644 ${WORKDIR}/org.freedesktop.UDisks.conf ${D}${sysconfdir}/dbus-1/system.d/ + + install -d ${D}${base_libdir}/systemd/system + install -m 0644 ${WORKDIR}/udisks.service ${D}${base_libdir}/systemd/system + + install -d ${D}${base_libdir}/systemd/system + install -m 0644 ${WORKDIR}/automount.service ${D}${base_libdir}/systemd/system + + install -d ${D}${libexecdir} + install -m 0755 ${WORKDIR}/automount.sh ${D}${libexecdir}/automount.sh +} |