summaryrefslogtreecommitdiffstats
path: root/php-getid3.spec
blob: b51c4421dad92ab69d0664a0b0e094ee0090baa8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
# remirepo spec file for php-getid3, from:
#
# Fedora spec file for php-getid3
#
# License: MIT
# http://opensource.org/licenses/MIT
#
# Please preserve changelog entries
#
%global gh_commit    06c7482532ff2b3f9111b011d880ca6699c8542b
%global gh_short     %(c=%{gh_commit}; echo ${c:0:7})
%global gh_owner     JamesHeinrich
%global gh_project   getID3
%global pk_owner     james-heinrich
%global pk_project   getid3

Name:      php-%{pk_project}
Version:   1.9.23
Release:   1%{?dist}
Epoch:     1
License:   GPL-1.0-or-later OR LGPL-3.0-only OR MPL-2.0
Summary:   The PHP media file parser
URL:       https://www.getid3.org/
Source0:   %{name}-%{version}-%{gh_short}.tgz
Source1:   makesrc.sh

BuildArch: noarch
BuildRequires: php-fedora-autoloader-devel

# from composer.json
#        "php": ">=5.3.0"
Requires:  php(language) >= 5.3.0
# from phpcompatinfo for version 1.9.16
Requires:  php-simplexml
Requires:  php-ctype
Requires:  php-date
Requires:  php-exif
Requires:  php-filter
Requires:  php-gd
Requires:  php-iconv
Requires:  php-json
Requires:  php-libxml
Requires:  php-mbstring
Requires:  php-pcre
Requires:  php-xml
%if 0%{?fedora} >= 27 || 0%{?rhel} >= 8
Suggests: php-dba
Suggests: php-mysqli
Suggests: php-rar
Suggests: php-sqlite3
%endif
# Autoloader
Requires:  php-composer(fedora/autoloader)

Provides:  php-composer(%{pk_owner}/%{pk_project}) = %{version}


%description
getID3() is a PHP script that extracts useful information 
(such as ID3 tags, bitrate, playtime, etc.) from MP3s & 
other multimedia file formats (Ogg, WMA, WMV, ASF, WAV, AVI, 
AAC, VQF, FLAC, MusePack, Real, QuickTime, Monkey's Audio, MIDI and more).

Autoloader: %{_datadir}/php/getid3/autoload.php


%prep
%setup -q -n %{gh_project}-%{gh_commit}



%build
# From composer.json, "autoload": {
#        "classmap": ["getid3/"]
%{_bindir}/phpab --template fedora --output getid3/autoload.php getid3


%install
mkdir -p %{buildroot}%{_datadir}/php
cp -a getid3 %{buildroot}%{_datadir}/php/


%check
php -r '
require "%{buildroot}%{_datadir}/php/getid3/autoload.php";
$ok = class_exists("getID3");
echo "Autoload: " . ($ok ? "Ok\n" : "fails\n");
echo "Version: " . getID3::VERSION . "\n";
$ok = ($ok && strpos(getID3::VERSION, "%{version}") !== false);
exit ($ok ? 0 : 1);
'


%files
# remirepo:1
%{!?_licensedir:%global license %%doc}
%license licenses license.txt
%doc changelog.txt dependencies.txt readme.txt structure.txt demos
%doc composer.json
%{_datadir}/php/getid3


%changelog
* Thu Oct 19 2023 Remi Collet <remi@remirepo.net> - 1.9.23-1
- update to 1.9.23
- fix license with SPDX ids

* Fri Sep 30 2022 Remi Collet <remi@remirepo.net> - 1.9.22-1
- update to 1.9.22

* Thu Sep 23 2021 Remi Collet <remi@remirepo.net> - 1.9.21-1
- update to 1.9.21

* Wed Jul  1 2020 Remi Collet <remi@remirepo.net> - 1.9.20-1
- update to 1.9.20

* Wed Dec 18 2019 Remi Collet <remi@remirepo.net> - 1.9.19-1
- update to 1.9.19

* Tue Sep 17 2019 Remi Collet <remi@remirepo.net> - 1.9.18-1
- update to 1.9.18
- use git snapshot for sources

* Fri Feb  8 2019 Remi Collet <remi@remirepo.net> - 1.9.17-1
- update to 1.9.17
- add weak dependencies on suggested extension

* Thu Oct 18 2018 Remi Collet <remi@remirepo.net> - 1.9.16-1
- update to 1.9.16

* Mon Oct 30 2017 Remi Collet <remi@remirepo.net> - 1.9.15-1
- Update to 1.9.15

* Tue Mar 28 2017 Remi Collet <remi@remirepo.net> - 1:1.9.14-1
- Update to 1.9.14
- handle all classes in autoloader

* Thu Dec 15 2016 Remi Collet <remi@fedoraproject.org> - 1:1.9.13-1
- update to 1.9.13
- use new URL http://www.getid3.org/
- use sources from github
- switch to fedora/autoloader
- add minimal check for autoloader

* Mon Mar 21 2016 Remi Collet <remi@fedoraproject.org> - 1:1.9.12-1
- update to 1.9.12
- add simple classmap autoloader

* Fri Dec 19 2014 Remi Collet <remi@fedoraproject.org> - 1:1.9.9-1
- new release 1.9.9

* Thu Aug 21 2014 Remi Collet <remi@fedoraproject.org> - 1:1.9.8-2
- fix minimal PHP version
- add explicit dependencies for all php extensions
- fix license handling
- provides php-composer(james-heinrich/getid3)

* Wed Aug 20 2014 Adam Williamson <awilliam@redhat.com> - 1:1.9.8-1
- new release 1.9.8

* Sun Sep  8 2013 Remi Collet <RPMS@famillecollet.com> - 1:1.9.7-1
- backport 1.9.7 for remi repo

* Sun Sep 08 2013 Roma <roma@lcg.ufrj.br> - 1:1.9.7-1
- Updated to 1.9.7
- Changed license to LGPLv3+

* Sun Nov 25 2012 Remi Collet <RPMS@famillecollet.com> - 1:1.9.3-1
- backport 1.9.3 for remi repo

* Sun Oct 07 2012 Paulo Roma <roma@lcg.ufrj.br> - 1:1.9.3-1
- Downgraded to latest stable version.
- Got needed extensions by using:
  phpci print --recursive --report extension /usr/share/php/getid3/
- Added BR php-gd.

* Sat Jan 14 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.0.0b5-4
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild

* Wed Feb 09 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.0.0b5-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild


* Fri Jul 31 2009 Paulo Roma <roma@lcg.ufrj.br> 2.0.0b5-2
- Updated ampache patch.

* Thu Jun 04 2009 Paulo Roma <roma@lcg.ufrj.br> 2.0.0b5-1
- Updated to 2.0.0b5
- Patched with ampache fixes.

* Thu Jun 04 2009 Paulo Roma <roma@lcg.ufrj.br> 1.7.9-1
- Initial spec file.