Skip to contentSkip to conversation

inetutils: Disable rsh, rcp, rlogin on musl

PATCH In review Khem Raj 3 participants 9 messages Dec 15, 2016 – Dec 19, 2016

lore
Share & tools
lore

Khem Raj

author
#0 lore raw

PATCH 1/6 inetutils: Disable rsh, rcp, rlogin on musl

They all need rcmd() API from rpc implementation and while glibc provides it bundled, musl does not so we disable these apps

---
 .../recipes-connectivity/inetutils/inetutils_1.9.4.bb | 19 +++++++++++++++----
 1 file changed, 15 insertions(+), 4 deletions(-)
meta-networking/recipes-connectivity/inetutils/inetutils_1.9.4.bb +15 -4
index a35e0b4..a8c4025 100644
@@ -5,6 +5,7 @@ talkd, telnet, telnetd, tftp, tftpd, and uucpd."
 HOMEPAGE = "http://www.gnu.org/software/inetutils"
 SECTION = "net"
 DEPENDS = "ncurses netbase readline"
+
 LICENSE = "GPLv3"
 
 LIC_FILES_CHKSUM = "file://COPYING;md5=0c7051aef9219dc7237f206c5c4179a7"
@@ -48,6 +49,8 @@ EXTRA_OECONF = "--with-ncurses-include-dir=${STAGING_INCDIR} \
         --enable-rpath=no \
 "
 
+EXTRA_OECONF_append_libc-musl = " --disable-rsh --disable-rcp --disable-rlogin "
+
 do_configure_prepend () {
     export HELP2MAN='true'
     cp ${STAGING_DATADIR_NATIVE}/gettext/config.rpath ${S}/build-aux/config.rpath
@@ -66,9 +69,15 @@ do_install_append () {
     mv ${D}${libexecdir}/tftpd ${D}${sbindir}/in.tftpd
     mv ${D}${libexecdir}/telnetd ${D}${sbindir}/in.telnetd
     mv ${D}${libexecdir}/rexecd ${D}${sbindir}/in.rexecd
-    mv ${D}${libexecdir}/rlogind ${D}${sbindir}/in.rlogind
-    mv ${D}${libexecdir}/rshd ${D}${sbindir}/in.rshd
-    mv ${D}${libexecdir}/talkd ${D}${sbindir}/in.talkd
+    if [ -e ${D}${libexecdir}/rlogind ]; then
+        mv ${D}${libexecdir}/rlogind ${D}${sbindir}/in.rlogind
+    fi
+    if [ -e ${D}${libexecdir}/rshd ]; then
+        mv ${D}${libexecdir}/rshd ${D}${sbindir}/in.rshd
+    fi
+    if [ -e ${D}${libexecdir}/talkd ]; then
+        mv ${D}${libexecdir}/talkd ${D}${sbindir}/in.talkd
+    fi
     mv ${D}${libexecdir}/uucpd ${D}${sbindir}/in.uucpd
     mv ${D}${libexecdir}/* ${D}${bindir}/
     cp ${WORKDIR}/rexec.xinetd.inetutils  ${D}/${sysconfdir}/xinetd.d/rexec
@@ -78,7 +87,9 @@ do_install_append () {
     cp ${WORKDIR}/tftpd.xinetd.inetutils  ${D}/${sysconfdir}/xinetd.d/tftpd
 
     sed -e 's,@SBINDIR@,${sbindir},g' -i ${D}/${sysconfdir}/xinetd.d/*
-
+    if [ -e ${D}${libdir}/charset.alias ]; then
+        rm -rf ${D}${libdir}/charset.alias
+    fi
     rm -rf ${D}${libexecdir}/
     # remove usr/lib if empty
     rmdir ${D}${libdir} || true
Signature · 1 line
2.10.2
author
#1 lore raw

PATCH 2/6 libmng: Add recipe

---
 meta-oe/recipes-graphics/libmng/libmng_2.0.3.bb | 22 ++++++++++++++++++++++
 1 file changed, 22 insertions(+)
 create mode 100644 meta-oe/recipes-graphics/libmng/libmng_2.0.3.bb
meta-oe/recipes-graphics/libmng/libmng_2.0.3.bb new file +22 -0
new file mode 100644
index 0000000..b176d09
@@ -0,0 +1,22 @@
+# Copyright (C) 2016 Khem Raj <[email protected]>
+# Released under the MIT license (see COPYING.MIT for the terms)
+
+DESCRIPTION = "Development files for the Multiple-image Network Graphics library"
+HOMEPAGE = "http://www.libmng.com/"
+LICENSE = "Zlib"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=32becdb8930f90eab219a8021130ec09"
+SECTION = "devel"
+DEPENDS = "zlib lcms"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${P}.tar.gz"
+
+SRC_URI[md5sum] = "7e9a12ba2a99dff7e736902ea07383d4"
+SRC_URI[sha256sum] = "cf112a1fb02f5b1c0fce5cab11ea8243852c139e669c44014125874b14b7dfaa"
+
+inherit autotools-brokensep pkgconfig
+
+PACKAGECONFIG ??= "jpeg"
+
+PACKAGECONFIG[jpeg] = "--with-jpeg,--without-jpeg,libjpeg-turbo"
+PACKAGECONFIG[lcms] = "---with-lcms2,--without-lcms2,lcms"
+
Signature · 1 line
2.10.2
author
#3 lore raw

PATCH v2 3/6 zbar: Add recipe

In reply to Khem Raj
---
 .../zbar/0001-make-relies-GNU-extentions.patch     | 32 ++++++++++++++
 .../zbar/zbar/0001-undefine-__va_arg_pack.patch    | 51 ++++++++++++++++++++++
 meta-oe/recipes-support/zbar/zbar_0.10.bb          | 28 ++++++++++++
 3 files changed, 111 insertions(+)
 create mode 100644 meta-oe/recipes-support/zbar/zbar/0001-make-relies-GNU-extentions.patch
 create mode 100644 meta-oe/recipes-support/zbar/zbar/0001-undefine-__va_arg_pack.patch
 create mode 100644 meta-oe/recipes-support/zbar/zbar_0.10.bb
meta-oe/recipes-support/zbar/zbar/0001-make-relies-GNU-extentions.patch new file +32 -0
new file mode 100644
index 0000000..04239ba
@@ -0,0 +1,32 @@
+From 224507bc4b6e58f7a6e445bfebfb59d6b8d78bd6 Mon Sep 17 00:00:00 2001
+From: Khem Raj <[email protected]>
+Date: Fri, 2 Dec 2016 17:38:51 -0800
+Subject: [PATCH] make relies GNU extentions
+
+We get errors like
+`%'-style pattern rules are a GNU make extension
+
+Disable this warning, since we use gmake with OE
+anyway
+
+Signed-off-by: Khem Raj <[email protected]>
+---
+ configure.ac | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/configure.ac b/configure.ac
+index 56d3dd0..9f85fd7 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -3,7 +3,7 @@ AC_PREREQ([2.61])
+ AC_INIT([zbar], [0.10], [[email protected]])
+ AC_CONFIG_AUX_DIR(config)
+ AC_CONFIG_MACRO_DIR(config)
+-AM_INIT_AUTOMAKE([1.10 -Wall -Werror foreign subdir-objects std-options dist-bzip2])
++AM_INIT_AUTOMAKE([1.10 -Wall -Werror -Wno-portability foreign subdir-objects std-options dist-bzip2])
+ AC_CONFIG_HEADERS([include/config.h])
+ AC_CONFIG_SRCDIR(zbar/scanner.c)
+ LT_PREREQ([2.2])
+-- 
+2.10.2
+
meta-oe/recipes-support/zbar/zbar/0001-undefine-__va_arg_pack.patch new file +51 -0

51 lines not on this page · raw message

meta-oe/recipes-support/zbar/zbar_0.10.bb new file +28 -0
new file mode 100644
index 0000000..77733aa
@@ -0,0 +1,28 @@
+DESRIPTION = "2D barcode scanner toolkit."
+SECTION = "graphics"
+LICENSE = "LGPL-2.1"
+
+DEPENDS = "pkgconfig intltool-native libpng jpeg"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=42bafded1b380c6fefbeb6c5cd5448d9"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/${PN}/${P}.tar.bz2 \
+           file://0001-undefine-__va_arg_pack.patch \
+           file://0001-make-relies-GNU-extentions.patch \
+"
+
+SRC_URI[md5sum] = "0fd61eb590ac1bab62a77913c8b086a5"
+SRC_URI[sha256sum] = "234efb39dbbe5cef4189cc76f37afbe3cfcfb45ae52493bfe8e191318bdbadc6"
+
+inherit autotools pkgconfig
+
+PACKAGECONFIG = "${@bb.utils.contains("DISTRO_FEATURES", "x11", "x11", "", d)}"
+
+PACKAGECONFIG[x11] = "--with-x,-without-x,libxcb libx11 libsm libxau libxext libxv libice libxdmcp"
+
+EXTRA_OECONF = " --without-imagemagick --without-qt --without-python --disable-video --without-gtk"
+
+do_install_append() {
+    #remove usr/bin if empty
+    rmdir ${D}${bindir}
+}
Signature · 1 line
2.10.2
author
#6 lore raw

PATCH v2 4/6 avro: Add recipe

In reply to Khem Raj
---
 meta-oe/recipes-support/avro/avro-c_1.8.1.bb | 18 ++++++++++++++++++
 1 file changed, 18 insertions(+)
 create mode 100644 meta-oe/recipes-support/avro/avro-c_1.8.1.bb
meta-oe/recipes-support/avro/avro-c_1.8.1.bb new file +18 -0
new file mode 100644
index 0000000..8deee4b
@@ -0,0 +1,18 @@
+SUMMARY = "Apache Avro data serialization system."
+HOMEPAGE = "http://apr.apache.org/"
+SECTION = "libs"
+
+
+LICENSE = "Apache-2.0"
+LIC_FILES_CHKSUM = "file://LICENSE;md5=73bdf70f268f0b3b9c5a83dd7a6f3324"
+
+DEPENDS = "jansson zlib xz"
+
+SRC_URI = "${APACHE_MIRROR}/avro/avro-${PV}/c/avro-c-${PV}.tar.gz"
+
+SRC_URI[md5sum] = "b268348536714541e10411823a1b59b0"
+SRC_URI[sha256sum] = "e5042088fa47e1aa2860c5cfed0bd061d81f9e96628f8b4d87a24d9b8c5e4ecc"
+
+LDFLAGS_append_libc-uclibc = " -lm"
+
+inherit cmake
Signature · 1 line
2.10.2
author
#7 lore raw

PATCH v2 5/6 liboop: Add recipe

In reply to Khem Raj

liboop is needed by ruli

---
 .../liboop/liboop/explicit_linking.patch           | 20 +++++++++++
 .../liboop/liboop/new-readline-typedef.patch       | 11 ++++++
 .../liboop/liboop/read_bugfixes.patch              | 40 ++++++++++++++++++++++
 .../recipes-support/liboop/liboop/tcl_dev.patch    | 22 ++++++++++++
 meta-oe/recipes-support/liboop/liboop_1.0.bb       | 23 +++++++++++++
 5 files changed, 116 insertions(+)
 create mode 100644 meta-oe/recipes-support/liboop/liboop/explicit_linking.patch
 create mode 100644 meta-oe/recipes-support/liboop/liboop/new-readline-typedef.patch
 create mode 100644 meta-oe/recipes-support/liboop/liboop/read_bugfixes.patch
 create mode 100644 meta-oe/recipes-support/liboop/liboop/tcl_dev.patch
 create mode 100644 meta-oe/recipes-support/liboop/liboop_1.0.bb
meta-oe/recipes-support/liboop/liboop/explicit_linking.patch new file +20 -0
new file mode 100644
index 0000000..05d3bf6
@@ -0,0 +1,20 @@
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -51,7 +51,7 @@ noinst_PROGRAMS = test-oop
+ 
+ test_oop_SOURCES = test-oop.c
+ test_oop_CFLAGS = $(GLIB2_CFLAGS) $(GLIB_INCLUDES) $(TCL_INCLUDES) $(WWW_INCLUDES)
+-test_oop_LDADD = $(lib_LTLIBRARIES)
++test_oop_LDADD = $(lib_LTLIBRARIES) $(GLIB2_LIBS) $(ADNS_LIBS) $(TCL_LIBS) $(READLINE_LIBS)
+ 
+ release: dist
+ 	gzip -dc $(PACKAGE)-$(VERSION).tar.gz | bzip2 -9 \
+--- a/liboop-glib2.pc.in
++++ b/liboop-glib2.pc.in
+@@ -7,5 +7,5 @@ Name: liboop-glib2
+ Description: Event loop management library (GLIB2 support)
+ Version: @VERSION@
+ Requires: liboop = @VERSION@ glib-2.0
+-Libs: -L${libdir} -loop-glib2
++Libs: -L${libdir} -loop-glib2 @GLIB2_LIBS@
+ Cflags: -D_REENTRANT -I${includedir}
meta-oe/recipes-support/liboop/liboop/new-readline-typedef.patch new file +11 -0
new file mode 100644
index 0000000..0a02420
@@ -0,0 +1,11 @@
+--- a/test-oop.c
++++ b/test-oop.c
+@@ -180,7 +180,7 @@ static void *stop_readline(oop_source *s
+ static void add_readline(oop_source *src) {
+ 	rl_callback_handler_install(
+ 		(char *) "> ", /* readline isn't const-correct */
+-		(VFunction *) on_readline);
++		(rl_vcpfunc_t *) on_readline);
+ 	oop_readline_register(src);
+ 	src->on_signal(src,SIGQUIT,stop_readline,NULL);
+ }
meta-oe/recipes-support/liboop/liboop/read_bugfixes.patch new file +40 -0
new file mode 100644
index 0000000..1880a24
@@ -0,0 +1,40 @@
+From: Ian Jackson <[email protected]>
+Applied-Upstream: no
+Bug-Debian: http://bugs.debian.org/579604
+Subject: oop-read.h bugfixes
+
+Some years ago I contributed a feature for reading lines and records
+to liboop: oop-read.h and read.c.  Since it took a while for that
+feature to make it into distributed versions, for a long time I've
+been using my own copy of the source file.  It seems that I fixed a
+couple of bugs in my copy which are still in the Debian package.  I
+can't find any record of me having told anyone about them and now I
+find that 1.0-6 still has the bugs.
+
+There are two fixes:
+ * Initialise "rd->discard" properly
+ * Avoid rd->neednotcheck becoming negative
+
+--- a/read.c
++++ b/read.c
+@@ -114,6 +114,7 @@ oop_read *oop_rd_new(oop_source *oop, oo
+   rd->allocbuf= 0;
+   rd->used= 0;
+   rd->alloc= buf ? bufsz : 0;
++  rd->discard= 0;
+   rd->neednotcheck= 0;
+   rd->displacedchar= -1;
+   rd->style= *OOP_RD_STYLE_IMMED;
+@@ -235,7 +236,11 @@ static void *on_process(oop_source *oop,
+   
+   if (rd->discard) {
+     rd->used -= rd->discard;
+-    rd->neednotcheck -= rd->discard;
++    if (rd->neednotcheck > rd->discard) {
++      rd->neednotcheck -= rd->discard;
++    } else {
++      rd->neednotcheck= 0;
++    }
+     memmove(buf, buf + rd->discard, rd->used);
+     rd->discard= 0;
+   }
meta-oe/recipes-support/liboop/liboop/tcl_dev.patch new file +22 -0
new file mode 100644
index 0000000..e738be5
@@ -0,0 +1,22 @@
+--- a/configure
++++ b/configure
+@@ -19935,7 +19935,7 @@
+ fi
+ 
+ if test xno != x$with_tcl; then
+-  for version in 8.4 8.3 8.2 8.1 8.0 ; do
++  for version in "" 8.4 8.3 8.2 8.1 8.0 ; do
+     CPPFLAGS="$save_cppflags -I/usr/include/tcl$version"
+     as_ac_Lib=`echo "ac_cv_lib_tcl$version''_Tcl_Main" | $as_tr_sh`
+ echo "$as_me:$LINENO: checking for Tcl_Main in -ltcl$version" >&5
+--- a/configure.ac
++++ b/configure.ac
+@@ -71,7 +71,7 @@
+ fi
+ 
+ if test xno != x$with_tcl; then
+-  for version in 8.4 8.3 8.2 8.1 8.0 ; do
++  for version in "" 8.4 8.3 8.2 8.1 8.0 ; do
+     CPPFLAGS="$save_cppflags -I/usr/include/tcl$version"
+     AC_CHECK_LIB(tcl$version,Tcl_Main,[
+     AC_CHECK_HEADER(tcl.h,[
meta-oe/recipes-support/liboop/liboop_1.0.bb new file +23 -0
new file mode 100644
index 0000000..82818c2
@@ -0,0 +1,23 @@
+DESCRIPTION = "Liboop is a low-level event loop management library for POSIX-based operating systems"
+HOMEPAGE = "http://liboop.org/"
+LICENSE = "GPL-2.0"
+LIC_FILES_CHKSUM = "file://COPYING;md5=8b54f38ccbd44feb80ab90e01af8b700"
+
+SRC_URI = "http://ftp.debian.org/debian/pool/main/libo/liboop/liboop_${PV}.orig.tar.gz \
+           file://read_bugfixes.patch \
+           file://explicit_linking.patch \
+           file://tcl_dev.patch \
+           file://new-readline-typedef.patch \
+"
+
+SRC_URI[md5sum] = "36cb971047d3af02369446f5e0b315a2"
+SRC_URI[sha256sum] = "34d83c6e0f09ee15cb2bc3131e219747c3b612bb57cf7d25318ab90da9a2d97c"
+
+PACKAGECONFIG ?= ""
+PACKAGECONFIG[readline] = "--with-readline,--without-readline,readline"
+PACKAGECONFIG[glib] = "--with-glib,--without-glib,glib-2.0 libpcre"
+PACKAGECONFIG[tcl] = "--with-tcl,--without-tcl,tcl"
+
+EXTRA_OECONF += "--without-adns -without-libwww"
+
+inherit autotools pkgconfig
Signature · 1 line
2.10.2
author
#8 lore raw

PATCH 6/6 gimp: Enable libmng plugins

In reply to Khem Raj

Now we have libmng recipe, therefore add support for libmng plugin

---
 meta-oe/recipes-graphics/gimp/gimp_2.8.18.bb | 1 +
 1 file changed, 1 insertion(+)
meta-oe/recipes-graphics/gimp/gimp_2.8.18.bb +1 -0
index 1f83523..38e10ef 100644
@@ -20,6 +20,7 @@ DEPENDS = " \
     jasper \
     bzip2 \
     libgudev \
+    libmng \
 "
 DEPENDS += "${@bb.utils.contains('DISTRO_FEATURES', 'x11', 'libxmu libxpm', '', d)}"
 
Signature · 1 line
2.10.2
#2 lore raw

Re: [meta-oe][PATCH 2/6] libmng: Add recipe

In reply to Khem Raj
Quoted 18 lines · Khem Raj
---
 meta-oe/recipes-graphics/libmng/libmng_2.0.3.bb | 22 ++++++++++++++++++++++
 1 file changed, 22 insertions(+)
 create mode 100644 meta-oe/recipes-graphics/libmng/libmng_2.0.3.bb
meta-oe/recipes-graphics/libmng/libmng_2.0.3.bb new file +6 -0
new file mode 100644
index 0000000..b176d09
@@ -0,0 +1,22 @@
+# Copyright (C) 2016 Khem Raj <[email protected]>
+# Released under the MIT license (see COPYING.MIT for the terms)
+
+DESCRIPTION = "Development files for the Multiple-image Network Graphics library"
+HOMEPAGE = "http://www.libmng.com/"
+LICENSE = "Zlib"

meta-oe/recipes-graphics/libmng/libmng_2.0.3.bb line 16

Quoted 10 lines
meta-oe/recipes-graphics/libmng/libmng_2.0.3.bb new file +10 -0
+LIC_FILES_CHKSUM = "file://LICENSE;md5=32becdb8930f90eab219a8021130ec09"
+SECTION = "devel"
+DEPENDS = "zlib lcms"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/${BPN}/${P}.tar.gz"
+
+SRC_URI[md5sum] = "7e9a12ba2a99dff7e736902ea07383d4"
+SRC_URI[sha256sum] = "cf112a1fb02f5b1c0fce5cab11ea8243852c139e669c44014125874b14b7dfaa"
+
+inherit autotools-brokensep pkgconfig

How difficult to fix B != S?

meta-oe/recipes-graphics/libmng/libmng_2.0.3.bb line 20

Quoted 4 lines
meta-oe/recipes-graphics/libmng/libmng_2.0.3.bb new file +4 -0
+
+PACKAGECONFIG ??= "jpeg"
+
+PACKAGECONFIG[jpeg] = "--with-jpeg,--without-jpeg,libjpeg-turbo"

Dependency should be on "jpeg" (unless libmng only supports libjpeg-turbo?).

Quoted 10 lines
meta-oe/recipes-graphics/libmng/libmng_2.0.3.bb new file +2 -1
+PACKAGECONFIG[lcms] = "---with-lcms2,--without-lcms2,lcms"
+
--

2.10.2

--
_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-devel

#4 lore raw

Re: [meta-oe][PATCH V2 3/6] zbar: Add recipe

In reply to Khem Raj

gst-plugins-bad-0.10.23: gst-plugins-bad-zbar rdepends on zbar, but it isn't a build dependency, missing zbar in DEPENDS or PACKAGECONFIG? [build-deps]

Quoted 162 lines · Khem Raj
---
 .../zbar/0001-make-relies-GNU-extentions.patch     | 32 ++++++++++++++
 .../zbar/zbar/0001-undefine-__va_arg_pack.patch    | 51
++++++++++++++++++++++
 meta-oe/recipes-support/zbar/zbar_0.10.bb          | 28 ++++++++++++
 3 files changed, 111 insertions(+)
 create mode 100644 meta-oe/recipes-support/zbar/
zbar/0001-make-relies-GNU-extentions.patch
 create mode 100644 meta-oe/recipes-support/zbar/
zbar/0001-undefine-__va_arg_pack.patch
 create mode 100644 meta-oe/recipes-support/zbar/zbar_0.10.bb
meta-oe/recipes-support/zbar/zbar/0001-make-relies- new file +0 -0
new file mode 100644
index 0000000..04239ba

GNU-extentions.patch

meta-oe/recipes-support/zbar/zbar/0001-make-relies- new file +25 -0
@@ -0,0 +1,32 @@
+From 224507bc4b6e58f7a6e445bfebfb59d6b8d78bd6 Mon Sep 17 00:00:00 2001
+From: Khem Raj <[email protected]>
+Date: Fri, 2 Dec 2016 17:38:51 -0800
+Subject: [PATCH] make relies GNU extentions
+
+We get errors like
+`%'-style pattern rules are a GNU make extension
+
+Disable this warning, since we use gmake with OE
+anyway
+
+Signed-off-by: Khem Raj <[email protected]>
+---
+ configure.ac | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/configure.ac b/configure.ac
+index 56d3dd0..9f85fd7 100644
+--- a/configure.ac
++++ b/configure.ac
+@@ -3,7 +3,7 @@ AC_PREREQ([2.61])
+ AC_INIT([zbar], [0.10], [[email protected]])
+ AC_CONFIG_AUX_DIR(config)
+ AC_CONFIG_MACRO_DIR(config)
+-AM_INIT_AUTOMAKE([1.10 -Wall -Werror foreign subdir-objects std-options

dist-bzip2])
++AM_INIT_AUTOMAKE([1.10 -Wall -Werror -Wno-portability foreign subdir-objects std-options dist-bzip2])
+ AC_CONFIG_HEADERS([include/config.h])
+ AC_CONFIG_SRCDIR(zbar/scanner.c)
+ LT_PREREQ([2.2])
+--
+2.10.2

meta-oe/recipes-support/zbar/zbar/0001-make-relies- new file +1 -0
+
meta-oe/recipes-support/zbar/zbar/0001-undefine-__va_arg_pack.patch new file +9 -0
new file mode 100644
index 0000000..f7d8ba1
@@ -0,0 +1,51 @@
+From f842872244219d9881fbec77054702412b1e16f8 Mon Sep 17 00:00:00 2001
+From: Khem Raj <[email protected]>
+Date: Fri, 2 Dec 2016 16:41:27 -0800
+Subject: [PATCH] undefine __va_arg_pack
+
+dprintf() is also a libc function. This fixes
+the compile errors
+
+/usr/include/bits/stdio2.h:140:1: error: expected identifier or '('

before '{' token
+| {

meta-oe/recipes-support/zbar/zbar/0001-undefine-__va_arg_pack.patch new file +41 -0
+
+Signed-off-by: Khem Raj <[email protected]>
+---
+ zbar/debug.h | 10 +++++-----
+ 1 file changed, 5 insertions(+), 5 deletions(-)
+
+diff --git a/zbar/debug.h b/zbar/debug.h
+index 482ca8d..68948f6 100644
+--- a/zbar/debug.h
++++ b/zbar/debug.h
+@@ -23,6 +23,7 @@
+
+ /* varargs variations on compile time debug spew */
+
++#undef __va_arg_pack
+ #ifndef DEBUG_LEVEL
+
+ # ifdef __GNUC__
+@@ -36,15 +37,14 @@
+ #else
+
+ # include <stdio.h>
+-
+ # ifdef __GNUC__
+-#  define dprintf(level, args...) \
++#  define dprintf(level, format, args...) \
+     if((level) <= DEBUG_LEVEL)    \
+-        fprintf(stderr, args)
++        fprintf(stderr, format, args)
+ # else
+-#  define dprintf(level, ...)     \
++#  define dprintf(level, format, ...)     \
+     if((level) <= DEBUG_LEVEL)    \
+-        fprintf(stderr, __VA_ARGS__)
++        fprintf(stderr, format, __VA_ARGS__)
+ # endif
+
+ #endif /* DEBUG_LEVEL */
+--
+2.10.2
+
meta-oe/recipes-support/zbar/zbar_0.10.bb new file +15 -0
new file mode 100644
index 0000000..77733aa
@@ -0,0 +1,28 @@
+DESRIPTION = "2D barcode scanner toolkit."
+SECTION = "graphics"
+LICENSE = "LGPL-2.1"
+
+DEPENDS = "pkgconfig intltool-native libpng jpeg"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=42bafded1b380c6fefbeb6c5cd5448d9"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/${PN}/${P}.tar.bz2 \
+           file://0001-undefine-__va_arg_pack.patch \
+           file://0001-make-relies-GNU-extentions.patch \
+"
+
+SRC_URI[md5sum] = "0fd61eb590ac1bab62a77913c8b086a5"
+SRC_URI[sha256sum] = "234efb39dbbe5cef4189cc76f37afb

e3cfcfb45ae52493bfe8e191318bdbadc6"

meta-oe/recipes-support/zbar/zbar_0.10.bb new file +4 -0
+
+inherit autotools pkgconfig
+
+PACKAGECONFIG = "${@bb.utils.contains("DISTRO_FEATURES", "x11", "x11",

"", d)}"

meta-oe/recipes-support/zbar/zbar_0.10.bb new file +2 -0
+
+PACKAGECONFIG[x11] = "--with-x,-without-x,libxcb libx11 libsm libxau

libxext libxv libice libxdmcp"

meta-oe/recipes-support/zbar/zbar_0.10.bb new file +7 -2
+
+EXTRA_OECONF = " --without-imagemagick --without-qt --without-python
--disable-video --without-gtk"
+
+do_install_append() {
+    #remove usr/bin if empty
+    rmdir ${D}${bindir}
+}
--

2.10.2

--
_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-devel

author
#5 lore raw

Re: [meta-oe][PATCH V2 3/6] zbar: Add recipe

Quoted 4 lines · Martin Jansa

gst-plugins-bad-0.10.23: gst-plugins-bad-zbar rdepends on zbar, but it isn't a build dependency, missing zbar in DEPENDS or PACKAGECONFIG? [build-deps]

sent a patch for this.