[packages] quagga-unstable: Update to v0.99.14 and refresh patches
[openwrt/svn-archive/archive.git] / utils / bandwidthd / Makefile
index 4a9aac4481d293aaf0411a34672761ffcf5d3912..7669eeb349480d2bab78b534f637c2af27168c1e 100644 (file)
@@ -1,10 +1,9 @@
 # 
-# Copyright (C) 2006-2008 OpenWrt.org
+# Copyright (C) 2006-2009 OpenWrt.org
 #
 # This is free software, licensed under the GNU General Public License v2.
 # See /LICENSE for more information.
 #
-# $Id: Makefile 11018 2008-05-03 12:11:35Z nico $
 
 include $(TOPDIR)/rules.mk
 
@@ -37,15 +36,20 @@ CONFIGURE_ARGS += \
        ac_cv_file__usr_pkg_include=no \
        ac_cv_file__usr_local_pgsql_lib=no \
        ac_cv_file__usr_local_pgsql_include=no \
+       ac_cv_lib_pq_PQconnectdb=no \
 
-EXTRA_CFLAGS+=-I$(STAGING_DIR)/usr/include -I$(STAGING_DIR)/include
-EXTRA_LDFLAGS+=-L$(STAGING_DIR)/usr/lib -Wl,-rpath-link,$(STAGING_DIR)/usr/lib
+EXTRA_CFLAGS+= $(TARGET_CPPFLAGS)
+EXTRA_LDFLAGS+= $(TARGET_LDFLAGS) -Wl,-rpath-link,$(STAGING_DIR)/usr/lib
 
 define Package/bandwidthd/install
        $(INSTALL_DIR) $(1)/usr/sbin
        $(INSTALL_BIN) $(PKG_BUILD_DIR)/bandwidthd $(1)/usr/sbin/
-       $(INSTALL_DIR) $(1)/etc
-       $(INSTALL_DATA) $(PKG_BUILD_DIR)/etc/bandwidthd.conf $(1)/etc/
+       $(INSTALL_DIR) $(1)/etc/config
+       $(INSTALL_DATA) ./files/bandwidthd.config $(1)/etc/config/bandwidthd
+       $(INSTALL_DIR) $(1)/etc/init.d
+       $(INSTALL_BIN) ./files/bandwidthd.init $(1)/etc/init.d/bandwidthd
+       $(INSTALL_DIR) $(1)/www
+       $(INSTALL_DATA) $(PKG_BUILD_DIR)/htdocs/legend.gif $(1)/www/
 endef
 
 $(eval $(call BuildPackage,bandwidthd))