# Make this stuff live under /usr/local by default %define _prefix /usr/local # by default the release is 0tvd_fedora or 0tvd_redhat depending on the build # platform. if you want to change it, set it via release... # --define 'release whatever' %if %{?release:0}%{!?release:1} %define rsuf %(eval "`ls -la /etc/{fedora,redhat}-release 2>/dev/null | grep ^- | sed -e 's/^.*[/]/rsuf=/' -e 's/-release//'`" ; echo $rsuf) %define release 0tvd_%{rsuf} %endif # use this if the file extension isn't bz2 (the default) # --define 'fext gz' %if %{?fext:0}%{!?fext:1} %define fext bz2 %endif # build httpd module? (0 by default) # --define 'httpd 1' %if %{?httpd:0}%{!?httpd:1} %define httpd 0 %endif # build with berkeley db support? (0 by default) # --define 'bdb 1' %if %{?bdb:0}%{!?bdb:1} %define bdb 0 %endif # build with ssl support? (1 by default) # --define 'ssl 0' %if %{?ssl:0}%{!?ssl:1} %define ssl 1 %endif Summary: A Concurrent Versioning system similar to but better than CVS. Name: subversion Version: 1.3.0 Release: %{release} License: BSD Group: Utilities/System URL: http://subversion.tigris.org SOURCE0: subversion-%{version}.tar.%{fext} BuildPreReq: autoconf >= 2.53 BuildPreReq: expat-devel BuildPreReq: libtool >= 1.4.2 BuildPreReq: zlib-devel %if %{ssl} BuildPreReq: openssl-devel %endif %if %{bdb} BuildPreReq: db4-devel %endif BuildRoot: %{_tmppath}/%{name}-%{version}-%{release} %description Subversion is a concurrent version control system which enables one or more users to collaborate in developing and maintaining a hierarchy of files and directories while keeping a history of all changes. Subversion only stores the differences between versions, instead of every complete file. Subversion also keeps a log of who, when, and why changes occurred. As such it basically does the same thing CVS does (Concurrent Versioning System) but has major enhancements compared to CVS and fixes a lot of the annoyances that CVS users face. %if %{httpd} %package -n subversion-httpd BuildRequires: httpd-devel Requires: httpd Summary: SVN modules for httpd Group: Utilities/System %description -n subversion-httpd SVN modules for httpd %endif %prep %setup -q # some platforms have multiple autoconf's installed, including 2.53 if [ -f /usr/bin/autoconf-2.53 ]; then AUTOCONF="autoconf-2.53" AUTOHEADER="autoheader-2.53" export AUTOCONF AUTOHEADER fi sh autogen.sh %if !%{httpd} APACHE=--without-apache %endif %if !%{bdb} BDB=--without-berkeley-db %endif %if %{ssl} SSL=--with-ssl %endif %configure \ --disable-mod-activation \ $SSL $APACHE $BDB %build make %install [ "$RPM_BUILD_ROOT" != "/" ] && rm -rf $RPM_BUILD_ROOT rm -f filelist make install DESTDIR="$RPM_BUILD_ROOT" [ -x /usr/lib/rpm/brp-compress ] && /usr/lib/rpm/brp-compress %if %{httpd} MODDIR=`/usr/sbin/apxs -q LIBEXECDIR` ( cd $RPM_BUILD_ROOT ; find . ! -type d ) | grep -v $MODDIR | sed -e 's/^\.//' > filelist ( cd $RPM_BUILD_ROOT ; find .$MODDIR ! -type d ) | sed -e 's/^\.//' > filelist2 %else ( cd $RPM_BUILD_ROOT ; find . ! -type d ) | sed -e 's/^\.//' > filelist %endif %post /sbin/ldconfig %postun /sbin/ldconfig %clean rm -rf $RPM_BUILD_ROOT %files -f filelist %defattr(-,root,root) %doc BUGS CHANGES COMMITTERS COPYING HACKING INSTALL README %doc subversion/LICENSE contrib %if %{httpd} %files -n subversion-httpd -f filelist2 %defattr(-,root,root) %endif