Makefile 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. #
  2. # Copyright (C) 2011 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:=1
  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. endef
  16. define Package/resolveip/description
  17. This package contains the small resolveip utility which
  18. can be used by scripts to turn host names into numeric
  19. IP addresses. It supports IPv4 and IPv6 resolving and
  20. has a configurable timeout to guarantee a certain maximum
  21. runtime in case of slow or defunct DNS servers.
  22. endef
  23. define Build/Prepare
  24. $(INSTALL_DIR) $(PKG_BUILD_DIR)
  25. $(INSTALL_DATA) ./src/resolveip.c $(PKG_BUILD_DIR)/
  26. endef
  27. define Build/Compile
  28. $(TARGET_CC) $(TARGET_CFLAGS) -Wall \
  29. -o $(PKG_BUILD_DIR)/resolveip $(PKG_BUILD_DIR)/resolveip.c
  30. endef
  31. define Package/resolveip/install
  32. $(INSTALL_DIR) $(1)/usr/bin
  33. $(INSTALL_BIN) $(PKG_BUILD_DIR)/resolveip $(1)/usr/bin/
  34. endef
  35. $(eval $(call BuildPackage,resolveip))