Makefile 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. #
  2. # Copyright (C) 2011-2012 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:=resolveip
  9. PKG_RELEASE:=2
  10. include $(INCLUDE_DIR)/package.mk
  11. define Package/resolveip
  12. SECTION:=utils
  13. CATEGORY:=Base system
  14. TITLE:=Simple DNS resolver with configurable timeout
  15. MAINTAINER:=Jo-Philipp Wich <[email protected]>
  16. endef
  17. define Package/resolveip/description
  18. This package contains the small resolveip utility which
  19. can be used by scripts to turn host names into numeric
  20. IP addresses. It supports IPv4 and IPv6 resolving and
  21. has a configurable timeout to guarantee a certain maximum
  22. runtime in case of slow or defunct DNS servers.
  23. endef
  24. define Build/Prepare
  25. $(INSTALL_DIR) $(PKG_BUILD_DIR)
  26. $(INSTALL_DATA) ./src/resolveip.c $(PKG_BUILD_DIR)/
  27. endef
  28. define Build/Compile
  29. $(TARGET_CC) $(TARGET_CFLAGS) -Wall \
  30. -o $(PKG_BUILD_DIR)/resolveip $(PKG_BUILD_DIR)/resolveip.c
  31. endef
  32. define Package/resolveip/install
  33. $(INSTALL_DIR) $(1)/usr/bin
  34. $(INSTALL_BIN) $(PKG_BUILD_DIR)/resolveip $(1)/usr/bin/
  35. endef
  36. $(eval $(call BuildPackage,resolveip))