|
|
|
|
##
|
|
|
|
|
## svnweb.spec -- OpenPKG RPM Package Specification
|
|
|
|
|
## Copyright (c) 2000-2009 OpenPKG Foundation e.V. <http://openpkg.net/>
|
|
|
|
|
##
|
|
|
|
|
## Permission to use, copy, modify, and distribute this software for
|
|
|
|
|
## any purpose with or without fee is hereby granted, provided that
|
|
|
|
|
## the above copyright notice and this permission notice appear in all
|
|
|
|
|
## copies.
|
|
|
|
|
##
|
|
|
|
|
## THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
|
|
|
|
|
## WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
|
|
|
|
## MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
|
|
|
|
|
## IN NO EVENT SHALL THE AUTHORS AND COPYRIGHT HOLDERS AND THEIR
|
|
|
|
|
## CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
|
|
|
|
## SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
|
|
|
|
## LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
|
|
|
|
|
## USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
|
|
|
|
|
## ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
|
|
|
|
## OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
|
|
|
|
|
## OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
|
|
|
|
|
## SUCH DAMAGE.
|
|
|
|
|
##
|
|
|
|
|
|
|
|
|
|
# package information
|
|
|
|
|
Name: svnweb
|
|
|
|
|
Summary: Subversion Repository Viewer
|
|
|
|
|
URL: http://search.cpan.org/~nikc/SVN-Web/
|
|
|
|
|
Vendor: Chia-liang Kao, Nik Clayton et al.
|
|
|
|
|
Packager: OpenPKG Foundation e.V.
|
|
|
|
|
Distribution: OpenPKG Community
|
|
|
|
|
Class: EVAL
|
|
|
|
|
Group: SCM
|
|
|
|
|
License: Artistic/GPL
|
|
|
|
|
Version: 0.53
|
|
|
|
|
Release: 20081027
|
|
|
|
|
|
|
|
|
|
# list of sources
|
|
|
|
|
Source0: http://www.cpan.org/authors/id/N/NI/NIKC/SVN-Web-%{version}.tar.gz
|
|
|
|
|
Source1: svnweb-apache.conf
|
|
|
|
|
Source2: svnweb.yaml
|
|
|
|
|
Patch0: svnweb.patch
|
|
|
|
|
|
|
|
|
|
# build information
|
|
|
|
|
Prefix: %{l_prefix}
|
|
|
|
|
BuildRoot: %{l_buildroot}
|
|
|
|
|
BuildPreReq: OpenPKG, openpkg >= 20040130, perl-openpkg
|
|
|
|
|
PreReq: OpenPKG, openpkg >= 20040130
|
|
|
|
|
BuildPreReq: perl, perl-parse, perl-text, perl-mail, perl-locale, perl-time, perl-util, perl-ds, perl-www, perl-template
|
|
|
|
|
PreReq: perl, perl-parse, perl-text, perl-mail, perl-locale, perl-time, perl-util, perl-ds, perl-www, perl-template
|
|
|
|
|
BuildPreReq: yaml, yaml::with_perl = yes
|
|
|
|
|
PreReq: yaml, yaml::with_perl = yes
|
|
|
|
|
BuildPreReq: subversion, subversion::with_perl = yes
|
|
|
|
|
PreReq: subversion, subversion::with_perl = yes
|
|
|
|
|
PreReq: apache, apache-perl, apache-apreq, apache-apreq::with_perl = yes
|
|
|
|
|
AutoReq: no
|
|
|
|
|
AutoReqProv: no
|
|
|
|
|
|
|
|
|
|
%description
|
|
|
|
|
SVN::Web provides a full-featured and theme-able Web interface to
|
|
|
|
|
local or remote Subversion (SVN) repositories.
|
|
|
|
|
|
|
|
|
|
%track
|
|
|
|
|
prog svnweb = {
|
|
|
|
|
version = %{version}
|
|
|
|
|
url = http://search.cpan.org/~nikc/SVN-Web/
|
|
|
|
|
regex = SVN-Web-(__VER__)\.tar\.gz
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
%prep
|
|
|
|
|
%setup -q -n SVN-Web-%{version}
|
|
|
|
|
chmod a+rw Build.PL
|
|
|
|
|
%patch -p0
|
|
|
|
|
|
|
|
|
|
%build
|
|
|
|
|
|
|
|
|
|
%install
|
|
|
|
|
rm -rf $RPM_BUILD_ROOT
|
|
|
|
|
%{l_shtool} mkdir -f -p -m 755 \
|
|
|
|
|
$RPM_BUILD_ROOT%{l_prefix}/etc/svnweb \
|
|
|
|
|
$RPM_BUILD_ROOT%{l_prefix}/etc/apache/apache.d
|
|
|
|
|
%{l_shtool} install -c -m 644 %{l_value -s -a} \
|
|
|
|
|
%{SOURCE svnweb.yaml} \
|
|
|
|
|
$RPM_BUILD_ROOT%{l_prefix}/etc/svnweb/config.yaml
|
|
|
|
|
%{l_shtool} install -c -m 644 %{l_value -s -a} \
|
|
|
|
|
%{SOURCE svnweb-apache.conf} \
|
|
|
|
|
$RPM_BUILD_ROOT%{l_prefix}/etc/apache/apache.d/svnweb.conf
|
|
|
|
|
%{l_prefix}/bin/perl-openpkg prepare
|
|
|
|
|
%{l_prefix}/bin/perl-openpkg configure \
|
|
|
|
|
-A --norun_apache_tests \
|
|
|
|
|
-A --norun_apache_cgi_tests \
|
|
|
|
|
-A --norun_svnweb-server_tests \
|
|
|
|
|
-A --skip_questions
|
|
|
|
|
%{l_prefix}/bin/perl-openpkg configure build install
|
|
|
|
|
%{l_prefix}/bin/perl-openpkg -F perl-openpkg-files fixate cleanup
|
|
|
|
|
%{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT \
|
|
|
|
|
%{l_files_std} \
|
|
|
|
|
`cat perl-openpkg-files` \
|
|
|
|
|
'%config %{l_prefix}/etc/svnweb/*' \
|
|
|
|
|
'%config %{l_prefix}/etc/apache/apache.d/*'
|
|
|
|
|
|
|
|
|
|
%files -f files
|
|
|
|
|
|
|
|
|
|
%clean
|
|
|
|
|
rm -rf $RPM_BUILD_ROOT
|
|
|
|
|
|
|
|
|
|
%post
|
|
|
|
|
# after upgrade, restart service
|
|
|
|
|
[ $1 -eq 2 ] || exit 0
|
|
|
|
|
eval `%{l_rc} apache status 2>/dev/null`
|
|
|
|
|
[ ".$apache_active" = .yes ] && %{l_rc} apache restart
|
|
|
|
|
exit 0
|
|
|
|
|
|