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.

128 lines
3.2 KiB

  1. #
  2. # Copyright (C) 2014 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:=alpine
  9. PKG_VERSION:=2.21.9999
  10. PKG_RELEASE:=2
  11. PKG_SOURCE_PROTO:=git
  12. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
  13. PKG_SOURCE_URL:=http://repo.or.cz/alpine.git
  14. PKG_SOURCE_VERSION:=d3e6f3932f2af9deca8eed09e30a55e9bd524362
  15. PKG_MIRROR_HASH:=72f9e8c4c3ecbd5f73f527af98ad23f716fcede3af0ab0400c6e0bc9b1288e30
  16. PKG_MAINTAINER:=Antti Seppälä <a.seppala@gmail.com>
  17. PKG_LICENSE:=Apache-2.0
  18. PKG_LICENSE_FILES:=LICENSE
  19. PKG_FIXUP:=autoreconf
  20. PKG_INSTALL:=1
  21. PKG_BUILD_PARALLEL:=1
  22. PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION)
  23. include $(INCLUDE_DIR)/package.mk
  24. include $(INCLUDE_DIR)/nls.mk
  25. define Package/alpine/Default
  26. SECTION:=mail
  27. CATEGORY:=Mail
  28. DEPENDS:=+libopenssl +libncurses +libpthread +libpam $(ICONV_DEPENDS) $(INTL_DEPENDS)
  29. TITLE:=Alternatively Licensed Program for Internet News and Email
  30. URL:=http://alpine.x10host.com/alpine/
  31. endef
  32. define Package/alpine/Default/description
  33. Alpine (Alternatively Licensed Program for Internet News and Email) is a
  34. free software email client developed at the University of Washington.
  35. It is suitable for both the inexperienced email user as well as for
  36. the most demanding power user.
  37. endef
  38. define Package/alpine
  39. $(call Package/alpine/Default)
  40. TITLE+= (with OpenSSL support)
  41. DEPENDS+= +libopenssl
  42. VARIANT:=ssl
  43. endef
  44. define Package/alpine/description
  45. $(call Package/alpine/Default/description)
  46. This package is built with OpenSSL support.
  47. endef
  48. define Package/alpine-nossl
  49. $(call Package/alpine/Default)
  50. TITLE+= (without OpenSSL support)
  51. VARIANT:=nossl
  52. endef
  53. define Package/alpine-nossl/description
  54. $(call Package/alpine/Default/description)
  55. This package is built without OpenSSL support.
  56. endef
  57. CONFIGURE_ARGS += \
  58. --with-libiconv-prefix=$(ICONV_PREFIX) \
  59. --with-libintl-prefix=$(INTL_PREFIX) \
  60. --without-tcl \
  61. --without-ldap \
  62. --without-krb5 \
  63. --with-system-pinerc=/etc/pine.conf \
  64. --with-system-fixed-pinerc=/etc/pine.conf.fixed \
  65. --with-supplied-regex \
  66. --with-default-sshpath=/usr/bin/ssh \
  67. --disable-debug \
  68. --disable-mouse \
  69. --with-c-client-target=slx \
  70. CONFIGURE_VARS += \
  71. top_builddir=$(PKG_BUILD_DIR)
  72. ifeq ($(BUILD_VARIANT),ssl)
  73. CONFIGURE_ARGS += \
  74. --with-ssl-include-dir=$(STAGING_DIR)/usr/include/openssl/. \
  75. --with-ssl-lib-dir=$(STAGING_DIR)/usr/lib
  76. endif
  77. ifeq ($(BUILD_VARIANT),nossl)
  78. CONFIGURE_ARGS += \
  79. --without-ssl
  80. endif
  81. ifeq ($(CONFIG_BUILD_NLS),y)
  82. DISABLE_NLS:=
  83. endif
  84. ifeq ($(CONFIG_IPV6),y)
  85. DISABLE_IPV6:=
  86. else
  87. DISABLE_IPV6:=--without-ipv6
  88. endif
  89. define Build/Compile
  90. ( cd $(PKG_BUILD_DIR)/pith ; \
  91. $(HOSTCC) help_h_gen.c -c -o help_h_gen.o ; \
  92. $(HOSTCC) help_h_gen.o -o help_h_gen ; \
  93. $(HOSTCC) help_c_gen.c -c -o help_c_gen.o ; \
  94. $(HOSTCC) help_c_gen.o -o help_c_gen ; \
  95. )
  96. $(call Build/Compile/Default)
  97. endef
  98. define Package/alpine/install
  99. $(INSTALL_DIR) $(1)/usr/bin
  100. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/$(PKG_NAME) $(1)/usr/bin/$(PKG_NAME)
  101. endef
  102. Package/alpine-nossl/install = $(Package/alpine/install)
  103. $(eval $(call BuildPackage,alpine))
  104. $(eval $(call BuildPackage,alpine-nossl))