Summary(pl.UTF-8): System Zarządzania Siecią Lokalną
Name: lms
Version: %{lmsver}.%{lmssubver}
-Release: 3
+Release: 11
License: GPL v2
Group: Networking/Utilities
Source0: http://www.lms.org.pl/download/%{lmsver}/%{name}-%{version}.tar.gz
# Source0-md5: 294899358ae2585a4030580d79a06ee8
-Source1: %{name}.conf
-Source2: %{name}.init
-Source3: %{name}.sysconfig
+Source1: %{name}.init
+Source2: %{name}.sysconfig
+Source3: %{name}-apache.conf
+Source4: %{name}-httpd.conf
Patch0: %{name}-PLD.patch
Patch1: %{name}-amd64.patch
Patch2: %{name}-smarty.patch
+Patch3: build.patch
URL: http://www.lms.org.pl/
BuildRequires: bison
BuildRequires: flex
Requires: webserver(access)
Requires: webserver(alias)
Requires: webserver(php)
+Conflicts: apache-base < 2.4.0-1
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
%define _sysconfdir /etc/%{name}
%patch1 -p1
%endif
%patch2 -p1
+%patch3 -p1
mkdir smarty-plugins
%{__mv} \
%install
rm -rf $RPM_BUILD_ROOT
install -d $RPM_BUILD_ROOT{%{_sbindir},%{_libdir}/%{name},%{_webapps}/%{_webapp}} \
- $RPM_BUILD_ROOT/etc/{rc.d/init.d,sysconfig} \
+ $RPM_BUILD_ROOT/etc/{rc.d/init.d,sysconfig,lms/modules} \
$RPM_BUILD_ROOT%{_smartyplugindir} \
$RPM_BUILD_ROOT%{_lmsdir}/{lms,userpanel,www/{doc,user,userpanel/modules}} \
$RPM_BUILD_ROOT%{_lmsvar}/{backups,documents,templates_c,userpanel/templates_c}
%{__mv} $RPM_BUILD_ROOT{%{_lmsdir}/sample/%{name}.ini,%{_sysconfdir}}
-install %{SOURCE1} $RPM_BUILD_ROOT%{_webapps}/%{_webapp}/apache.conf
-install %{SOURCE1} $RPM_BUILD_ROOT%{_webapps}/%{_webapp}/httpd.conf
+install %{SOURCE3} $RPM_BUILD_ROOT%{_webapps}/%{_webapp}/apache.conf
+install %{SOURCE4} $RPM_BUILD_ROOT%{_webapps}/%{_webapp}/httpd.conf
# sqlpanel
%{__mv} $RPM_BUILD_ROOT%{_lmsdir}/{contrib/sqlpanel/sql*.php,modules}
for module in dns ggnotify notify; do
cp -a daemon/modules/$module/sample $RPM_BUILD_ROOT%{_sysconfdir}/modules/$module
done
-install %{SOURCE2} $RPM_BUILD_ROOT/etc/rc.d/init.d/lmsd
-install %{SOURCE3} $RPM_BUILD_ROOT/etc/sysconfig/%{name}
+install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/lmsd
+install %{SOURCE2} $RPM_BUILD_ROOT/etc/sysconfig/%{name}
%endif
#userpanel
%triggerun -- apache1 < 1.3.37-3, apache1-base
%webapp_unregister apache %{_webapp}
-%triggerin -- apache < 2.2.0, apache-base
+%triggerin -- apache-base
%webapp_register httpd %{_webapp}
-%triggerun -- apache < 2.2.0, apache-base
+%triggerun -- apache-base
%webapp_unregister httpd %{_webapp}
%files
%files scripts
%defattr(644,root,root,755)
%attr(755,root,root) %{_sbindir}/lms-*
-%attr(755,root,root) %{_sbindir}/lmsd-*sql
%files sqlpanel
%defattr(644,root,root,755)
%if %{with lmsd}
%files lmsd
%defattr(644,root,root,755)
-%attr(755,root,root) %{_sbindir}/lmsd-*
+%attr(755,root,root) %{_sbindir}/lmsd-*sql
%dir %{_libdir}/lms
%attr(755,root,root) %{_libdir}/lms/*.so
%attr(754,root,root) /etc/rc.d/init.d/lmsd