Added radiusclient-ng, libradiusclient-ng. Config.in may need some tweaking to be...
[openwrt/svn-archive/archive.git] / openwrt / package / radiusclient-ng / Makefile
1 # $Id: Makefile 1146 2005-06-05 13:32:28Z nbd $
2
3 include $(TOPDIR)/rules.mk
4
5 PKG_NAME:=radiusclient-ng
6 PKG_VERSION:=0.5.2
7 PKG_RELEASE:=1
8 PKG_MD5SUM:=c54eb70e964bdd22dd44b39a9b4df8ca
9
10 PKG_SOURCE_URL:=http://download.berlios.de/radiusclient-ng/
11 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
12 PKG_CAT:=zcat
13
14 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(PKG_VERSION)
15 PKG_INSTALL_DIR:=$(PKG_BUILD_DIR)/ipkg-install
16
17 include $(TOPDIR)/package/rules.mk
18
19 $(eval $(call PKG_template,RADIUSCLIENT_NG,radiusclient-ng,$(PKG_VERSION)-$(PKG_RELEASE),$(ARCH)))
20 $(eval $(call PKG_template,LIBRADIUSCLIENT_NG,libradiusclient-ng,$(PKG_VERSION)-$(PKG_RELEASE),$(ARCH)))
21
22 $(PKG_BUILD_DIR)/.configured:
23 (cd $(PKG_BUILD_DIR); rm -rf config.cache; \
24 $(TARGET_CONFIGURE_OPTS) \
25 CFLAGS="$(TARGET_CFLAGS)" \
26 CPPFLAGS="-I$(STAGING_DIR)/usr/include" \
27 LDFLAGS="-L$(STAGING_DIR)/usr/lib" \
28 ac_cv_func_getdomainname=yes \
29 ./configure \
30 --target=$(GNU_TARGET_NAME) \
31 --host=$(GNU_TARGET_NAME) \
32 --build=$(GNU_HOST_NAME) \
33 --program-prefix="" \
34 --program-suffix="" \
35 --prefix=/usr \
36 --exec-prefix=/usr \
37 --bindir=/usr/bin \
38 --datadir=/usr/share \
39 --includedir=/usr/include \
40 --infodir=/usr/share/info \
41 --libdir=/usr/lib \
42 --libexecdir=/usr/lib \
43 --localstatedir=/var \
44 --mandir=/usr/share/man \
45 --sbindir=/usr/sbin \
46 --sysconfdir=/etc \
47 $(DISABLE_NLS) \
48 $(DISABLE_LARGEFILE) \
49 );
50 touch $@
51
52 $(PKG_BUILD_DIR)/.built:
53 $(MAKE) -C $(PKG_BUILD_DIR) \
54 DESTDIR=$(PKG_INSTALL_DIR) \
55 install-exec install-data
56 touch $@
57
58 $(IPKG_RADIUSCLIENT_NG):
59 mkdir -p $(IDIR_RADIUSCLIENT_NG)/usr
60 $(CP) $(PKG_INSTALL_DIR)/usr/sbin $(IDIR_RADIUSCLIENT_NG)/usr/
61 $(CP) $(PKG_INSTALL_DIR)/etc $(IDIR_RADIUSCLIENT_NG)/
62 $(RSTRIP) $(IDIR_RADIUSCLIENT_NG)/
63 $(IPKG_BUILD) $(IDIR_RADIUSCLIENT_NG) $(PACKAGE_DIR)
64
65 $(IPKG_LIBRADIUSCLIENT_NG):
66 mkdir -p $(IDIR_LIBRADIUSCLIENT_NG)/usr
67 $(CP) $(PKG_INSTALL_DIR)/usr/lib $(IDIR_LIBRADIUSCLIENT_NG)/usr/
68 $(RSTRIP) $(IDIR_LIBRADIUSCLIENT_NG)/
69 $(IPKG_BUILD) $(IDIR_LIBRADIUSCLIENT_NG) $(PACKAGE_DIR)
70
71 $(STAGING_DIR)/usr/lib/libradiusclient-ng.so: $(PKG_BUILD_DIR)/.built
72 mkdir -p $(STAGING_DIR)/usr/include
73 $(CP) $(PKG_INSTALL_DIR)/usr/include/ $(STAGING_DIR)/usr/
74 mkdir -p $(STAGING_DIR)/usr/lib/
75 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libradiusclient-ng{a,la,so}* $(STAGING_DIR)/usr/lib/
76 touch $@
77
78 mostlyclean:
79 $(MAKE) -C $(PKG_BUILD_DIR) clean
80 rm -f $(PKG_BUILD_DIR)/.built