source: projects/specs/trunk/p/php-ext-phpredis/php-ext-phpredis-vl.spec @ 12516

Revision 12516, 4.4 KB checked in by tomop, 3 years ago (diff)

updated 4 packages

php-ext-clearsilver-0.4-16

php-ext-mailparse-3.1.1-1

php-ext-memcached-3.1.5.git20201219-1

php-ext-phpredis-5.3.2-1

  • Property svn:executable set to *
Line 
1%define extname phpredis
2
3Summary: A redis extension for PHP
4Summary(ja): PHP用redis拡張
5Name: php-ext-phpredis
6Version: 5.3.2
7Release: 1%{_dist_release}
8Group: programming
9Vendor: Project Vine
10Distribution: Vine Linux
11Packager: tomop
12
13Source: https://github.com/phpredis/phpredis/archive/%{version}.tar.gz#/phpredis-%{version}.tgz
14License: The PHP License
15BuildRoot: %{_tmppath}/%{name}-%{version}-root
16
17%description
18 The phpredis extension provides an API for communicating with the Redis
19key-value store.
20
21%description -l ja
22 phpredis拡張は、Redis KVSと通信するためのAPIを提供します。
23
24
25%package -n php80-ext-phpredis
26Summary: A redis extension for PHP
27Summary(ja): PHP用redis拡張
28Group: programming
29BuildRequires: php80-devel
30%if "%{?req_php80_api}" != ""
31Requires: %{req_php80_api}
32%endif
33
34%description -n php80-ext-phpredis
35 The phpredis extension provides an API for communicating with the Redis
36key-value store.
37
38%description -n php80-ext-phpredis -l ja
39 phpredis拡張は、Redis KVSと通信するためのAPIを提供します。
40
41
42%package -n php74-ext-phpredis
43Summary: A redis extension for PHP
44Summary(ja): PHP用redis拡張
45Group: programming
46BuildRequires: php74-devel
47%if "%{?req_php74_api}" != ""
48Requires: %{req_php74_api}
49%endif
50
51%description -n php74-ext-phpredis
52 The phpredis extension provides an API for communicating with the Redis
53key-value store.
54
55%description -n php74-ext-phpredis -l ja
56 phpredis拡張は、Redis KVSと通信するためのAPIを提供します。
57
58
59%debug_package
60
61
62%prep
63%setup -q -c -n phpredis-%{version}
64cp %{extname}-%{version}/{COPYING,CREDITS,Changelog.md,*.markdown} ./
65
66cp -a %{extname}-%{version} php80
67pushd php80
68phpize80
69popd
70
71cp -a %{extname}-%{version} php74
72pushd php74
73phpize74
74popd
75
76
77%build
78pushd php80
79%configure --with-php-config=%{_bindir}/php-config80
80%__make %{?_smp_mflags}
81popd
82
83pushd php74
84%configure --with-php-config=%{_bindir}/php-config74
85%__make %{?_smp_mflags}
86popd
87
88
89%install
90rm -rf %{buildroot}
91pushd php80
92mkdir -p %{buildroot}%{_libdir}/php80/
93mkdir -p %{buildroot}%{_sysconfdir}/php80/php.d
94%makeinstall INSTALL_ROOT=%{buildroot}
95
96cat > %{buildroot}%{_sysconfdir}/php80/php.d/redis.ini <<EOF
97; Enable redis extension module
98extension=redis.so
99
100;session.save_handler = redis
101;session.save_path = "tcp://host1:6379?weight=1, tcp://host2:6379?weight=2&timeout=2.5, tcp://host3:6379?weight=2&read_timeout=2.5"
102
103; Should the locking be enabled? Defaults to: 0.
104;redis.session.locking_enabled = 1
105; How long should the lock live (in seconds)? Defaults to: value of max_execution_time.
106;redis.session.lock_expire = 60
107; How long to wait between attempts to acquire lock, in microseconds (µs)?. Defaults to: 2000
108;redis.session.lock_wait_time = 50000
109; Maximum number of times to retry (-1 means infinite). Defaults to: 10
110;redis.session.lock_retries = 10
111
112EOF
113popd
114
115pushd php74
116mkdir -p %{buildroot}%{_libdir}/php74/
117mkdir -p %{buildroot}%{_sysconfdir}/php74/php.d
118%makeinstall INSTALL_ROOT=%{buildroot}
119
120cat > %{buildroot}%{_sysconfdir}/php74/php.d/redis.ini <<EOF
121; Enable redis extension module
122extension=redis.so
123
124;session.save_handler = redis
125;session.save_path = "tcp://host1:6379?weight=1, tcp://host2:6379?weight=2&timeout=2.5, tcp://host3:6379?weight=2&read_timeout=2.5"
126
127; Should the locking be enabled? Defaults to: 0.
128;redis.session.locking_enabled = 1
129; How long should the lock live (in seconds)? Defaults to: value of max_execution_time.
130;redis.session.lock_expire = 60
131; How long to wait between attempts to acquire lock, in microseconds (µs)?. Defaults to: 2000
132;redis.session.lock_wait_time = 50000
133; Maximum number of times to retry (-1 means infinite). Defaults to: 10
134;redis.session.lock_retries = 10
135
136EOF
137popd
138
139
140%clean
141rm -rf %{buildroot}
142
143
144%files -n php80-ext-phpredis
145%defattr(-,root,root)
146%license COPYING
147%doc CREDITS Changelog.md *.markdown
148%{_libdir}/php80/*
149%config(noreplace) %{_sysconfdir}/php80/php.d/*
150
151%files -n php74-ext-phpredis
152%defattr(-,root,root)
153%license COPYING
154%doc CREDITS Changelog.md *.markdown
155%{_libdir}/php74/*
156%config(noreplace) %{_sysconfdir}/php74/php.d/*
157
158
159%changelog
160* Sat Dec 19 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.3.2-1
161- new upstream release.
162- added php80 support.
163
164* Thu Dec 19 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.1.1-1
165- new upstream release.
166- built for php74.
167
168* Thu Aug 22 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 5.0.2-1
169- initial build for Vine Linux.
Note: See TracBrowser for help on using the repository browser.