2 # Copyright (C) 2006 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
9 include $(TOPDIR
)/rules.mk
10 include $(INCLUDE_DIR
)/kernel.mk
16 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.gz
17 PKG_SOURCE_URL
:=http
://www.openswan.org
/download
18 PKG_MD5SUM
:=918cc56ccf8e5d14cd2047e47450b34a
20 include $(INCLUDE_DIR
)/package.mk
22 define Package
/openswan
/Default
24 URL
:=http
://www.openswan.org
/
27 define Package
/openswan
/Default
/description
28 Openswan is an IPsec implementation for Linux.
31 define Package
/openswan
32 $(call Package
/openswan
/Default
)
35 DEPENDS
:=@LINUX_2_4
+kmod-openswan
+libgmp
+ip
37 URL
:=http
://www.openswan.org
/
40 define Package
/openswan
/description
41 $(call Package
/openswan
/Default
/description
)
42 This package contains the Openswan user-land daemon.
45 define KernelPackage
/openswan
46 $(call Package
/openswan
/Default
)
47 SUBMENU
:=Network Support
49 TITLE
+= (kernel module
)
50 FILES
:=$(PKG_BUILD_DIR
)/modobj
*/ipsec.
$(LINUX_KMOD_SUFFIX
)
53 define KernelPackage
/openswan
/description
54 $(call Package
/openswan
/Default
/description
)
55 This package contains the Openswan kernel module.
60 LINUX_RELEASE
="$(LINUX_RELEASE)" \
61 KERNELSRC
="$(LINUX_DIR)" \
62 ARCH
="$(LINUX_KARCH)" \
63 CROSS_COMPILE
="$(TARGET_CROSS)" \
64 USERCOMPILE
="$(TARGET_CFLAGS) -I./linux/include $(TARGET_CPPFLAGS) $(TARGET_LDFLAGS)" \
65 IPSECDIR
="/usr/lib/ipsec" \
69 $(MAKE
) -C
$(PKG_BUILD_DIR
) \
70 $(TARGET_CONFIGURE_OPTS
) \
72 LDFLAGS
="$(TARGET_LDFLAGS)" \
73 DESTDIR
="$(PKG_INSTALL_DIR)" \
74 programs module
install
77 define Package
/openswan
/install
78 $(CP
) $(PKG_INSTALL_DIR
)/* $(1)
79 $(INSTALL_DIR
) $(1)/etc
/init.d
80 $(CP
) .
/files
/ipsec.init
$(1)/etc
/init.d
/ipsec
85 find
$(1) -name \
*.old | xargs
rm -rf
88 $(eval
$(call BuildPackage
,openswan
))
89 $(eval
$(call KernelPackage
,openswan
))