Makefile 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253
  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.47
  10. PKG_RELEASE:=3
  11. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
  12. PKG_SOURCE_URL:=http://thekelleys.org.uk/dnsmasq
  13. PKG_MD5SUM:=4524081e56d0b935717d493e8e8d3e11
  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. endef
  27. define Build/Compile
  28. $(MAKE) -C $(PKG_BUILD_DIR) \
  29. $(TARGET_CONFIGURE_OPTS) \
  30. CFLAGS="$(TARGET_CFLAGS) -DHAVE_ISC_READER=1" \
  31. BINDIR="/usr/sbin" MANDIR="/usr/man" \
  32. AWK="awk" \
  33. all
  34. endef
  35. define Package/dnsmasq/install
  36. $(INSTALL_DIR) $(1)/usr/sbin
  37. $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/dnsmasq $(1)/usr/sbin/
  38. $(INSTALL_DIR) $(1)/etc/config
  39. $(INSTALL_DATA) ./files/dhcp.conf $(1)/etc/config/dhcp
  40. $(INSTALL_DIR) $(1)/etc/init.d
  41. $(INSTALL_BIN) ./files/dnsmasq.init $(1)/etc/init.d/dnsmasq
  42. endef
  43. $(eval $(call BuildPackage,dnsmasq))