replace lots of manual install commands with INSTALL_* variables
[packages.git] / net / socat / Makefile
1 #
2 # Copyright (C) 2006 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7 # $Id$
8
9 include $(TOPDIR)/rules.mk
10
11 PKG_NAME:=socat
12 PKG_VERSION:=1.4.3.0
13 PKG_RELEASE:=2
14
15 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
16 PKG_SOURCE_URL:=http://www.dest-unreach.org/socat/download/
17 PKG_MD5SUM:=ce574e75c2fda4456e8efd4efb86ec5e
18 PKG_CAT:=bzcat
19
20 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-1.4
21 PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
22
23 include $(INCLUDE_DIR)/package.mk
24
25 define Package/socat
26   SECTION:=net
27   CATEGORY:=Network
28   DEPENDS:=+libopenssl +libpthread
29   TITLE:=A multipurpose relay (SOcket CAT)
30   DESCRIPTION:=\
31         SoCat (for SOcket CAT) establishes two bidirectional byte streams and \\\
32         transfers data between them.\\\
33         Data channels may be files, pipes, devices (terminal or modem, etc.), or \\\
34         sockets (Unix, IPv4, IPv6, raw, UDP, TCP, SSL). It provides forking, \\\
35         logging and tracing, different modes for interprocess communication and \\\
36         many more options.
37   URL:=http://www.dest-unreach.org/socat/
38 endef
39
40 define Build/Configure
41         $(call Build/Configure/Default, \
42                 --disable-libwrap \
43                 --disable-readline \
44                 --disable-termios \
45                 , \
46                 sc_cv_termios_ispeed="no" \
47         )
48 endef
49
50 define Build/Compile    
51         $(MAKE) -C $(PKG_BUILD_DIR) \
52                 DESTDIR="$(PKG_INSTALL_DIR)" \
53                 all install
54 endef
55
56 define Package/socat/install    
57         $(INSTALL_DIR) $(1)/usr/bin
58         $(CP) $(PKG_INSTALL_DIR)/usr/bin/socat $(1)/usr/bin/
59 endef
60
61 $(eval $(call BuildPackage,socat))