InstallDev should be using (1) and not (STAGING_DIR)
[openwrt/svn-archive/archive.git] / libs / libpam / Makefile
1 #
2 # Copyright (C) 2006 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7 # $Id$
8
9 include $(TOPDIR)/rules.mk
10
11 PKG_NAME:=libpam
12 PKG_VERSION:=0.99.6.3
13 PKG_RELEASE:=1
14
15 PKG_SOURCE:=Linux-PAM-$(PKG_VERSION).tar.gz
16 PKG_SOURCE_URL:=http://www.kernel.org/pub/linux/libs/pam/pre/library/
17 PKG_MD5SUM:=0f17f7105faa82a51dfbeb6b08a1ca29
18 PKG_CAT:=zcat
19
20 PKG_BUILD_DIR:=$(BUILD_DIR)/Linux-PAM-$(PKG_VERSION)
21 PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
22
23 include $(INCLUDE_DIR)/package.mk
24
25 define Package/libpam
26 SECTION:=libs
27 CATEGORY:=Libraries
28 TITLE:=free implementation of the following DCE-RFC from Sunsoft.
29 DESCRIPTION:=\
30 Linux-PAM is a free implementation of the following DCE-RFC from Sunsoft. \\\
31 URL:=http://www.kernel.org/pub/linux/libs/pam
32 endef
33
34 define Build/Configure
35 $(call Build/Configure/Default, \
36 --enable-shared \
37 --enable-static \
38 --enable-pamlocking \
39 --disable-prelude \
40 --disable-lckpwdf \
41 --disable-selinux \
42 --disable-nls \
43 --disable-rpath \
44 )
45 endef
46
47 define Build/Compile
48 $(MAKE) -C $(PKG_BUILD_DIR) \
49 DESTDIR="$(PKG_INSTALL_DIR)" \
50 all install
51 endef
52
53 define Build/InstallDev
54 mkdir -p $(1)/usr/lib $(1)/lib
55 mkdir -p $(1)/usr/include
56 $(CP) $(PKG_INSTALL_DIR)/lib/* $(1)/usr/lib/
57 $(CP) $(PKG_INSTALL_DIR)/usr/include/* $(1)/usr/include
58 endef
59
60 define Build/UninstallDev
61 rm -rf \
62 $(STAGING_DIR)/usr/include/security \
63 $(STAGING_DIR)/lib/libpam.* \
64 $(STAGING_DIR)/lib/security
65 endef
66
67 define Package/libpam/install
68 $(INSTALL_DIR) $(1)/lib
69 $(INSTALL_DIR) $(1)/etc
70 $(INSTALL_DIR) $(1)/usr/sbin
71 $(CP) $(PKG_INSTALL_DIR)/* $(1)/lib/
72 $(CP) $(PKG_INSTALL_DIR)/etc/* $(1)/etc/
73 $(CP) $(PKG_INSTALL_DIR)/usr/sbin/* $(1)/usr/sbin/
74 endef
75
76 $(eval $(call BuildPackage,libpam))