Группа :: Сети/Прочее
Пакет: glpi
Главная Изменения Спек Патчи Sources Загрузить Gear Bugs and FR Repocop
%define installdir %webserver_webappsdir/%name
Name: glpi
Version: 10.0.7
Release: alt1
Summary: IT and asset management software
License: GPLv3
Group: Networking/Other
URL: http://www.glpi-project.org
Packager: Pavel Zilke <zidex at altlinux dot org>
BuildArch: noarch
Source0: https://github.com/glpi-project/glpi/releases/download/%version/%name-%version.tgz
Source1: apache2.conf
Source2: README.ALT
Source3: UPGRADE.ALT
#Patch: patch0.patch
Requires: webserver-common php-engine curl lynx
BuildRequires(pre): rpm-macros-webserver-common
%description
GLPI is the Information Resource-Manager with an additional Administration-
Interface.
You can use it to build up a database with an inventory for your company
(computer, software, printers...).
It has enhanced functions to make the daily life for the administrators easier,
like a job-tracking-system with mail-notification and methods to build a
database with basic information about your network-topology.
%package apache2
Summary: Apache 2.x web-server configuration for %name
Group: Networking/Other
Requires: %name = %version-%release, apache2
%description apache2
Apache 2.x web-server configuration for %name
%package php7
Summary: PHP7 dependencies for %name
Group: Networking/Other
Requires: %name = %version-%release
Requires: php7 >= 7.4
Requires: php7-curl, php7-fileinfo, php7-gd2, php7-json, php7-mbstring, php7-mysqlnd-mysqli, php7-session, php7-zlib, php7-simplexml, php7-xml, php7-intl
Requires: php7-apcu, php7-bz2, php7-exif, php7-ldap, php7-opcache, php7-openssl, php7-sodium, php7-xmlrpc, php7-zip
%description php7
PHP7 dependencies for %name
%package php8.0
Summary: PHP8.0 dependencies for %name
Group: Networking/Other
Requires: %name = %version-%release
Requires: php8.0
Requires: php8.0-curl, php8.0-fileinfo, php8.0-gd2, php8.0-json, php8.0-mbstring, php8.0-mysqlnd-mysqli, php8.0-session, php8.0-zlib, php8.0-simplexml, php8.0-xml, php8.0-intl
Requires: php8.0-apcu, php8.0-bz2, php8.0-exif, php8.0-ldap, php8.0-opcache, php8.0-openssl, php8.0-sodium, php8.0-xmlrpc, php8.0-zip
%description php8.0
php8.0 dependencies for %name
%package php8.1
Summary: PHP8.1 dependencies for %name
Group: Networking/Other
Requires: %name = %version-%release
Requires: php8.1
Requires: php8.1-curl, php8.1-fileinfo, php8.1-gd2, php8.1-json, php8.1-mbstring, php8.1-mysqlnd-mysqli, php8.1-session, php8.1-zlib, php8.1-simplexml, php8.1-xml, php8.1-intl
Requires: php8.1-apcu, php8.1-bz2, php8.1-exif, php8.1-ldap, php8.1-opcache, php8.1-openssl, php8.1-sodium, php8.1-zip
%description php8.1
php8.1 dependencies for %name
%package php8.2
Summary: PHP8.2 dependencies for %name
Group: Networking/Other
Requires: %name = %version-%release
Requires: php8.2
Requires: php8.2-curl, php8.2-fileinfo, php8.2-gd2, php8.2-json, php8.2-mbstring, php8.2-mysqlnd-mysqli, php8.2-session, php8.2-zlib, php8.2-simplexml, php8.2-xml, php8.2-intl
Requires: php8.2-apcu, php8.2-bz2, php8.2-exif, php8.2-ldap, php8.2-opcache, php8.2-openssl, php8.2-sodium, php8.2-zip
%description php8.2
php8.2 dependencies for %name
%prep
%setup
%build
%install
# install apache config
install -pD -m0644 %_sourcedir/apache2.conf %buildroot%_sysconfdir/httpd2/conf/sites-available/%name.conf
# install glpi
mkdir -p %buildroot%installdir
cp -rp . %buildroot%installdir
#install README.ALT and UPGRADE.ALT
install -pD -m0644 %_sourcedir/README.ALT README.ALT
install -pD -m0644 %_sourcedir/UPGRADE.ALT UPGRADE.ALT
# remove .htaccess files - we're use apache config instead
find %buildroot%installdir -name .htaccess -delete
# remove files
find $RPM_BUILD_ROOT \( -name 'Thumbs.db' -o -name 'Thumbs.db.gz' \) -print -delete
find %buildroot%installdir -name *.py -delete
find %buildroot%installdir -name remove.txt -delete
rm -rf %buildroot%installdir/vendor/sabre/dav/bin
%post
echo "If you upgrade from previous version (less than 9.5) then read /usr/share/doc/%name-%version/UPGRADE.ALT"
%post apache2
if [ "$1" = "1" ]; then
a2enmode rewrite
a2ensite %name
%_initdir/httpd2 condreload
fi
if [ "$1" = "2" ]; then
a2enmode rewrite
%_initdir/httpd2 condreload
fi
%preun apache2
if [ "$1" = "0" ]; then
a2dissite %name ||:
fi
%postun apache2
if [ "$1" = "0" ]; then
%_initdir/httpd2 condreload
fi
%files
%dir %installdir
%dir %attr(2770,root,%webserver_group) %installdir/config
%dir %attr(2770,root,%webserver_group) %installdir/files
%dir %attr(2770,root,%webserver_group) %installdir/files/_cache
%dir %attr(2770,root,%webserver_group) %installdir/files/_cron
%dir %attr(2770,root,%webserver_group) %installdir/files/_dumps
%dir %attr(2770,root,%webserver_group) %installdir/files/_graphs
%dir %attr(2770,root,%webserver_group) %installdir/files/_inventories
%dir %attr(2770,root,%webserver_group) %installdir/files/_locales
%dir %attr(2770,root,%webserver_group) %installdir/files/_lock
%dir %attr(2770,root,%webserver_group) %installdir/files/_log
%dir %attr(2770,root,%webserver_group) %installdir/files/_pictures
%dir %attr(2770,root,%webserver_group) %installdir/files/_plugins
%dir %attr(2770,root,%webserver_group) %installdir/files/_rss
%dir %attr(2770,root,%webserver_group) %installdir/files/_sessions
%dir %attr(2770,root,%webserver_group) %installdir/files/_tmp
%dir %attr(2770,root,%webserver_group) %installdir/files/_uploads
%dir %attr(2770,root,%webserver_group) %installdir/marketplace
%installdir/ajax
%installdir/bin
%installdir/css
%installdir/css_compiled
%installdir/front
%installdir/inc
%installdir/install
%installdir/js
%installdir/lib
%installdir/locales
%installdir/pics
%installdir/plugins
%installdir/public
%installdir/resources
%installdir/sound
%installdir/src
%installdir/templates
%installdir/vendor
%installdir/version
%installdir/*.php
%installdir/LICENSE
%doc CHANGELOG.md
%doc CONTRIBUTING.md
%doc README.md
%doc SUPPORT.md
%doc SECURITY.md
%doc apirest.md
%doc README.ALT
%doc UPGRADE.ALT
%files apache2
%config(noreplace) %attr(0644,root,root) %_sysconfdir/httpd2/conf/sites-available/%name.conf
%files php7
%files php8.0
%files php8.1
%files php8.2
%changelog
…
Полный changelog можно просмотреть здесь
Name: glpi
Version: 10.0.7
Release: alt1
Summary: IT and asset management software
License: GPLv3
Group: Networking/Other
URL: http://www.glpi-project.org
Packager: Pavel Zilke <zidex at altlinux dot org>
BuildArch: noarch
Source0: https://github.com/glpi-project/glpi/releases/download/%version/%name-%version.tgz
Source1: apache2.conf
Source2: README.ALT
Source3: UPGRADE.ALT
#Patch: patch0.patch
Requires: webserver-common php-engine curl lynx
BuildRequires(pre): rpm-macros-webserver-common
%description
GLPI is the Information Resource-Manager with an additional Administration-
Interface.
You can use it to build up a database with an inventory for your company
(computer, software, printers...).
It has enhanced functions to make the daily life for the administrators easier,
like a job-tracking-system with mail-notification and methods to build a
database with basic information about your network-topology.
%package apache2
Summary: Apache 2.x web-server configuration for %name
Group: Networking/Other
Requires: %name = %version-%release, apache2
%description apache2
Apache 2.x web-server configuration for %name
%package php7
Summary: PHP7 dependencies for %name
Group: Networking/Other
Requires: %name = %version-%release
Requires: php7 >= 7.4
Requires: php7-curl, php7-fileinfo, php7-gd2, php7-json, php7-mbstring, php7-mysqlnd-mysqli, php7-session, php7-zlib, php7-simplexml, php7-xml, php7-intl
Requires: php7-apcu, php7-bz2, php7-exif, php7-ldap, php7-opcache, php7-openssl, php7-sodium, php7-xmlrpc, php7-zip
%description php7
PHP7 dependencies for %name
%package php8.0
Summary: PHP8.0 dependencies for %name
Group: Networking/Other
Requires: %name = %version-%release
Requires: php8.0
Requires: php8.0-curl, php8.0-fileinfo, php8.0-gd2, php8.0-json, php8.0-mbstring, php8.0-mysqlnd-mysqli, php8.0-session, php8.0-zlib, php8.0-simplexml, php8.0-xml, php8.0-intl
Requires: php8.0-apcu, php8.0-bz2, php8.0-exif, php8.0-ldap, php8.0-opcache, php8.0-openssl, php8.0-sodium, php8.0-xmlrpc, php8.0-zip
%description php8.0
php8.0 dependencies for %name
%package php8.1
Summary: PHP8.1 dependencies for %name
Group: Networking/Other
Requires: %name = %version-%release
Requires: php8.1
Requires: php8.1-curl, php8.1-fileinfo, php8.1-gd2, php8.1-json, php8.1-mbstring, php8.1-mysqlnd-mysqli, php8.1-session, php8.1-zlib, php8.1-simplexml, php8.1-xml, php8.1-intl
Requires: php8.1-apcu, php8.1-bz2, php8.1-exif, php8.1-ldap, php8.1-opcache, php8.1-openssl, php8.1-sodium, php8.1-zip
%description php8.1
php8.1 dependencies for %name
%package php8.2
Summary: PHP8.2 dependencies for %name
Group: Networking/Other
Requires: %name = %version-%release
Requires: php8.2
Requires: php8.2-curl, php8.2-fileinfo, php8.2-gd2, php8.2-json, php8.2-mbstring, php8.2-mysqlnd-mysqli, php8.2-session, php8.2-zlib, php8.2-simplexml, php8.2-xml, php8.2-intl
Requires: php8.2-apcu, php8.2-bz2, php8.2-exif, php8.2-ldap, php8.2-opcache, php8.2-openssl, php8.2-sodium, php8.2-zip
%description php8.2
php8.2 dependencies for %name
%prep
%setup
%build
%install
# install apache config
install -pD -m0644 %_sourcedir/apache2.conf %buildroot%_sysconfdir/httpd2/conf/sites-available/%name.conf
# install glpi
mkdir -p %buildroot%installdir
cp -rp . %buildroot%installdir
#install README.ALT and UPGRADE.ALT
install -pD -m0644 %_sourcedir/README.ALT README.ALT
install -pD -m0644 %_sourcedir/UPGRADE.ALT UPGRADE.ALT
# remove .htaccess files - we're use apache config instead
find %buildroot%installdir -name .htaccess -delete
# remove files
find $RPM_BUILD_ROOT \( -name 'Thumbs.db' -o -name 'Thumbs.db.gz' \) -print -delete
find %buildroot%installdir -name *.py -delete
find %buildroot%installdir -name remove.txt -delete
rm -rf %buildroot%installdir/vendor/sabre/dav/bin
%post
echo "If you upgrade from previous version (less than 9.5) then read /usr/share/doc/%name-%version/UPGRADE.ALT"
%post apache2
if [ "$1" = "1" ]; then
a2enmode rewrite
a2ensite %name
%_initdir/httpd2 condreload
fi
if [ "$1" = "2" ]; then
a2enmode rewrite
%_initdir/httpd2 condreload
fi
%preun apache2
if [ "$1" = "0" ]; then
a2dissite %name ||:
fi
%postun apache2
if [ "$1" = "0" ]; then
%_initdir/httpd2 condreload
fi
%files
%dir %installdir
%dir %attr(2770,root,%webserver_group) %installdir/config
%dir %attr(2770,root,%webserver_group) %installdir/files
%dir %attr(2770,root,%webserver_group) %installdir/files/_cache
%dir %attr(2770,root,%webserver_group) %installdir/files/_cron
%dir %attr(2770,root,%webserver_group) %installdir/files/_dumps
%dir %attr(2770,root,%webserver_group) %installdir/files/_graphs
%dir %attr(2770,root,%webserver_group) %installdir/files/_inventories
%dir %attr(2770,root,%webserver_group) %installdir/files/_locales
%dir %attr(2770,root,%webserver_group) %installdir/files/_lock
%dir %attr(2770,root,%webserver_group) %installdir/files/_log
%dir %attr(2770,root,%webserver_group) %installdir/files/_pictures
%dir %attr(2770,root,%webserver_group) %installdir/files/_plugins
%dir %attr(2770,root,%webserver_group) %installdir/files/_rss
%dir %attr(2770,root,%webserver_group) %installdir/files/_sessions
%dir %attr(2770,root,%webserver_group) %installdir/files/_tmp
%dir %attr(2770,root,%webserver_group) %installdir/files/_uploads
%dir %attr(2770,root,%webserver_group) %installdir/marketplace
%installdir/ajax
%installdir/bin
%installdir/css
%installdir/css_compiled
%installdir/front
%installdir/inc
%installdir/install
%installdir/js
%installdir/lib
%installdir/locales
%installdir/pics
%installdir/plugins
%installdir/public
%installdir/resources
%installdir/sound
%installdir/src
%installdir/templates
%installdir/vendor
%installdir/version
%installdir/*.php
%installdir/LICENSE
%doc CHANGELOG.md
%doc CONTRIBUTING.md
%doc README.md
%doc SUPPORT.md
%doc SECURITY.md
%doc apirest.md
%doc README.ALT
%doc UPGRADE.ALT
%files apache2
%config(noreplace) %attr(0644,root,root) %_sysconfdir/httpd2/conf/sites-available/%name.conf
%files php7
%files php8.0
%files php8.1
%files php8.2
%changelog
…
Полный changelog можно просмотреть здесь