2
0

Makefile 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. #
  2. # Copyright (C) 2006-2009 OpenWrt.org
  3. #
  4. # This is free software, licensed under the GNU General Public License v2.
  5. # See /LICENSE for more information.
  6. #
  7. include $(TOPDIR)/rules.mk
  8. PKG_NAME:=dnsmasq
  9. PKG_VERSION:=2.50
  10. PKG_RELEASE:=2
  11. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
  12. PKG_SOURCE_URL:=http://thekelleys.org.uk/dnsmasq
  13. PKG_MD5SUM:=f7b1e17c590e493039537434c57c9de7
  14. include $(INCLUDE_DIR)/package.mk
  15. define Package/dnsmasq
  16. SECTION:=net
  17. CATEGORY:=Base system
  18. TITLE:=A lightweight DNS and DHCP server
  19. URL:=http://www.thekelleys.org.uk/dnsmasq/
  20. endef
  21. define Package/dnsmasq/description
  22. It is intended to provide coupled DNS and DHCP service to a LAN.
  23. endef
  24. define Package/dnsmasq/conffiles
  25. /etc/config/dhcp
  26. /etc/dnsmasq.conf
  27. endef
  28. define Build/Compile
  29. $(MAKE) -C $(PKG_BUILD_DIR) \
  30. $(TARGET_CONFIGURE_OPTS) \
  31. CFLAGS="$(TARGET_CFLAGS) -DHAVE_ISC_READER=1" \
  32. BINDIR="/usr/sbin" MANDIR="/usr/man" \
  33. AWK="awk" \
  34. all
  35. endef
  36. define Package/dnsmasq/install
  37. $(INSTALL_DIR) $(1)/usr/sbin
  38. $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/dnsmasq $(1)/usr/sbin/
  39. $(INSTALL_DIR) $(1)/etc/config
  40. $(INSTALL_DATA) ./files/dhcp.conf $(1)/etc/config/dhcp
  41. $(INSTALL_DATA) ./files/dnsmasq.conf $(1)/etc/dnsmasq.conf
  42. $(INSTALL_DIR) $(1)/etc/init.d
  43. $(INSTALL_BIN) ./files/dnsmasq.init $(1)/etc/init.d/dnsmasq
  44. endef
  45. $(eval $(call BuildPackage,dnsmasq))