clean up .svn and CVS directories for every package
[openwrt.git] / package / dropbear / Makefile
1 # $Id$
2
3 include $(TOPDIR)/rules.mk
4
5 PKG_NAME:=dropbear
6 PKG_VERSION:=0.48.1
7 PKG_RELEASE:=1
8
9 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
10 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
11 PKG_SOURCE_URL:=http://matt.ucc.asn.au/dropbear/releases/
12 PKG_MD5SUM:=ca8e53a766faec831882831364568421
13 PKG_CAT:=zcat
14
15 include $(TOPDIR)/package/rules.mk
16
17 define Package/dropbear
18 SECTION:=base
19 CATEGORY:=Base system
20 DEFAULT:=y
21 TITLE:=Small SSH 2 client/server
22 DESCRIPTION:=A small SSH 2 server/client designed for small memory environments.
23 URL:=http://matt.ucc.asn.au/dropbear/
24 endef
25
26 define Package/dropbearconvert
27 $(call Package/dropbear)
28 TITLE:=Utility for converting SSH keys
29 DESCRIPTION:=Utility for converting SSH keys
30 DEPENDS:=+zlib
31 endef
32
33 define Build/Configure
34 $(SED) 's,^/\* #define PKG_MULTI.*,#define PKG_MULTI,g' $(PKG_BUILD_DIR)/options.h
35 $(SED) 's,^#define DO_HOST_LOOKUP,/* & */,g' $(PKG_BUILD_DIR)/options.h
36 (cd $(PKG_BUILD_DIR); rm -rf config.cache; \
37 autoconf; \
38 $(TARGET_CONFIGURE_OPTS) \
39 CFLAGS="$(TARGET_CFLAGS) -I$(STAGING_DIR)/usr/include" \
40 LDFLAGS="-L$(STAGING_DIR)/usr/lib" \
41 ./configure \
42 --target=$(GNU_TARGET_NAME) \
43 --host=$(GNU_TARGET_NAME) \
44 --build=$(GNU_HOST_NAME) \
45 --program-prefix="" \
46 --program-suffix="" \
47 --prefix=/usr \
48 --exec-prefix=/usr \
49 --bindir=/usr/bin \
50 --datadir=/usr/share \
51 --includedir=/usr/include \
52 --infodir=/usr/share/info \
53 --libdir=/usr/lib \
54 --libexecdir=/usr/lib \
55 --localstatedir=/var \
56 --mandir=/usr/share/man \
57 --sbindir=/usr/sbin \
58 --sysconfdir=/etc \
59 $(DISABLE_LARGEFILE) \
60 $(DISABLE_NLS) \
61 --with-shared \
62 --disable-pam \
63 --enable-openpty \
64 --enable-syslog \
65 --disable-shadow \
66 --disable-lastlog \
67 --disable-utmp \
68 --disable-utmpx \
69 --disable-wtmp \
70 --disable-wtmpx \
71 --disable-loginfunc \
72 --disable-pututline \
73 --disable-pututxline \
74 --disable-zlib \
75 );
76 endef
77
78 define Build/Compile
79 $(MAKE) -C $(PKG_BUILD_DIR) \
80 LD=$(TARGET_CC) \
81 PROGRAMS="dropbear dbclient dropbearkey scp" \
82 MULTI=1 SCPPROGRESS=1
83 $(MAKE) -C $(PKG_BUILD_DIR) \
84 LD=$(TARGET_CC) \
85 PROGRAMS="dropbearconvert"
86 endef
87
88 define Package/dropbear/install
89 mkdir -p $(1)/usr/bin
90 mkdir -p $(1)/usr/sbin
91 install -m 755 $(PKG_BUILD_DIR)/dropbearmulti \
92 $(1)/usr/sbin/dropbear
93 ln -sf ../sbin/dropbear $(1)/usr/bin/scp
94 ln -sf ../sbin/dropbear $(1)/usr/bin/ssh
95 ln -sf ../sbin/dropbear $(1)/usr/bin/dbclient
96 ln -sf ../sbin/dropbear $(1)/usr/bin/dropbearkey
97 mkdir -p $(1)/etc/init.d
98 install -m 755 ./files/S50dropbear $(1)/etc/init.d/
99 endef
100
101 define Package/dropbearconvert/install
102 mkdir -p $(1)/usr/bin
103 install -m 755 $(PKG_BUILD_DIR)/dropbearconvert \
104 $(1)/usr/bin/dropbearconvert
105 endef
106
107 $(eval $(call BuildPackage,dropbear))
108 $(eval $(call BuildPackage,dropbearconvert))
This page took 0.04079 seconds and 5 git commands to generate.