Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:ecsos:server
phpMyFAQ
phpMyFAQ.spec
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File phpMyFAQ.spec of Package phpMyFAQ
# # spec file for package phpMyFAQ # # Copyright (c) 2024 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed # upon. The license for this file, and modifications and additions to the # file, is the same license as for the pristine package itself (unless the # license for the pristine package is not an Open Source License, in which # case the license is the MIT License). An "Open Source License" is a # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. # Please submit bugfixes or comments via https://bugs.opensuse.org/ # # See also http://en.opensuse.org/openSUSE:Specfile_guidelines %define source_name phpmyfaq %define phpmyfaqroot /usr/share/php/%{source_name} %define minphpversion 8.1.0 Name: phpMyFAQ Version: 3.2.6 Release: 0 Summary: FAQ-Software in php License: MPL-2.0 Group: Productivity/Networking/Web/Frontends URL: http://www.phpmyfaq.de Source0: http://www.phpmyfaq.de/download/%{name}-%{version}.tar.gz Source1: %{name}.conf Source2: %{name}-README.SUSE Patch0: %{name}-configpath.patch Patch1: %{name}-htaccess.patch BuildArch: noarch BuildRoot: %{_tmppath}/%{name}-%{version}-build BuildRequires: apache-rpm-macros BuildRequires: fdupes Requires: php-curl >= %{minphpversion} Requires: php-fileinfo >= %{minphpversion} Requires: php-filter >= %{minphpversion} Requires: php-gd >= %{minphpversion} Requires: php-json >= %{minphpversion} Requires: php-mbstring >= %{minphpversion} Requires: php-mysql >= %{minphpversion} Requires: php-session >= %{minphpversion} Requires: php-spl >= %{minphpversion} Requires: php-xmlwriter >= %{minphpversion} Requires: php-zip >= %{minphpversion} %description phpMyFAQ is a multilingual, scalable, completely database-driven FAQ software using php %package apache Summary: Apache configuration for %{name} Group: Productivity/Networking/Web/Utilities BuildRequires: apache2 Requires: %{name} Requires: apache2 Requires: mod_php_any >= %{minphpversion} Supplements: packageand(apache2:%name) %description apache This subpackage contains the Apache configuration files %prep %setup -q -n %{source_name} %patch -P 0 -p1 %patch -P 1 -p1 install -m644 %{SOURCE2} . # rpmlint suse-filelist-forbidden find . -type f -name '*.orig' -exec rm {} \; find . -type f -name '.gitignore' -exec rm {} \; find . -type f -name '*.sh' -exec sed -i -e 's|\/usr\/bin\/env bash|\/usr\/bin\/bash|g' {} \; %build %install install -d -m0755 %{buildroot}%{phpmyfaqroot} install -d -m0755 %{buildroot}%{_sysconfdir}/%{source_name} install -d -m0755 %{buildroot}%{phpmyfaqroot}/attachments install -d -m0755 %{buildroot}%{phpmyfaqroot}/data install -d -m0755 %{buildroot}%{phpmyfaqroot}/images cp -dR * %{buildroot}%{phpmyfaqroot} ##install phpmyfaq.conf to apache conf.d ##install -D -m0640 %%{SOURCE1} %%{buildroot}%%{apache_sysconfdir}/conf.d/%%{source_name}.conf # install patched .htaccess to apache conf.d install -D -m0640 .htaccess %{buildroot}%{apache_sysconfdir}/conf.d/%{source_name}.conf # copy phpmyfaq configfiles to sysconfdir install -D -m0640 %{buildroot}%{phpmyfaqroot}/config/* \ %{buildroot}%{_sysconfdir}/%{source_name} rm -f %{buildroot}%{phpmyfaqroot}/config/* # generate file list find %{buildroot}%{phpmyfaqroot} -mindepth 1 -maxdepth 1 -type d | sed -e "s@%{buildroot}@@" > FILELIST find %{buildroot}%{phpmyfaqroot} -maxdepth 1 -type f | sed -e "s@%{buildroot}@@" >> FILELIST # rpmlint %fdupes %{buildroot}%{phpmyfaqroot} %post %{__chown} -R %{apache_user}:%{apache_group} %{phpmyfaqroot} # only on update move to new location if [ "$1" -gt 1 ] ; then if [ -d "/srv/www/phpmyfaq" ] ; then echo "o %{name} post-install: Move/Copy files to new location..." cp -aR /srv/www/phpmyfaq/attachments/* %{phpmyfaqroot}/attachments/ || : cp -aR /srv/www/phpmyfaq/data/* %{phpmyfaqroot}/data/ || : cp -aR /srv/www/phpmyfaq/images/* %{phpmyfaqroot}/images/ || : rm -rf /srv/www/phpmyfaq || : fi fi %post apache %restart_on_update apache2 %postun apache %restart_on_update apache2 %files -f FILELIST %doc %{name}-README.SUSE %dir %{_datadir}/php %defattr(640,root,root,750) %dir %attr(0770,root,%{apache_group}) %{_sysconfdir}/%{source_name} %config(noreplace) %attr(640,%{apache_user},%{apache_group}) %{_sysconfdir}/%{source_name}/* %dir %attr(0750,%{apache_user},%{apache_group}) %{phpmyfaqroot} %files apache %config(noreplace) %{apache_sysconfdir}/conf.d/%{source_name}.conf %changelog
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor