diff options
author | Khem Raj <raj.khem@gmail.com> | 2018-12-22 19:20:14 -0800 |
---|---|---|
committer | Khem Raj <raj.khem@gmail.com> | 2018-12-23 13:29:20 -0800 |
commit | 55f2541bf6279a3aa14eb1597e3a4bf844c7b00f (patch) | |
tree | 26571d5baf84d8354570616402bd1030ac12c24a /meta-networking/recipes-connectivity | |
parent | bf5cc7e1ffad95184079d69c6ab59ba96e5e0806 (diff) | |
download | meta-openembedded-55f2541bf6279a3aa14eb1597e3a4bf844c7b00f.tar.gz |
miniupnpd: Fix cross compile on OE
genconfig script can be specified OS specs
if its not then it pokes at the build system
via uname, we add code for OE support to ensure
we pass DISTRO_VERSION as OS_VERSION
Signed-off-by: Khem Raj <raj.khem@gmail.com>
Diffstat (limited to 'meta-networking/recipes-connectivity')
-rw-r--r-- | meta-networking/recipes-connectivity/miniupnpd/files/0001-Add-OpenEmbedded-cross-compile-case.patch | 40 | ||||
-rw-r--r-- | meta-networking/recipes-connectivity/miniupnpd/miniupnpd_2.1.20180706.bb | 8 |
2 files changed, 47 insertions, 1 deletions
diff --git a/meta-networking/recipes-connectivity/miniupnpd/files/0001-Add-OpenEmbedded-cross-compile-case.patch b/meta-networking/recipes-connectivity/miniupnpd/files/0001-Add-OpenEmbedded-cross-compile-case.patch new file mode 100644 index 000000000..cd4291d91 --- /dev/null +++ b/meta-networking/recipes-connectivity/miniupnpd/files/0001-Add-OpenEmbedded-cross-compile-case.patch | |||
@@ -0,0 +1,40 @@ | |||
1 | From 54698856e5602bbd9d61e855814c854a013b4840 Mon Sep 17 00:00:00 2001 | ||
2 | From: Khem Raj <raj.khem@gmail.com> | ||
3 | Date: Sat, 22 Dec 2018 18:47:45 -0800 | ||
4 | Subject: [PATCH] Add OpenEmbedded cross compile case | ||
5 | |||
6 | Upstream-Status: Pending | ||
7 | Signed-off-by: Khem Raj <raj.khem@gmail.com> | ||
8 | --- | ||
9 | genconfig.sh | 11 +++++++++++ | ||
10 | 1 file changed, 11 insertions(+) | ||
11 | |||
12 | diff --git a/genconfig.sh b/genconfig.sh | ||
13 | index dc42462..59922e9 100755 | ||
14 | --- a/genconfig.sh | ||
15 | +++ b/genconfig.sh | ||
16 | @@ -98,6 +98,12 @@ if [ -f ../shared/tomato_version ]; then | ||
17 | OS_VERSION="Tomato $TOMATO_VER" | ||
18 | fi | ||
19 | |||
20 | +# OpenEmbedded special case | ||
21 | +if [ -f ./os.openembedded ]; then | ||
22 | + OS_NAME=OpenEmbedded | ||
23 | + OS_VERSION=$(cat ./os.openembedded) | ||
24 | +fi | ||
25 | + | ||
26 | ${RM} ${CONFIGFILE} | ||
27 | |||
28 | echo "/* MiniUPnP Project" >> ${CONFIGFILE} | ||
29 | @@ -318,6 +324,11 @@ case $OS_NAME in | ||
30 | echo "#define USE_IFACEWATCHER 1" >> ${CONFIGFILE} | ||
31 | FW=netfilter | ||
32 | ;; | ||
33 | + OpenEmbedded) | ||
34 | + OS_URL=http://www.openembedded.org/ | ||
35 | + echo "#define USE_IFACEWATCHER 1" >> ${CONFIGFILE} | ||
36 | + FW=netfilter | ||
37 | + ;; | ||
38 | AstLinux) | ||
39 | OS_URL=http://www.astlinux.org/ | ||
40 | echo "#define USE_IFACEWATCHER 1" >> ${CONFIGFILE} | ||
diff --git a/meta-networking/recipes-connectivity/miniupnpd/miniupnpd_2.1.20180706.bb b/meta-networking/recipes-connectivity/miniupnpd/miniupnpd_2.1.20180706.bb index d5d9bcf64..ff40daaac 100644 --- a/meta-networking/recipes-connectivity/miniupnpd/miniupnpd_2.1.20180706.bb +++ b/meta-networking/recipes-connectivity/miniupnpd/miniupnpd_2.1.20180706.bb | |||
@@ -12,12 +12,18 @@ inherit autotools gettext pkgconfig systemd | |||
12 | DEPENDS += "iptables net-tools util-linux libmnl libnetfilter-conntrack" | 12 | DEPENDS += "iptables net-tools util-linux libmnl libnetfilter-conntrack" |
13 | 13 | ||
14 | SRC_URI = "http://miniupnp.tuxfamily.org/files/download.php?file=${P}.tar.gz;downloadfilename=${P}.tar.gz \ | 14 | SRC_URI = "http://miniupnp.tuxfamily.org/files/download.php?file=${P}.tar.gz;downloadfilename=${P}.tar.gz \ |
15 | file://miniupnpd.service" | 15 | file://miniupnpd.service \ |
16 | file://0001-Add-OpenEmbedded-cross-compile-case.patch \ | ||
17 | " | ||
16 | SRC_URI[md5sum] = "a84b3647c871802abeccfc2771e8db21" | 18 | SRC_URI[md5sum] = "a84b3647c871802abeccfc2771e8db21" |
17 | SRC_URI[sha256sum] = "fc2d2fd044d8c3f8d02b63d70489bb35ece836a4fc1b6386865ac8fbe8d8b006" | 19 | SRC_URI[sha256sum] = "fc2d2fd044d8c3f8d02b63d70489bb35ece836a4fc1b6386865ac8fbe8d8b006" |
18 | 20 | ||
19 | IPV6 = "${@bb.utils.contains('DISTRO_FEATURES', 'ipv6', '--ipv6', '', d)}" | 21 | IPV6 = "${@bb.utils.contains('DISTRO_FEATURES', 'ipv6', '--ipv6', '', d)}" |
20 | 22 | ||
23 | do_configure_prepend() { | ||
24 | echo "${@d.getVar('DISTRO_VERSION')}" > ${S}/os.openembedded | ||
25 | } | ||
26 | |||
21 | do_compile() { | 27 | do_compile() { |
22 | cd ${S} | 28 | cd ${S} |
23 | CONFIG_OPTIONS="${IPV6} --leasefile --vendorcfg" oe_runmake -f Makefile.linux | 29 | CONFIG_OPTIONS="${IPV6} --leasefile --vendorcfg" oe_runmake -f Makefile.linux |