mirror of
https://github.com/MiyooCFW/buildroot.git
synced 2025-09-27 22:24:19 +03:00
Merge from bittboy/buildroot@db180c0
This commit is contained in:
37
package/socat/0001-no-documentation.patch
Normal file
37
package/socat/0001-no-documentation.patch
Normal file
@@ -0,0 +1,37 @@
|
||||
socat: disable documentation build/installation
|
||||
|
||||
The documentation generation process requires a special yold2man
|
||||
program, for which we don't have a package in Buildroot. Since we
|
||||
generally don't care much about documentation of packages, just adjust
|
||||
the package Makefile.in to not build/install its documentation.
|
||||
|
||||
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
|
||||
|
||||
Index: b/Makefile.in
|
||||
===================================================================
|
||||
--- a/Makefile.in
|
||||
+++ b/Makefile.in
|
||||
@@ -93,7 +93,7 @@
|
||||
Config/Makefile.Cygwin-1-5-25 Config/config.Cygwin-1-5-25.h \
|
||||
Config/Makefile.MacOSX-10-5 Config/config.MacOSX-10-5.h
|
||||
|
||||
-all: progs doc
|
||||
+all: progs
|
||||
|
||||
scmclean: gitclean
|
||||
|
||||
@@ -136,13 +136,11 @@
|
||||
strip: progs
|
||||
strip $(PROGS)
|
||||
|
||||
-install: progs $(srcdir)/doc/socat.1
|
||||
+install: progs
|
||||
mkdir -p $(DESTDIR)$(BINDEST)
|
||||
$(INSTALL) -m 755 socat $(DESTDIR)$(BINDEST)
|
||||
$(INSTALL) -m 755 procan $(DESTDIR)$(BINDEST)
|
||||
$(INSTALL) -m 755 filan $(DESTDIR)$(BINDEST)
|
||||
- mkdir -p $(DESTDIR)$(MANDEST)/man1
|
||||
- $(INSTALL) -m 644 $(srcdir)/doc/socat.1 $(DESTDIR)$(MANDEST)/man1/
|
||||
|
||||
uninstall:
|
||||
rm -f $(DESTDIR)$(BINDEST)/socat
|
||||
28
package/socat/0002-ptrdiff_t-is-defined-in-stddef.h.patch
Normal file
28
package/socat/0002-ptrdiff_t-is-defined-in-stddef.h.patch
Normal file
@@ -0,0 +1,28 @@
|
||||
From 99c55f2694fe8621ca2344eb002610dac7f9c969 Mon Sep 17 00:00:00 2001
|
||||
From: Gustavo Zacarias <gustavo@zacarias.com.ar>
|
||||
Date: Tue, 2 Feb 2016 09:34:24 -0300
|
||||
Subject: [PATCH] ptrdiff_t is defined in stddef.h
|
||||
|
||||
Status: sent upstream via email.
|
||||
|
||||
Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
|
||||
---
|
||||
nestlex.c | 2 ++
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/nestlex.c b/nestlex.c
|
||||
index f7950f0..f49482d 100644
|
||||
--- a/nestlex.c
|
||||
+++ b/nestlex.c
|
||||
@@ -4,6 +4,8 @@
|
||||
|
||||
/* a function for lexical scanning of nested character patterns */
|
||||
|
||||
+#include <stddef.h> /* ptrdiff_t */
|
||||
+
|
||||
#include "config.h"
|
||||
#include "mytypes.h"
|
||||
|
||||
--
|
||||
2.4.10
|
||||
|
||||
35
package/socat/0003-compat-set-NETDB_INTERNAL.patch
Normal file
35
package/socat/0003-compat-set-NETDB_INTERNAL.patch
Normal file
@@ -0,0 +1,35 @@
|
||||
From e7804d1750652e39c7a5803d360b29b2637a695f Mon Sep 17 00:00:00 2001
|
||||
From: Romain Naour <romain.naour@gmail.com>
|
||||
Date: Sun, 28 Aug 2016 21:04:01 +0200
|
||||
Subject: [PATCH] compat: set NETDB_INTERNAL
|
||||
|
||||
Musl doesn't provide NETDB_INTERNAL which is defined in resolv/netdb.h
|
||||
in Glibc [1].
|
||||
|
||||
Set NETDB_INTERNAL to -1 locally if not already defined.
|
||||
Based on [2].
|
||||
|
||||
[1] https://sourceware.org/git/?p=glibc.git;a=blob;f=resolv/netdb.h;h=3aba530932c7a62a4f23e3193e9186da677f552b;hb=fdfc9260b61d3d72541f18104d24c7bcb0ce5ca2#l74
|
||||
[2] http://git.alpinelinux.org/cgit/aports/tree/main/socat/netdb-internal.patch?id=5a45173b50892cb634197c30b3506ebff98d3b7d
|
||||
|
||||
Signed-off-by: Romain Naour <romain.naour@gmail.com>
|
||||
---
|
||||
compat.h | 2 ++
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/compat.h b/compat.h
|
||||
index 19a929f..4f5ee6d 100644
|
||||
--- a/compat.h
|
||||
+++ b/compat.h
|
||||
@@ -666,6 +666,8 @@ typedef int sig_atomic_t;
|
||||
|
||||
#if !defined(NETDB_INTERNAL) && defined(h_NETDB_INTERNAL)
|
||||
# define NETDB_INTERNAL h_NETDB_INTERNAL
|
||||
+#elif !defined(NETDB_INTERNAL)
|
||||
+# define NETDB_INTERNAL (-1)
|
||||
#endif
|
||||
|
||||
#ifndef INET_ADDRSTRLEN
|
||||
--
|
||||
2.5.5
|
||||
|
||||
@@ -0,0 +1,91 @@
|
||||
From 1c141194e3587cc8124e5f4512dc3030e5a104b1 Mon Sep 17 00:00:00 2001
|
||||
From: Romain Naour <romain.naour@gmail.com>
|
||||
Date: Sun, 28 Aug 2016 22:06:09 +0200
|
||||
Subject: [PATCH] xio-tun: remove if_tun.h kernel header
|
||||
|
||||
xio-tun mixes userspace and kernel headers.
|
||||
|
||||
http://wiki.musl-libc.org/wiki/FAQ#Q:_why_am_i_getting_.22error:_redefinition_of_struct_ethhdr.2Ftcphdr.2Fetc.22_.3F
|
||||
|
||||
Signed-off-by: Romain Naour <romain.naour@gmail.com>
|
||||
---
|
||||
config.h.in | 3 ---
|
||||
configure.in | 8 +-------
|
||||
sysincludes.h | 3 ---
|
||||
xio-tun.c | 6 ++++++
|
||||
4 files changed, 7 insertions(+), 13 deletions(-)
|
||||
|
||||
diff --git a/config.h.in b/config.h.in
|
||||
index 9058bf8..ed0962c 100644
|
||||
--- a/config.h.in
|
||||
+++ b/config.h.in
|
||||
@@ -258,9 +258,6 @@
|
||||
/* Define if you have the <linux/errqueue.h> header file. */
|
||||
#undef HAVE_LINUX_ERRQUEUE_H
|
||||
|
||||
-/* Define if you have the <linux/if_tun.h> header file. */
|
||||
-#undef HAVE_LINUX_IF_TUN_H
|
||||
-
|
||||
/* Define if you have the <netpacket/packet.h> header file. */
|
||||
#undef HAVE_NETPACKET_PACKET_H
|
||||
|
||||
diff --git a/configure.in b/configure.in
|
||||
index 1d2e76f..27bb3d5 100644
|
||||
--- a/configure.in
|
||||
+++ b/configure.in
|
||||
@@ -78,7 +78,7 @@ AC_CHECK_HEADERS(arpa/nameser.h)
|
||||
|
||||
AC_HEADER_RESOLV()
|
||||
|
||||
-AC_CHECK_HEADERS(termios.h linux/if_tun.h)
|
||||
+AC_CHECK_HEADERS(termios.h)
|
||||
AC_CHECK_HEADERS(net/if_dl.h)
|
||||
AC_CHECK_HEADERS(linux/types.h)
|
||||
AC_CHECK_HEADER(linux/errqueue.h, AC_DEFINE(HAVE_LINUX_ERRQUEUE_H), [], [#include <sys/time.h>
|
||||
@@ -680,12 +680,6 @@ AC_ARG_ENABLE(tun, [ --disable-tun disable TUN/TAP support],
|
||||
esac],
|
||||
[AC_MSG_RESULT(yes); WITH_TUN=1 ])
|
||||
|
||||
-#
|
||||
-if ! test "$ac_cv_header_linux_if_tun_h" = 'yes'; then
|
||||
- AC_MSG_WARN(include file linux/if_tun.h not found, disabling TUN)
|
||||
- WITH_TUN=
|
||||
-fi
|
||||
-#
|
||||
if test -n "$WITH_TUN"; then
|
||||
AC_DEFINE(WITH_TUN)
|
||||
fi
|
||||
diff --git a/sysincludes.h b/sysincludes.h
|
||||
index 98dff77..28067f4 100644
|
||||
--- a/sysincludes.h
|
||||
+++ b/sysincludes.h
|
||||
@@ -142,9 +142,6 @@
|
||||
#if HAVE_NETINET_IF_ETHER_H
|
||||
#include <netinet/if_ether.h>
|
||||
#endif
|
||||
-#if HAVE_LINUX_IF_TUN_H
|
||||
-#include <linux/if_tun.h>
|
||||
-#endif
|
||||
|
||||
#if HAVE_TERMIOS_H && _WITH_TERMIOS
|
||||
#include <termios.h>
|
||||
diff --git a/xio-tun.c b/xio-tun.c
|
||||
index 0628d27..f965a7e 100644
|
||||
--- a/xio-tun.c
|
||||
+++ b/xio-tun.c
|
||||
@@ -14,6 +14,12 @@
|
||||
|
||||
#include "xio-tun.h"
|
||||
|
||||
+/* TUNSETIFF flags from if_tun.h kernel header */
|
||||
+#define IFF_TUN 0x0001
|
||||
+#define IFF_TAP 0x0002
|
||||
+#define IFF_NO_PI 0x1000
|
||||
+
|
||||
+#define TUNSETIFF _IOW('T', 202, int)
|
||||
|
||||
static int xioopen_tun(int argc, const char *argv[], struct opt *opts, int xioflags, xiofile_t *fd, unsigned groups, int dummy1, int dummy2, int dummy3);
|
||||
|
||||
--
|
||||
2.5.5
|
||||
|
||||
7
package/socat/Config.in
Normal file
7
package/socat/Config.in
Normal file
@@ -0,0 +1,7 @@
|
||||
config BR2_PACKAGE_SOCAT
|
||||
bool "socat"
|
||||
depends on BR2_USE_MMU # fork()
|
||||
help
|
||||
Multipurpose socket relay program.
|
||||
|
||||
http://www.dest-unreach.org/socat/
|
||||
8
package/socat/socat.hash
Normal file
8
package/socat/socat.hash
Normal file
@@ -0,0 +1,8 @@
|
||||
# From http://www.dest-unreach.org/socat/download.md5sum
|
||||
md5 607a24c15bd2cb54e9328bfbbd3a1ae9 socat-1.7.3.2.tar.bz2
|
||||
# Calculated based on the hash above
|
||||
sha256 e3561f808739383eb10fada1e5d4f26883f0311b34fd0af7837d0c95ef379251 socat-1.7.3.2.tar.bz2
|
||||
# Locally calculated
|
||||
sha256 4846488cea98a2905dc75b7aa5eea721568e372447efe06b85bd896ee8c54f10 README
|
||||
sha256 8177f97513213526df2cf6184d8ff986c675afb514d4e68a404010521b880643 COPYING
|
||||
sha256 fd9e48ca316a5032069b9521f4f4b4d9b1c60365012bae1e62286bcd5bd2e761 COPYING.OpenSSL
|
||||
51
package/socat/socat.mk
Normal file
51
package/socat/socat.mk
Normal file
@@ -0,0 +1,51 @@
|
||||
################################################################################
|
||||
#
|
||||
# socat
|
||||
#
|
||||
################################################################################
|
||||
|
||||
SOCAT_VERSION = 1.7.3.2
|
||||
SOCAT_SOURCE = socat-$(SOCAT_VERSION).tar.bz2
|
||||
SOCAT_SITE = http://www.dest-unreach.org/socat/download
|
||||
SOCAT_LICENSE = GPL-2.0 with OpenSSL exception
|
||||
SOCAT_LICENSE_FILES = README COPYING COPYING.OpenSSL
|
||||
|
||||
SOCAT_CONF_ENV = sc_cv_termios_ispeed=no
|
||||
|
||||
ifeq ($(BR2_powerpc)$(BR2_powerpc64)$(BR2_powerpc64le),y)
|
||||
SOCAT_CONF_ENV += \
|
||||
sc_cv_sys_crdly_shift=12 \
|
||||
sc_cv_sys_tabdly_shift=10 \
|
||||
sc_cv_sys_csize_shift=8
|
||||
else
|
||||
SOCAT_CONF_ENV += \
|
||||
sc_cv_sys_crdly_shift=9 \
|
||||
sc_cv_sys_tabdly_shift=11 \
|
||||
sc_cv_sys_csize_shift=4
|
||||
endif
|
||||
|
||||
# We need to run autoconf to regenerate the configure script, since we patch
|
||||
# configure.in and Makefile.in. However, the package only uses autoconf and not
|
||||
# automake, so we can't use the normal autoreconf logic.
|
||||
|
||||
SOCAT_DEPENDENCIES = host-autoconf
|
||||
|
||||
ifeq ($(BR2_PACKAGE_OPENSSL),y)
|
||||
SOCAT_DEPENDENCIES += openssl
|
||||
else
|
||||
SOCAT_CONF_OPTS += --disable-openssl
|
||||
endif
|
||||
|
||||
ifeq ($(BR2_PACKAGE_READLINE),y)
|
||||
SOCAT_DEPENDENCIES += readline
|
||||
else
|
||||
SOCAT_CONF_OPTS += --disable-readline
|
||||
endif
|
||||
|
||||
define SOCAT_RUN_AUTOCONF
|
||||
(cd $(@D); $(HOST_DIR)/bin/autoconf)
|
||||
endef
|
||||
|
||||
SOCAT_PRE_CONFIGURE_HOOKS += SOCAT_RUN_AUTOCONF
|
||||
|
||||
$(eval $(autotools-package))
|
||||
Reference in New Issue
Block a user