1f2dbb1268d5c94423cce34102f8f8629f2c76ed
[openwrt.git] / target / linux / package / openswan / Makefile
1 # $Id$
2
3 include $(TOPDIR)/rules.mk
4 include ../../rules.mk
5
6 PKG_NAME:=openswan
7 PKG_VERSION:=2.4.4
8 PKG_RELEASE:=2
9 PKG_MD5SUM:=bd1a46c64727674149de61da2a32ca63
10
11 PKG_SOURCE_URL:=http://www.openswan.org/download
12 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
13 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
14 PKG_CAT:=zcat
15
16 include $(TOPDIR)/package/rules.mk
17
18 ifeq ($(KERNEL_DIR),)
19 KERNEL_DIR:=$(LINUX_DIR)
20 endif
21
22 $(eval $(call PKG_template,KMOD_OPENSWAN,kmod-openswan,$(LINUX_VERSION)+$(PKG_VERSION)-$(BOARD)-$(PKG_RELEASE),$(ARCH),kernel ($(LINUX_VERSION)-$(BOARD)-$(KERNEL_RELEASE))))
23
24 FLAGS := $(TARGET_CFLAGS) -I$(PKG_BUILD_DIR)/linux/include -L$(STAGING_DIR)/usr/lib -I$(STAGING_DIR)/usr/include
25
26 $(PKG_BUILD_DIR)/.built:
27 $(MAKE) -C $(PKG_BUILD_DIR) \
28 $(TARGET_CONFIGURE_OPTS) \
29 KERNEL_RELEASE="$(KERNEL_RELEASE)" \
30 KERNELSRC="$(KERNEL_DIR)" \
31 ARCH="$(LINUX_KARCH)" \
32 CROSS_COMPILE="$(TARGET_CROSS)" \
33 USERCOMPILE="$(FLAGS)" \
34 AS="$(TARGET_CC) -c $(TARGET_CFLAGS)" \
35 module
36
37 $(IPKG_KMOD_OPENSWAN):
38 mkdir -p $(IDIR_KMOD_OPENSWAN)/lib/modules/$(LINUX_VERSION)
39 cp -fpR $(PKG_BUILD_DIR)/modobj*/ipsec.$(LINUX_KMOD_SUFFIX) $(IDIR_KMOD_OPENSWAN)/lib/modules/$(LINUX_VERSION)/
40 $(IPKG_BUILD) $(IDIR_KMOD_OPENSWAN) $(PACKAGE_DIR)
This page took 0.037547 seconds and 3 git commands to generate.