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.

126 lines
3.1 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.72.0
  10. PKG_RELEASE:=1
  11. PKG_SOURCE_URL:=@GNU/gnunet
  12. PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
  13. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
  14. PKG_HASH:=b1e72be03fcf9b3fdaf01ae0702c686e9de10f67ef538918447c9e81555694f8
  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/en/gnurl.html
  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. --without-zstd \
  63. --disable-ares \
  64. --disable-sspi \
  65. --disable-crypto-auth \
  66. --disable-ntlm-wb \
  67. --disable-tls-srp \
  68. --disable-ldap \
  69. --disable-ldaps \
  70. --disable-rtsp \
  71. --disable-dict \
  72. --disable-telnet \
  73. --disable-tftp \
  74. --disable-pop3 \
  75. --disable-imap \
  76. --disable-smtp \
  77. --disable-gopher \
  78. --disable-file \
  79. --disable-ftp \
  80. --disable-smb \
  81. --disable-debug \
  82. --disable-manual \
  83. --disable-verbose
  84. define Build/Compile
  85. +$(MAKE) $(PKG_JOBS) -C $(PKG_BUILD_DIR) \
  86. DESTDIR="$(PKG_INSTALL_DIR)" \
  87. CC="$(TARGET_CC)" \
  88. install
  89. endef
  90. define Build/InstallDev
  91. $(INSTALL_DIR) $(2)/bin $(1)/usr/bin $(1)/usr/include/gnurl $(1)/usr/lib $(1)/usr/lib/pkgconfig
  92. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gnurl-config $(1)/usr/bin/
  93. $(CP) $(PKG_INSTALL_DIR)/usr/include/gnurl/*.h $(1)/usr/include/gnurl
  94. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libgnurl.{a,so*} $(1)/usr/lib/
  95. $(CP) $(PKG_BUILD_DIR)/libgnurl.pc $(1)/usr/lib/pkgconfig/
  96. $(SED) 's,-L$$$${exec_prefix}/lib,,g' $(1)/usr/bin/gnurl-config
  97. [ -n "$(TARGET_LDFLAGS)" ] && $(SED) 's#$(TARGET_LDFLAGS)##g' $(1)/usr/lib/pkgconfig/libgnurl.pc || true
  98. $(LN) $(STAGING_DIR)/usr/bin/gnurl-config $(2)/bin/
  99. endef
  100. define Package/gnurl/install
  101. $(INSTALL_DIR) $(1)/usr/bin
  102. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/gnurl $(1)/usr/bin/
  103. endef
  104. define Package/libgnurl/install
  105. $(INSTALL_DIR) $(1)/usr/lib
  106. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libgnurl.so.* $(1)/usr/lib/
  107. endef
  108. $(eval $(call BuildPackage,gnurl))
  109. $(eval $(call BuildPackage,libgnurl))