1 %include /usr/lib/rpm/macros.perl
2 Summary: Open source content management system (CMS)
7 Group: Development/Languages/Perl
8 URL: http://www.plainblack.com/webgui
9 Source0: http://files.plainblack.com/downloads/5.x.x/webgui-%{version}.tar.gz
10 Patch0: %{name}-etc.patch
11 BuildRequires: perl >= 5.6
12 BuildRequires: rpm-perlprov >= 3.0.3-16
14 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
17 WebGUI is a content management platform built to allow average
18 business users to build and maintain complex web sites. It is modular,
19 pluggable, and platform independent. It was designed to allow the
20 people who create the content, to manage it online, rather than
21 content management taking up the time of the busy IT Staff.
27 perl -pi -e 's|/data/WebGUI|%{_libdir}/WebGUI|' sbin/preload.perl etc/WebGUI.conf*
28 perl -pi -e 's|configFile\s+=\s+\"WebGUI.conf\"|configFile = \"%{_sysconfdir}/WebGUI/WebGUI.conf\"|' www/index.pl
29 perl -pi -e 's|webguiRoot\s*=\s*\".+?\"|webguiRoot = \"%{_libdir}/WebGUI\"|' www/index.pl
34 rm -rf $RPM_BUILD_ROOT
35 install -d $RPM_BUILD_ROOT%{_libdir}/%{name}/sql
36 install -d $RPM_BUILD_ROOT%{_sysconfdir}/%{name}
39 mv docs/upgrades $RPM_BUILD_ROOT%{_libdir}/%{name}/sql
40 mv docs/create.sql $RPM_BUILD_ROOT%{_libdir}/%{name}/sql
42 mv etc/* $RPM_BUILD_ROOT%{_sysconfdir}/%{name}
44 cp -av . $RPM_BUILD_ROOT%{_libdir}/%{name}
45 rm -r $RPM_BUILD_ROOT%{_libdir}/%{name}/docs
48 rm -rf $RPM_BUILD_ROOT
51 %defattr(644,root,root,755)
53 %{_sysconfdir}/%{name}