1 %define _noautoreqfiles vendor/paragonie/random_compat/psalm-autoload.php
2 Summary: phpMyAdmin - web-based MySQL administration
3 Summary(pl.UTF-8): phpMyAdmin - administracja bazami MySQL przez WWW
8 Group: Applications/Databases/Interfaces
9 Source0: https://files.phpmyadmin.net/%{name}/%{version}/%{name}-%{version}-all-languages.tar.xz
10 # Source0-md5: e73377b11b7d38fa3f3014f2799c5252
11 Source1: %{name}-apache.conf
12 Source2: %{name}-lighttpd.conf
13 Patch0: %{name}-config.patch
14 Patch1: %{name}-disable-version-check.patch
15 URL: http://www.phpmyadmin.net/
16 BuildRequires: rpmbuild(macros) >= 1.268
17 BuildRequires: tar >= 1:1.22
19 # phpMyAdmin doesn't support mysql < 5.5 and won't work with php < 7.1
20 Requires: mysql-libs >= 5.5
21 Requires: php(core) >= 7.1
26 Requires: php(mbstring)
29 Requires: php(session)
30 Requires: php(simplexml)
32 Requires: webserver(access)
33 Requires: webserver(alias)
34 Requires(triggerpostun): sed >= 4.0
35 Suggests: webserver(indexfile)
36 Suggests: webserver(php)
38 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
40 %define _appdir %{_datadir}/%{name}
41 %define _webapps /etc/webapps
42 %define _webapp %{name}
43 %define _sysconfdir %{_webapps}/%{_webapp}
46 phpMyAdmin can administer a whole MySQL-server (needs a super-user)
47 but also a single database. To accomplish the latter you'll need a
48 properly set up MySQL-user who can read/write only the desired
49 database. It's up to you to look up the appropiate part in the MySQL
50 manual. Currently phpMyAdmin can:
51 - create and drop databases
52 - create, copy, drop and alter tables
53 - delete, edit and add fields
54 - execute any SQL-statement, even batch-queries
55 - manage keys on fields
56 - load text files into tables
57 - create (*) and read dumps of tables
58 - export (*) and import data to CSV values
59 - administer multiple servers and single databases
60 - check referencial integrity
61 - create complex queries automatically connecting required tables
62 - create PDF graphics of your database layout
63 - communicate in more than 50 different languages
65 %description -l pl.UTF-8
66 phpMyAdmin potrafi zarządzać całymi bazami MySQL (potrzebne
67 uprawnienia superużytkownika) jak i pojedynczymi bazami danych.
68 Potrzebny jest użytkownik, który ma prawa zapisu/odczytu tylko tych
69 baz, którymi chcemy administrować (więcej informacji w odpowiedniej
70 podręcznika MySQL). Aktualnie phpMyAdmin potrafi:
71 - tworzyć i usuwać bazy
72 - wykonywać create, copy, drop oraz alter na tabelach
73 - dodawać, usuwać i modyfikować pola
74 - wykonywać dowolne zapytania SQL
75 - zarządzać kluczami na rekordach
76 - wczytywać tekst z plików do tabel
77 - obsługiwać ponad 20 języków
78 - zarządzać wieloma serwerami i pojedynczymi bazami danych
79 - eksportować i importować dane do wartości CSV
80 - tworzyć i czytać zrzuty tabel
83 %setup -q -n %{name}-%{version}-all-languages
87 # cleanup backups after patching
88 find '(' -name '*~' -o -name '*.orig' ')' -print0 | xargs -0 -r -l512 rm -f
91 rm -rf $RPM_BUILD_ROOT
92 install -d $RPM_BUILD_ROOT{%{_sysconfdir},%{_appdir}/tmp}
94 cp -p *.php *.css *.json *.lock favicon.ico robots.txt $RPM_BUILD_ROOT%{_appdir}
95 cp -a js libraries locale sql templates themes vendor $RPM_BUILD_ROOT%{_appdir}
97 cp -p libraries/config.default.php $RPM_BUILD_ROOT%{_sysconfdir}/config.inc.php
98 ln -sf %{_sysconfdir}/config.inc.php $RPM_BUILD_ROOT%{_appdir}/config.inc.php
100 cp -p %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/httpd.conf
101 cp -p %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/apache.conf
102 cp -p %{SOURCE2} $RPM_BUILD_ROOT%{_sysconfdir}/lighttpd.conf
105 rm -rf $RPM_BUILD_ROOT
107 %triggerin -- apache1 < 1.3.37-3, apache1-base
108 %webapp_register apache %{_webapp}
110 %triggerun -- apache1 < 1.3.37-3, apache1-base
111 %webapp_unregister apache %{_webapp}
113 %triggerin -- apache < 2.2.0, apache-base
114 %webapp_register httpd %{_webapp}
116 %triggerun -- apache < 2.2.0, apache-base
117 %webapp_unregister httpd %{_webapp}
119 %triggerin -- lighttpd
120 %webapp_register lighttpd %{_webapp}
122 %triggerun -- lighttpd
123 %webapp_unregister lighttpd %{_webapp}
126 %defattr(644,root,root,755)
127 %doc ChangeLog README examples
128 %dir %attr(750,root,http) %{_sysconfdir}
129 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/apache.conf
130 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/httpd.conf
131 %attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/lighttpd.conf
132 %attr(640,root,http) %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/*.php
140 %dir %attr(770,http,http) %{_appdir}/tmp
146 %{_appdir}/favicon.ico
147 %{_appdir}/robots.txt