diff --git a/net/ser2net/Makefile b/net/ser2net/Makefile new file mode 100644 index 000000000..ec0b5731f --- /dev/null +++ b/net/ser2net/Makefile @@ -0,0 +1,50 @@ +# +# Copyright (C) 2006-2015 OpenWrt.org +# +# This is free software, licensed under the GNU General Public License v2. +# See /LICENSE for more information. +# + +include $(TOPDIR)/rules.mk + +PKG_NAME:=ser2net +PKG_VERSION:=2.10.0 +PKG_RELEASE:=1 + +PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz +PKG_SOURCE_URL:=@SF/ser2net +PKG_MD5SUM:=cd937041144de83d41d811521e72158c + +PKG_LICENSE:=GPL-2.0+ +PKG_LICENSE_FILES:=COPYING +PKG_MAINTAINER:=Nicolas Thill + +PKG_FIXUP:=autoreconf +PKG_INSTALL:=1 + +include $(INCLUDE_DIR)/package.mk + +define Package/ser2net + SECTION:=net + CATEGORY:=Network + TITLE:=Serial to Network Proxy + URL:=http://sourceforge.net/projects/ser2net/ +endef + +define Package/ser2net/description + This project provides a proxy that allows telnet/tcp connections to be made to + serial ports on a machine. +endef + +define Package/ser2net/conffiles +/etc/ser2net.conf +endef + +define Package/ser2net/install + $(INSTALL_DIR) $(1)/usr/sbin + $(CP) $(PKG_INSTALL_DIR)/usr/sbin/ser2net $(1)/usr/sbin/ + $(INSTALL_DIR) $(1)/etc + $(INSTALL_CONF) $(PKG_BUILD_DIR)/ser2net.conf $(1)/etc/ +endef + +$(eval $(call BuildPackage,ser2net)) diff --git a/net/ser2net/patches/001-fix_TIOCSRS485_undeclared_error.patch b/net/ser2net/patches/001-fix_TIOCSRS485_undeclared_error.patch new file mode 100644 index 000000000..370d0b9b0 --- /dev/null +++ b/net/ser2net/patches/001-fix_TIOCSRS485_undeclared_error.patch @@ -0,0 +1,59 @@ +ser2net: Fix compilation failures due to missing TIOCSRS485 macro + +Patch sent upstream: + https://sourceforge.net/p/ser2net/mailman/message/32905302/ + +Signed-off-by: Vicente Olivert Riera + +From: Yegor Yefremov + +include fixes compilations for systems, +where won't be included automatically. + +Move special Linux includes to dataxfer.h. + +Signed-off-by: Yegor Yefremov +--- + dataxfer.h | 5 +++-- + devcfg.c | 2 -- + 2 files changed, 3 insertions(+), 4 deletions(-) + +--- a/dataxfer.h ++++ b/dataxfer.h +@@ -20,8 +20,6 @@ + #ifndef DATAXFER + #define DATAXFER + +-#include +- + #include "controller.h" + + #ifdef USE_UUCP_LOCKING +@@ -30,6 +28,9 @@ extern int uucp_locking_enabled; + + #ifdef linux + ++#include ++#include ++ + #define USE_RS485_FEATURE + + /* Check, if the toolchain provides serial_rs485 structure and macros */ +--- a/devcfg.c ++++ b/devcfg.c +@@ -18,7 +18,6 @@ + */ + + /* This code handles generating the configuration for the serial port. */ +- + #include + #include + #include +@@ -31,7 +30,6 @@ + #include + #include + #include +-#include + + #include "ser2net.h" + #include "selector.h"