3 include $(TOPDIR)/rules.mk
8 PKG_MD5SUM:=ca8e53a766faec831882831364568421
10 PKG_SOURCE_URL:=http://matt.ucc.asn.au/dropbear/releases/
11 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
14 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
16 include $(TOPDIR)/package/rules.mk
18 $(eval $(call PKG_template,DROPBEAR,$(PKG_NAME),$(PKG_VERSION)-$(PKG_RELEASE),$(ARCH)))
19 $(eval $(call PKG_template,DBCONVERT,dropbearconvert,$(PKG_VERSION)-$(PKG_RELEASE),$(ARCH)))
21 $(PKG_BUILD_DIR)/.configured:
22 $(SED) 's,^/\* #define PKG_MULTI.*,#define PKG_MULTI,g' $(PKG_BUILD_DIR)/options.h
23 $(SED) 's,^#define DO_HOST_LOOKUP,/* & */,g' $(PKG_BUILD_DIR)/options.h
24 (cd $(PKG_BUILD_DIR); rm -rf config.cache; \
26 $(TARGET_CONFIGURE_OPTS) \
27 CFLAGS="$(TARGET_CFLAGS) -I$(STAGING_DIR)/usr/include" \
28 LDFLAGS="-L$(STAGING_DIR)/usr/lib" \
30 --target=$(GNU_TARGET_NAME) \
31 --host=$(GNU_TARGET_NAME) \
32 --build=$(GNU_HOST_NAME) \
38 --datadir=/usr/share \
39 --includedir=/usr/include \
40 --infodir=/usr/share/info \
42 --libexecdir=/usr/lib \
43 --localstatedir=/var \
44 --mandir=/usr/share/man \
47 $(DISABLE_LARGEFILE) \
61 --disable-pututxline \
66 $(PKG_BUILD_DIR)/.built:
67 $(MAKE) -C $(PKG_BUILD_DIR) \
69 PROGRAMS="dropbear dbclient dropbearkey scp" \
71 $(MAKE) -C $(PKG_BUILD_DIR) \
73 PROGRAMS="dropbearconvert"
77 mkdir -p $(IDIR_DBCONVERT)/usr/bin
78 install -m 755 $(PKG_BUILD_DIR)/dropbearconvert \
79 $(IDIR_DBCONVERT)/usr/bin/dropbearconvert
80 $(IPKG_BUILD) $(IDIR_DBCONVERT) $(PACKAGE_DIR)
83 mkdir -p $(IDIR_DROPBEAR)/usr/bin
84 mkdir -p $(IDIR_DROPBEAR)/usr/sbin
85 install -m 755 $(PKG_BUILD_DIR)/dropbearmulti \
86 $(IDIR_DROPBEAR)/usr/sbin/dropbear
87 $(STRIP) $(IDIR_DROPBEAR)/usr/sbin/dropbear
88 ln -sf ../sbin/dropbear $(IDIR_DROPBEAR)/usr/bin/scp
89 ln -sf ../sbin/dropbear $(IDIR_DROPBEAR)/usr/bin/ssh
90 ln -sf ../sbin/dropbear $(IDIR_DROPBEAR)/usr/bin/dbclient
91 ln -sf ../sbin/dropbear $(IDIR_DROPBEAR)/usr/bin/dropbearkey
92 mkdir -p $(IDIR_DROPBEAR)/etc/init.d
93 install -m 755 ./files/S50dropbear $(IDIR_DROPBEAR)/etc/init.d/
94 $(IPKG_BUILD) $(IDIR_DROPBEAR) $(PACKAGE_DIR)