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.

125 lines
3.0 KiB

  1. #
  2. # Copyright (C) 2007-2015 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:=gnurl
  9. PKG_VERSION:=7.65.1
  10. PKG_RELEASE:=1
  11. PKG_SOURCE_URL:=https://ftp.gnu.org/gnu/gnunet
  12. PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
  13. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
  14. PKG_HASH:=37bb87993f9219f4c76195031f1b0311afde157a1b852d54f570e3195ad7af01
  15. PKG_LICENSE:=MIT
  16. PKG_LICENSE_FILES:=COPYING
  17. PKG_FIXUP:=autoreconf
  18. PKG_BUILD_PARALLEL:=1
  19. include $(INCLUDE_DIR)/package.mk
  20. define Package/gnurl/Default
  21. SECTION:=net
  22. CATEGORY:=Network
  23. URL:=https://gnunet.org/gnurl
  24. MAINTAINER:=Daniel Golle <daniel@makrotopia.org>
  25. endef
  26. define Package/gnurl
  27. $(call Package/gnurl/Default)
  28. SUBMENU:=File Transfer
  29. DEPENDS:=+libgnurl
  30. TITLE:=A client-side HTTP/HTTPS transfer utility
  31. endef
  32. define Package/libgnurl
  33. $(call Package/gnurl/Default)
  34. SECTION:=libs
  35. CATEGORY:=Libraries
  36. DEPENDS:=+libgnutls +libidn2 +zlib
  37. TITLE:=A client-side HTTP/HTTPS transfer library
  38. endef
  39. TARGET_CFLAGS += $(FPIC)
  40. CONFIGURE_ARGS += \
  41. $(call autoconf_bool,CONFIG_IPV6,ipv6) \
  42. --with-gnutls="$(STAGING_DIR)/usr" \
  43. --with-libidn="$(STAGING_DIR)/usr" \
  44. --with-zlib="$(STAGING_DIR)/usr" \
  45. --with-ca-path="/etc/ssl/certs/" \
  46. --enable-shared \
  47. --enable-static \
  48. --without-axtls \
  49. --without-brotli \
  50. --without-libssh2 \
  51. --without-libmetalink \
  52. --without-winidn \
  53. --without-librtmp \
  54. --without-nghttp2 \
  55. --without-nss \
  56. --without-cyassl \
  57. --without-libpsl \
  58. --without-polarssl \
  59. --without-ssl \
  60. --without-winssl \
  61. --without-darwinssl \
  62. --disable-ares \
  63. --disable-sspi \
  64. --disable-crypto-auth \
  65. --disable-ntlm-wb \
  66. --disable-tls-srp \
  67. --disable-ldap \
  68. --disable-ldaps \
  69. --disable-rtsp \
  70. --disable-dict \
  71. --disable-telnet \
  72. --disable-tftp \
  73. --disable-pop3 \
  74. --disable-imap \
  75. --disable-smtp \
  76. --disable-gopher \
  77. --disable-file \
  78. --disable-ftp \
  79. --disable-smb \
  80. --disable-debug \
  81. --disable-manual \
  82. --disable-verbose
  83. define Build/Compile
  84. +$(MAKE) $(PKG_JOBS) -C $(PKG_BUILD_DIR) \
  85. DESTDIR="$(PKG_INSTALL_DIR)" \
  86. CC="$(TARGET_CC)" \
  87. install
  88. endef
  89. define Build/InstallDev
  90. $(INSTALL_DIR) $(2)/bin $(1)/usr/bin $(1)/usr/include/gnurl $(1)/usr/lib $(1)/usr/lib/pkgconfig
  91. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gnurl-config $(1)/usr/bin/
  92. $(CP) $(PKG_INSTALL_DIR)/usr/include/gnurl/*.h $(1)/usr/include/gnurl
  93. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libgnurl.{a,so*} $(1)/usr/lib/
  94. $(CP) $(PKG_BUILD_DIR)/libgnurl.pc $(1)/usr/lib/pkgconfig/
  95. $(SED) 's,-L$$$${exec_prefix}/lib,,g' $(1)/usr/bin/gnurl-config
  96. [ -n "$(TARGET_LDFLAGS)" ] && $(SED) 's#$(TARGET_LDFLAGS)##g' $(1)/usr/lib/pkgconfig/libgnurl.pc || true
  97. $(LN) $(STAGING_DIR)/usr/bin/gnurl-config $(2)/bin/
  98. endef
  99. define Package/gnurl/install
  100. $(INSTALL_DIR) $(1)/usr/bin
  101. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gnurl $(1)/usr/bin/
  102. endef
  103. define Package/libgnurl/install
  104. $(INSTALL_DIR) $(1)/usr/lib
  105. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libgnurl.so.* $(1)/usr/lib/
  106. endef
  107. $(eval $(call BuildPackage,gnurl))
  108. $(eval $(call BuildPackage,libgnurl))