You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

150 lines
3.6 KiB

  1. #
  2. # Copyright (C) 2006-2010 OpenWrt.org
  3. # Copyright (C) 2019 Noah Meyerhans <frodo@morgul.net>
  4. #
  5. #
  6. # This is free software, licensed under the GNU General Public License v2.
  7. # See /LICENSE for more information.
  8. include $(TOPDIR)/rules.mk
  9. PKG_NAME:=iputils
  10. PKG_VERSION:=20190709
  11. PKG_RELEASE:=1
  12. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
  13. PKG_SOURCE_URL:=https://codeload.github.com/iputils/iputils/tar.gz/s$(PKG_VERSION)?
  14. PKG_HASH:=a15720dd741d7538dd2645f9f516d193636ae4300ff7dbc8bfca757bf166490a
  15. PKG_MAINTAINER:=Noah Meyerhans <frodo@morgul.net>
  16. PKG_LICENSE:=BSD-3-Clause
  17. PKG_LICENSE_FILES:=LICENSE
  18. PKG_CPE_ID:=cpe:/a:iputils_project:iputils
  19. PKG_BUILD_DIR:=$(BUILD_DIR)/iputils-s$(PKG_VERSION)
  20. PKG_BUILD_DEPENDS:=meson/host
  21. include $(INCLUDE_DIR)/package.mk
  22. include ../../devel/meson/meson.mk
  23. MESON_ARGS:=-DBUILD_MANS=false \
  24. -DBUILD_HTML_MANS=false \
  25. -DUSE_CAP=false \
  26. -DUSE_CRYPTO=kernel \
  27. -DUSE_IDN=false \
  28. -DUSE_GETTEXT=false \
  29. -DNO_SETCAP_OR_SUID=true \
  30. -DBUILD_PING=true \
  31. -DBUILD_ARPING=true \
  32. -DBUILD_CLOCKDIFF=true \
  33. -DBUILD_TRACEPATH=true \
  34. -DBUILD_TFTPD=true
  35. define Package/iputils/Default
  36. SECTION:=net
  37. CATEGORY:=Network
  38. TITLE:=iputils
  39. URL:=https://github.com/iputils/iputils
  40. endef
  41. ### ping
  42. define Package/iputils-ping
  43. $(call Package/iputils/Default)
  44. TITLE:=iputils-ping
  45. DEPENDS:=+kmod-crypto-md5
  46. endef
  47. define Package/iputils-ping/config
  48. source "$(SOURCE)/Config_ping.in"
  49. endef
  50. define Package/iputils-ping/description
  51. Send ICMP_ECHOREQUEST packets to IP hosts and report on replies
  52. endef
  53. define Package/iputils-ping/install
  54. $(INSTALL_DIR) $(1)/usr/bin
  55. $(INSTALL_SUID) $(MESON_BUILD_DIR)/ping $(1)/usr/bin/
  56. ifdef CONFIG_PING_LEGACY_SYMLINKS
  57. ln -s ping $(1)/usr/bin/ping4
  58. ln -s ping $(1)/usr/bin/ping6
  59. endif
  60. endef
  61. ### arping
  62. define Package/iputils-arping
  63. $(call Package/iputils/Default)
  64. TITLE:=iputils-arping
  65. endef
  66. define Package/iputils-arping/description
  67. Send ARP REQUEST packets to a neighbor host
  68. endef
  69. define Package/iputils-arping/install
  70. $(INSTALL_DIR) $(1)/usr/bin
  71. $(INSTALL_BIN) $(MESON_BUILD_DIR)/arping $(1)/usr/bin/
  72. endef
  73. ### clockdiff
  74. define Package/iputils-clockdiff
  75. $(call Package/iputils/Default)
  76. TITLE:=iputils-clockdiff
  77. endef
  78. define Package/iputils-clockdiff/description
  79. Measure the clock difference between two hosts
  80. endef
  81. define Package/iputils-clockdiff/install
  82. $(INSTALL_DIR) $(1)/usr/bin
  83. $(INSTALL_BIN) $(MESON_BUILD_DIR)/clockdiff $(1)/usr/bin/
  84. endef
  85. ### tracepath
  86. define Package/iputils-tracepath
  87. $(call Package/iputils/Default)
  88. TITLE:=iputils-tracepath
  89. endef
  90. define Package/iputils-tracepath/description
  91. trace network path to a host, discovering PMTU
  92. endef
  93. define Package/iputils-tracepath/config
  94. source "$(SOURCE)/Config_tracepath.in"
  95. endef
  96. define Package/iputils-tracepath/install
  97. $(INSTALL_DIR) $(1)/usr/bin
  98. $(INSTALL_BIN) $(MESON_BUILD_DIR)/tracepath $(1)/usr/bin/
  99. ifdef CONFIG_TRACEPATH_LEGACY_SYMLINKS
  100. ln -s tracepath $(1)/usr/bin/tracepath4
  101. ln -s tracepath $(1)/usr/bin/tracepath6
  102. endif
  103. endef
  104. ### tftp
  105. define Package/iputils-tftpd
  106. $(call Package/iputils/Default)
  107. TITLE:=iputils-tftpd
  108. endef
  109. define Package/iputils-tftpd/description
  110. Trivial File Transfer Protocol server
  111. endef
  112. define Package/iputils-tftpd/install
  113. $(INSTALL_DIR) $(1)/usr/bin
  114. $(INSTALL_BIN) $(MESON_BUILD_DIR)/tftpd $(1)/usr/bin/
  115. endef
  116. $(eval $(call BuildPackage,iputils-ping))
  117. $(eval $(call BuildPackage,iputils-arping))
  118. $(eval $(call BuildPackage,iputils-clockdiff))
  119. $(eval $(call BuildPackage,iputils-tracepath))
  120. $(eval $(call BuildPackage,iputils-tftpd))