[Packages] subversion:
[openwrt/svn-archive/archive.git] / net / subversion / Makefile
1 #
2 # Copyright (C) 2007 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7 # $Id$
8
9 include $(TOPDIR)/rules.mk
10
11 PKG_NAME:=subversion
12 PKG_VERSION:=1.4.5
13 PKG_RELEASE:=1
14
15 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
16 PKG_SOURCE_URL:=http://subversion.tigris.org/downloads/
17 PKG_MD5SUM:=4c333a5fe827568c67d195cda7a5e154
18
19 include $(INCLUDE_DIR)/package.mk
20
21 define Package/subversion/Default
22 SECTION:=net
23 CATEGORY:=Network
24 TITLE:=A compelling replacement for CVS
25 DEPENDS:=+zlib +libneon +libintl +libapr +libaprutil
26 URL:=http://subversion.tigris.org/
27 SUBMENU:=subversion
28 endef
29
30 define Package/subversion-libs
31 $(call Package/subversion/Default)
32 TITLE:=subversion libs
33 endef
34
35 define Package/subversion-client
36 $(call Package/subversion/Default)
37 DEPENDS+=subversion-libs
38 TITLE:=subversion client tools
39 endef
40
41 define Package/subversion-server
42 $(call Package/subversion/Default)
43 DEPENDS+=subversion-libs
44 TITLE:=subversion server
45 endef
46
47 CONFIGURE_ARGS += \
48 --with-apr="$(STAGING_DIR)/usr/bin/apr-1-config" \
49 --with-apr-util="$(STAGING_DIR)/usr/bin/apu-1-config" \
50 --with-neon="$(STAGING_DIR)/usr/include/neon" \
51 --disable-mod-activation \
52 --without-ruby-sitedir \
53 --without-swig \
54 --with-jikes=no \
55 --without-junit \
56 --without-berkeley-db \
57 --with-ssl \
58 --disable-neon-version-check \
59 --with-apxs=no \
60 --with-apache=no \
61
62 CONFIGURE_VARS += \
63 svn_lib_neon=yes \
64 LDFLAGS="-lcrypt -lnsl -lm -lintl -L$(STAGING_DIR)/usr/lib/libintl/lib/ \
65 -lz -L$(STAGING_DIR)/usr/lib/ -lpthread -L$(STAGING_DIR)/lib" \
66 CPPFLAGS="-I$(STAGING_DIR)/usr/include/ -I$(STAGING_DIR)/usr/lib/libintl/include \
67 -I$(STAGING_DIR)/include/" \
68
69 define Build/Configure
70 $(call Build/Configure/Default)
71 $(call libtool_disable_rpath)
72 endef
73
74 define Build/Compile
75 $(call libtool_fixup_libdir,$(PKG_INSTALL_DIR))
76 $(MAKE) -C $(PKG_BUILD_DIR) DESTDIR="$(PKG_INSTALL_DIR)" all local-install
77 endef
78
79 define Package/subversion-libs/install
80 $(INSTALL_DIR) $(1)/usr/lib
81 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libsvn_* $(1)/usr/lib/
82 endef
83
84 define Package/subversion-client/install
85 $(INSTALL_DIR) $(1)/usr/bin
86 $(CP) $(PKG_INSTALL_DIR)/usr/bin/{svn,svnversion,svnsync} $(1)/usr/bin/
87 endef
88
89 define Package/subversion-server/install
90 $(INSTALL_DIR) $(1)/usr/bin
91 $(CP) $(PKG_INSTALL_DIR)/usr/bin/svn{look,admin,dumpfilter,serve} $(1)/usr/bin/
92 $(INSTALL_DIR) $(1)/etc/config
93 $(INSTALL_DATA) ./files/subversion.config $(1)/etc/config/subversion
94 $(INSTALL_DIR) $(1)/etc/init.d
95 $(INSTALL_BIN) ./files/subversion.init $(1)/etc/init.d/subversion
96 endef
97
98 $(eval $(call BuildPackage,subversion-libs))
99 $(eval $(call BuildPackage,subversion-client))
100 $(eval $(call BuildPackage,subversion-server))