%define gitversion v0.27.4 %define fixesdate 0 %define rel 1 %if %{fixesdate} %define release %mkrel %fixesdate.%rel %else %define release %mkrel %rel %endif %define required_myth %{version} Summary: The web interface to MythTV Name: mythtv-mythweb Version: 0.27.4 Release: %{release} URL: http://www.mythtv.org/ License: GPLv2 Group: Video/Television Source0: https://github.com/MythTV/mythweb/archive/v%{version}.tar.gz Source1: update-fixes.sh %if %{fixesdate} Patch001: fixes-%{gitversion}.patch %endif BuildArch: noarch Requires: mythtv-backend >= %{required_myth} Requires: apache-mod_php >= 2.0.54 Requires: php-mythtv Obsoletes: mythweb < 0.20a-7 # Requires autofinder is confused, requires nonexistent packages %global __requires_exclude pear* %description The web interface to MythTV. %prep %setup -q -n mythweb-%{version} %apply_patches # (cg) The install scripts are pretty dumb at times and include these files # so lets trash them early find \( -name .gitignore -o -name "*.[0-9][0-9][0-9][0-9]" \) -delete %build %install install -d -m755 %{buildroot}%{_var}/www/mythweb install -m644 *.php %{buildroot}%{_var}/www/mythweb install -m755 *.pl %{buildroot}%{_var}/www/mythweb for dir in classes includes js modules skins ; do cp -r $dir %{buildroot}%{_var}/www/mythweb done install -d -m755 %{buildroot}%{_localstatedir}/lib/mythweb/data ln -s %{_localstatedir}/lib/mythweb/data %{buildroot}%{_var}/www/mythweb/data # Create a default configuration for mythweb install -d -m755 %{buildroot}%{_sysconfdir}/httpd/conf/webapps.d install -m644 mythweb.conf.apache %{buildroot}%{_sysconfdir}/httpd/conf/webapps.d/mythweb.conf perl -pi -e's|<Directory "/var/www/html|<Directory "%{_var}/www/mythweb|' %{buildroot}%{_sysconfdir}/httpd/conf/webapps.d/mythweb.conf perl -pi -e's|# RewriteBase /mythweb| RewriteBase /mythweb|' %{buildroot}%{_sysconfdir}/httpd/conf/webapps.d/mythweb.conf cat >> %{buildroot}%{_sysconfdir}/httpd/conf/webapps.d/mythweb.conf <<EOF # Mageia Customisations Alias /mythweb %{_var}/www/mythweb <Directory %{_var}/www/mythweb> # Only allow localhost access by default. Customise to suit your needs # (customisations should be placed in a separate file in conf/vhosts.d/) %if %{mgaversion} < 3 Order deny,allow Deny from all Allow from 127.0.0.1 %endif %if %{mgaversion} >= 3 Require local granted %endif </Directory> EOF %files %doc README* LICENSE INSTALL mythweb.conf.* %{_var}/www/mythweb %dir %{_localstatedir}/lib/mythweb %attr(-,apache,apache) %{_localstatedir}/lib/mythweb/data %config(noreplace) %{_sysconfdir}/httpd/conf/webapps.d/mythweb.conf %changelog * Wed Oct 22 2014 colin <colin> 0.27.4-1.mga5 + Revision: 792510 - New version: 0.27.4 (no actual change since 0.27.1) * Wed Oct 15 2014 umeabot <umeabot> 0.27.3-20140710.2.mga5 + Revision: 742515 - Second Mageia 5 Mass Rebuild + tv <tv> - use %%global for req/prov exclude - autoconvert to new prov/req excludes * Thu Jul 10 2014 colin <colin> 0.27.3-20140710.1.mga5 + Revision: 651064 - Update to 0.27.3 * Sun Dec 22 2013 colin <colin> 0.27-20131222.1.mga4 + Revision: 559915 - Update to latest fixes * Tue Sep 24 2013 colin <colin> 0.27-1.mga4 + Revision: 484768 - Fix unexpanded macro - imported package mythtv-mythweb