Skip to contentSkip to conversation

fix libpcap/systemd/guile

PATCH In review Robert Yang 3 participants 9 messages Jun 16, 2014 – Jun 18, 2014

lore
Share & tools
lore
#0 lore raw

cover fix libpcap/systemd/guile

The following changes since commit 3a88df915831f2fd5e46ed71b21190398d1de0f1:

alsa-tools: Add missing pkgconfg dependency (2014-06-14 08:46:02 +0100)

are available in the git repository at:

git://git.pokylinux.org/poky-contrib rbt/3fixes
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=rbt/3fixes

Hu Yadi (1):
libpcap: Avoid libpcap build error when libnl1 is involved

Robert Yang (1):
systemd: check IFLA_VLAN_PROTOCOL

Yue Tao (1):
guile: depends on texinfo-native

 meta/recipes-connectivity/libpcap/libpcap.inc      |    3 ++
 .../systemd/systemd/systemd-older-kernel.patch     |   56 ++++++++++++++++++++
 meta/recipes-core/systemd/systemd_213.bb           |    2 +-
 meta/recipes-devtools/guile/guile_2.0.11.bb        |    2 +-
 4 files changed, 61 insertions(+), 2 deletions(-)
 create mode 100644 meta/recipes-core/systemd/systemd/systemd-older-kernel.patch
Signature · 1 line
1.7.9.5
#1 lore raw

PATCH 1/3 systemd: check IFLA_VLAN_PROTOCOL

The older kernel's linux/if_link.h doesn't have IFLA_VLAN_PROTOCOL, we need check whether it has been defined or not.

The maintainer said that he would fix it:

http://thread.gmane.org/gmane.comp.sysutils.systemd.devel/18200

Also we need redefine IFLA_MAX from 34 to 35 when define IFLA_CARRIER, otherwise there would be error:

| src/libsystemd/sd-rtnl/rtnl-types.c:233:9: error: array index in initializer exceeds array bounds
| [IFLA_CARRIER] = { .type = NLA_U8 },

[YOCTO #6380]

---
 .../systemd/systemd/systemd-older-kernel.patch     |   56 ++++++++++++++++++++
 meta/recipes-core/systemd/systemd_213.bb           |    2 +-
 2 files changed, 57 insertions(+), 1 deletion(-)
 create mode 100644 meta/recipes-core/systemd/systemd/systemd-older-kernel.patch
meta/recipes-core/systemd/systemd/systemd-older-kernel.patch new file +56 -0
new file mode 100644
index 0000000..18b50e7
@@ -0,0 +1,56 @@
+From 6109f02dcc4f2d7a461c5772bab494f5753a2203 Mon Sep 17 00:00:00 2001
+From: Robert Yang <[email protected]>
+Date: Thu, 29 May 2014 08:09:07 +0000
+Subject: [PATCH] rtnl-types.c: check IFLA_VLAN_PROTOCOL
+
+The older kernel's linux/if_link.h doesn't have IFLA_VLAN_PROTOCOL, we need
+check whether it has been defined or not.
+
+The maintainer said that he would fix it:
+
+http://thread.gmane.org/gmane.comp.sysutils.systemd.devel/18200
+
+Also we need redefine IFLA_MAX from 34 to 35 when define IFLA_CARRIER,
+otherwise there would be error:
+
+| src/libsystemd/sd-rtnl/rtnl-types.c:233:9: error: array index in initializer exceeds array bounds
+|          [IFLA_CARRIER]          = { .type = NLA_U8 },
+
+Upstream-Status: Pending
+
+Signed-off-by: Robert Yang <[email protected]>
+---
+ src/libsystemd/sd-rtnl/rtnl-types.c | 2 ++
+ src/shared/missing.h                | 2 ++
+ 2 files changed, 4 insertions(+)
+
+diff --git a/src/libsystemd/sd-rtnl/rtnl-types.c b/src/libsystemd/sd-rtnl/rtnl-types.c
+index 44ac5ec..ab6161f 100644
+--- a/src/libsystemd/sd-rtnl/rtnl-types.c
++++ b/src/libsystemd/sd-rtnl/rtnl-types.c
+@@ -67,7 +67,9 @@ static const NLType rtnl_link_info_data_vlan_types[IFLA_VLAN_MAX + 1] = {
+         [IFLA_VLAN_EGRESS_QOS]  = { .type = NLA_NESTED },
+         [IFLA_VLAN_INGRESS_QOS] = { .type = NLA_NESTED },
+ */
++#ifdef IFLA_VLAN_PROTOCOL
+         [IFLA_VLAN_PROTOCOL]    = { .type = NLA_U16 },
++#endif
+ };
+ 
+ static const NLType rtnl_link_info_data_bond_types[IFLA_BOND_MAX + 1] = {
+diff --git a/src/shared/missing.h b/src/shared/missing.h
+index d5ec2f8..732853f 100644
+--- a/src/shared/missing.h
++++ b/src/shared/missing.h
+@@ -94,6 +94,8 @@
+ 
+ #ifndef IFLA_CARRIER
+   #define IFLA_CARRIER 33
++  #undef IFLA_MAX
++  #define IFLA_MAX 35
+   #ifndef IFLA_NUM_RX_QUEUES
+     #define IFLA_NUM_RX_QUEUES 32
+     #ifndef IFLA_NUM_TX_QUEUES
+-- 
+1.8.3.4
+
meta/recipes-core/systemd/systemd_213.bb +1 -1
index 5f90576..279cf23 100644
@@ -31,11 +31,11 @@ SRC_URI = "git://anongit.freedesktop.org/systemd/systemd;branch=master;protocol=
            file://0001-uClibc-doesn-t-implement-pwritev-preadv.patch \
            file://uclibc-sysinfo_h.patch \
            file://uclibc-get-physmem.patch \
-           \
            file://touchscreen.rules \
            file://00-create-volatile.conf \
            file://init \
            file://run-ptest \
+           file://systemd-older-kernel.patch \
           "
 
 S = "${WORKDIR}/git"
Signature · 1 line
1.7.9.5
#2 lore raw

Re: [PATCH 1/3] systemd: check IFLA_VLAN_PROTOCOL

Robert Yang <[email protected]>

Quoted 3 lines · writes:

++#ifdef IFLA_VLAN_PROTOCOL
+ [IFLA_VLAN_PROTOCOL] = { .type = NLA_U16 },
++#endif

This will trigger everytime because IFLA_VLAN_PROTOCOL is an enum, not a #define

Enrico

#3 lore raw

PATCH 2/3 libpcap: Avoid libpcap build error when libnl1 is involved

In reply to Robert Yang

From: Hu Yadi <[email protected]>

Add --with-libnl autoconfig parameter and dependency between libpcap and libnl1

---
 meta/recipes-connectivity/libpcap/libpcap.inc |    3 +++
 1 file changed, 3 insertions(+)
meta/recipes-connectivity/libpcap/libpcap.inc +3 -0
index 177b70f..6f76cb5 100644
@@ -23,6 +23,9 @@ inherit autotools binconfig
 
 EXTRA_OECONF = "--with-pcap=linux"
 
+PACKAGECONFIG ??= ""
+PACKAGECONFIG[libnl1] = "--with-libnl,--without-libnl,libnl1,libnl1"
+
 CPPFLAGS_prepend = "-I${S} "
 CFLAGS_prepend = "-I${S} "
 CXXFLAGS_prepend = "-I${S} "
Signature · 1 line
1.7.9.5
#4 lore raw

Re: [PATCH 2/3] libpcap: Avoid libpcap build error when libnl1 is involved

Quoted 1 line · Robert Yang

+PACKAGECONFIG[libnl1] = "--with-libnl,--without-libnl,libnl1,libnl1"

Why did you need to specify a runtime dependency?

Ross

#5 lore raw

Re: [PATCH 2/3] libpcap: Avoid libpcap build error when libnl1 is involved

Quoted 4 lines · Ross
Quoted 1 line · Robert Yang

+PACKAGECONFIG[libnl1] = "--with-libnl,--without-libnl,libnl1,libnl1"

Why did you need to specify a runtime dependency?

Sorry, please drop this one, I will check with the original author.

// Robert

Quoted 4 lines

Ross

#6 lore raw

PATCH 3/3 guile: depends on texinfo-native

In reply to Robert Yang

From: Yue Tao <[email protected]>

Fixed this error on Fedora19-x86_64:

[snip]

| ./api-control.texi:1616: must be after `@deftypefn' to use `@deftypefnx'
| ./api-utility.texi:518: warning: node `C Hooks' is next for `Hook Reference' in menu but not in sectioning
| ./api-utility.texi:626: warning: node `Hook Reference' is prev for `C Hooks' in menu but not in sectioning

[snip]

We can use the texinfo-native to fix this error.

---
 meta/recipes-devtools/guile/guile_2.0.11.bb |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta/recipes-devtools/guile/guile_2.0.11.bb +1 -1
index d19460a..8a3bf28 100644
@@ -31,7 +31,7 @@ SRC_URI[sha256sum] = "aed0a4a6db4e310cbdfeb3613fa6f86fddc91ef624c1e3f8937a6304c6
 inherit autotools gettext pkgconfig texinfo
 BBCLASSEXTEND = "native"
 
-DEPENDS = "libunistring bdwgc gmp libtool libffi"
+DEPENDS = "libunistring bdwgc gmp libtool libffi texinfo-native"
 # add guile-native only to the target recipe's DEPENDS
 DEPENDS_append_class-target = " guile-native libatomics-ops"
 
Signature · 1 line
1.7.9.5
#7 lore raw

Re: [PATCH 3/3] guile: depends on texinfo-native

Quoted 1 line · Robert Yang

+DEPENDS = "libunistring bdwgc gmp libtool libffi texinfo-native"

There's a texinfo class you can inherit, instead of adding the dependency directly.

Ross

#8 lore raw

Re: [PATCH 3/3] guile: depends on texinfo-native

Quoted 5 lines · Ross
Quoted 1 line · Robert Yang

+DEPENDS = "libunistring bdwgc gmp libtool libffi texinfo-native"

There's a texinfo class you can inherit, instead of adding the dependency directly.

Thanks, I didn't notice we have the texinfo.bbclass now, will test whether it works or not and update again.

Quoted 4 lines

Ross