Selaa lähdekoodia

ser2net: import from old packages feed

 - update to latest version (v2.10.0)
 - add a patch to fix compilation failures due to missing TIOCSRS485 macro
 - add license info
 - add myself as maintainer

Signed-off-by: Nicolas Thill <nico@openwrt.org>
Nicolas Thill 10 vuotta sitten
vanhempi
commit
e2b6aedea8

+ 50
- 0
net/ser2net/Makefile Näytä tiedosto

@@ -0,0 +1,50 @@
1
+#
2
+# Copyright (C) 2006-2015 OpenWrt.org
3
+#
4
+# This is free software, licensed under the GNU General Public License v2.
5
+# See /LICENSE for more information.
6
+#
7
+
8
+include $(TOPDIR)/rules.mk
9
+
10
+PKG_NAME:=ser2net
11
+PKG_VERSION:=2.10.0
12
+PKG_RELEASE:=1
13
+
14
+PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
15
+PKG_SOURCE_URL:=@SF/ser2net
16
+PKG_MD5SUM:=cd937041144de83d41d811521e72158c
17
+
18
+PKG_LICENSE:=GPL-2.0+
19
+PKG_LICENSE_FILES:=COPYING
20
+PKG_MAINTAINER:=Nicolas Thill <nico@openwrt.org>
21
+
22
+PKG_FIXUP:=autoreconf
23
+PKG_INSTALL:=1
24
+
25
+include $(INCLUDE_DIR)/package.mk
26
+
27
+define Package/ser2net
28
+  SECTION:=net
29
+  CATEGORY:=Network
30
+  TITLE:=Serial to Network Proxy
31
+  URL:=http://sourceforge.net/projects/ser2net/
32
+endef
33
+
34
+define Package/ser2net/description
35
+  This project provides a proxy that allows telnet/tcp connections to be made to
36
+  serial ports on a machine.
37
+endef
38
+
39
+define Package/ser2net/conffiles
40
+/etc/ser2net.conf
41
+endef
42
+
43
+define Package/ser2net/install
44
+	$(INSTALL_DIR) $(1)/usr/sbin
45
+	$(CP) $(PKG_INSTALL_DIR)/usr/sbin/ser2net $(1)/usr/sbin/
46
+	$(INSTALL_DIR) $(1)/etc
47
+	$(INSTALL_CONF) $(PKG_BUILD_DIR)/ser2net.conf $(1)/etc/
48
+endef
49
+
50
+$(eval $(call BuildPackage,ser2net))

+ 59
- 0
net/ser2net/patches/001-fix_TIOCSRS485_undeclared_error.patch Näytä tiedosto

@@ -0,0 +1,59 @@
1
+ser2net: Fix compilation failures due to missing TIOCSRS485 macro
2
+
3
+Patch sent upstream:
4
+	https://sourceforge.net/p/ser2net/mailman/message/32905302/
5
+
6
+Signed-off-by: Vicente Olivert Riera <Vincent.Riera@imgtec.com>
7
+
8
+From: Yegor Yefremov <yegorslists@googlemail.com>
9
+
10
+include <asm-generic/ioctls.h> fixes compilations for systems,
11
+where <asm-generic/ioctls.h> won't be included automatically.
12
+
13
+Move special Linux includes to dataxfer.h.
14
+
15
+Signed-off-by: Yegor Yefremov <yegorslists@googlemail.com>
16
+---
17
+ dataxfer.h | 5 +++--
18
+ devcfg.c   | 2 --
19
+ 2 files changed, 3 insertions(+), 4 deletions(-)
20
+
21
+--- a/dataxfer.h
22
++++ b/dataxfer.h
23
+@@ -20,8 +20,6 @@
24
+ #ifndef DATAXFER
25
+ #define DATAXFER
26
+ 
27
+-#include <linux/serial.h>
28
+-
29
+ #include "controller.h"
30
+ 
31
+ #ifdef USE_UUCP_LOCKING
32
+@@ -30,6 +28,9 @@ extern int uucp_locking_enabled;
33
+ 
34
+ #ifdef linux
35
+ 
36
++#include <linux/serial.h>
37
++#include <asm-generic/ioctls.h>
38
++
39
+ #define USE_RS485_FEATURE
40
+ 
41
+ /* Check, if the toolchain provides serial_rs485 structure and macros */
42
+--- a/devcfg.c
43
++++ b/devcfg.c
44
+@@ -18,7 +18,6 @@
45
+  */
46
+ 
47
+ /* This code handles generating the configuration for the serial port. */
48
+-
49
+ #include <unistd.h>
50
+ #include <termios.h>
51
+ #include <sys/ioctl.h>
52
+@@ -31,7 +30,6 @@
53
+ #include <signal.h>
54
+ #include <errno.h>
55
+ #include <syslog.h>
56
+-#include <linux/serial.h>
57
+ 
58
+ #include "ser2net.h"
59
+ #include "selector.h"