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.

131 lines
3.6 KiB

  1. #
  2. # This is free software, licensed under the GNU General Public License v2.
  3. # See /LICENSE for more information.
  4. #
  5. include $(TOPDIR)/rules.mk
  6. PKG_NAME:=subversion
  7. PKG_RELEASE:=1
  8. PKG_VERSION:=1.12.0
  9. PKG_SOURCE_URL:=@APACHE/subversion
  10. PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
  11. PKG_HASH:=7fae7c73d8a007c107c0ae5eb372bc0bb013dbfe966fcd5c59cd5a195a5e2edf
  12. PKG_LICENSE:=Apache-2.0
  13. PKG_LICENSE_FILES:=LICENSE
  14. PKG_MAINTAINER:=Val Kulkov <val.kulkov@gmail.com>
  15. PKG_FIXUP:=autoreconf
  16. PKG_MACRO_PATHS:=build/ac-macros
  17. PKG_BUILD_DEPENDS:=apr-util
  18. PKG_BUILD_PARALLEL:=1
  19. PKG_INSTALL:=1
  20. include $(INCLUDE_DIR)/package.mk
  21. include $(INCLUDE_DIR)/nls.mk
  22. define Package/subversion/Default
  23. SECTION:=net
  24. CATEGORY:=Network
  25. SUBMENU:=Version Control Systems
  26. TITLE:=A compelling replacement for CVS
  27. DEPENDS:=+PACKAGE_unixodbc:unixodbc +libaprutil +libmagic $(ICONV_DEPENDS) $(INTL_DEPENDS)
  28. URL:=https://subversion.apache.org/
  29. endef
  30. define Package/subversion/Default/description
  31. Subversion is a free/open-source version control system. That is,
  32. Subversion manages files and directories, and the changes made to them,
  33. over time. This allows you to recover older versions of your data, or
  34. examine the history of how your data changed. In this regard, many
  35. people think of a version control system as a sort of time machine.
  36. endef
  37. define Package/subversion-libs
  38. $(call Package/subversion/Default)
  39. TITLE:=subversion libs
  40. endef
  41. define Package/subversion-libs/description
  42. $(call Package/subversion/Default/description)
  43. This package contains the Subversion libraries.
  44. endef
  45. define Package/subversion-client
  46. $(call Package/subversion/Default)
  47. DEPENDS:=+subversion-libs
  48. TITLE:=subversion client tools
  49. endef
  50. define Package/subversion-client/description
  51. $(call Package/subversion/Default/description)
  52. This package contains the Subversion client tools.
  53. endef
  54. define Package/subversion-server
  55. $(call Package/subversion/Default)
  56. DEPENDS:=+subversion-libs
  57. TITLE:=subversion server
  58. endef
  59. define Package/subversion-server/description
  60. $(call Package/subversion/Default/description)
  61. This package contains the Subversion server.
  62. endef
  63. define Package/subversion-server/conffiles
  64. /etc/config/subversion
  65. endef
  66. TARGET_CFLAGS += $(FPIC)
  67. CONFIGURE_ARGS += \
  68. --with-apr="$(STAGING_DIR)/usr/bin/apr-1-config" \
  69. --with-apr-util="$(STAGING_DIR)/usr/bin/apu-1-config" \
  70. --with-libmagic="$(STAGING_DIR)/usr" \
  71. --disable-mod-activation \
  72. --without-ruby-sitedir \
  73. --without-swig \
  74. --without-jikes \
  75. --without-junit \
  76. --without-berkeley-db \
  77. --without-apxs \
  78. --without-sasl \
  79. --with-lz4=internal \
  80. --with-utf8proc=internal
  81. ifdef $(INTL_FULL)
  82. CONFIGURE_ARGS += --enable-nls
  83. else
  84. CONFIGURE_ARGS += --disable-nls
  85. endif
  86. define Package/subversion-libs/install
  87. $(INSTALL_DIR) $(1)/usr/lib
  88. $(CP) $(PKG_INSTALL_DIR)/usr/lib/libsvn_*.so.* $(1)/usr/lib/
  89. endef
  90. define Package/subversion-client/install
  91. $(INSTALL_DIR) $(1)/usr/bin
  92. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/{svn,svnversion,svnsync} $(1)/usr/bin/
  93. endef
  94. define Package/subversion-server/install
  95. $(INSTALL_DIR) $(1)/usr/bin
  96. $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/svn{look,admin,dumpfilter,serve} $(1)/usr/bin/
  97. $(INSTALL_DIR) $(1)/etc/config
  98. $(INSTALL_CONF) ./files/subversion.config $(1)/etc/config/subversion
  99. $(INSTALL_DIR) $(1)/etc/init.d
  100. $(INSTALL_BIN) ./files/subversion.init $(1)/etc/init.d/subversion
  101. endef
  102. define Package/subversion-server/prerm
  103. #!/bin/sh
  104. ps | grep '\(/svnserve$\| svnserve\)' | grep -cvq grep >/dev/null && /etc/init.d/subversion stop
  105. /etc/init.d/subversion disable
  106. endef
  107. $(eval $(call BuildPackage,subversion-libs))
  108. $(eval $(call BuildPackage,subversion-client))
  109. $(eval $(call BuildPackage,subversion-server))