source: packages/net/ipsec-tools/Makefile @ 23378

Last change on this file since 23378 was 23378, checked in by mb, 6 years ago

ipsec-tools: Fix compile on linux-2.6.36

  • Property svn:copyright set to Copyright (C) 2006 OpenWrt.org
  • Property svn:eol-style set to native
File size: 2.3 KB
Line 
1#
2# Copyright (C) 2006-2010 OpenWrt.org
3#
4# This is free software, licensed under the GNU General Public License v2.
5# See /LICENSE for more information.
6#
7
8include $(TOPDIR)/rules.mk
9include $(INCLUDE_DIR)/kernel.mk
10
11PKG_NAME:=ipsec-tools
12PKG_VERSION:=0.7.3
13PKG_RELEASE:=3
14
15PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
16PKG_SOURCE_URL:=@SF/ipsec-tools
17PKG_MD5SUM:=821bd84e8d4ad5a93bf594b8b3d66e1e
18
19PKG_INSTALL:=1
20
21include $(INCLUDE_DIR)/package.mk
22
23define Package/ipsec-tools
24  SECTION:=net
25  CATEGORY:=Network
26  DEPENDS:=@!LINUX_2_4 +libopenssl +kmod-ipsec
27  TITLE:=IPsec management tools
28  URL:=http://ipsec-tools.sourceforge.net/
29endef
30
31CONFIGURE_ARGS += \
32        --enable-shared \
33        --enable-static \
34        --with-kernel-headers="$(LINUX_DIR)/include" \
35        --without-readline \
36        --with-openssl="$(STAGING_DIR)/usr" \
37        --without-libradius \
38        --without-libpam \
39        --enable-dpd \
40        --enable-hybrid \
41        --enable-security-context=no \
42        --enable-natt \
43        --enable-adminport
44
45# override CFLAGS holding "-Werror" that break builds on compile warnings
46MAKE_FLAGS+=\
47        CFLAGS="$(TARGET_CFLAGS) $(EXTRA_CFLAGS) $(TARGET_CPPFLAGS) $(EXTRA_CPPFLAGS)"
48
49define Build/Prepare
50        $(call Build/Prepare/Default)
51        chmod -R u+w $(PKG_BUILD_DIR)
52endef
53
54define Build/Configure
55        (cd $(PKG_BUILD_DIR); touch \
56                configure.ac \
57                aclocal.m4 \
58                Makefile.in \
59                config.h.in \
60                configure \
61        );
62        $(call Build/Configure/Default)
63        echo "#undef HAVE_SHADOW_H" >> $(PKG_BUILD_DIR)/config.h
64endef
65
66define Package/ipsec-tools/install
67        $(INSTALL_DIR) $(1)/etc
68        $(INSTALL_CONF) $(PKG_BUILD_DIR)/src/racoon/samples/racoon.conf $(1)/etc/
69        $(SED) 's|@sysconfdir_x@|/etc|g' $(1)/etc/racoon.conf
70        $(INSTALL_DIR) $(1)/etc/racoon
71        $(INSTALL_CONF) $(PKG_BUILD_DIR)/src/racoon/samples/psk.txt $(1)/etc/racoon/
72        $(INSTALL_DIR) $(1)/usr/lib
73        $(CP) $(PKG_INSTALL_DIR)/usr/lib/libipsec.so.* $(1)/usr/lib/
74        $(CP) $(PKG_INSTALL_DIR)/usr/lib/libracoon.so.* $(1)/usr/lib/
75        $(INSTALL_DIR) $(1)/usr/sbin
76        $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/plainrsa-gen $(1)/usr/sbin/
77        $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/racoon $(1)/usr/sbin/
78        $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/racoonctl $(1)/usr/sbin/
79        $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/setkey $(1)/usr/sbin/
80endef
81
82define Package/ipsec-tools/conffiles
83/etc/racoon.conf
84/etc/racoon/psk.txt
85endef
86
87$(eval $(call BuildPackage,ipsec-tools))
Note: See TracBrowser for help on using the repository browser.