From 08662abec2537789d300217d1c246a8b4c734212 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Arkadiusz=20Mi=C5=9Bkiewicz?= Date: Thu, 3 Apr 2014 12:45:27 +0200 Subject: [PATCH] - up to 6.0.0 (supports PHP5.4 only) --- ZendGuardLoader.spec | 44 +++++++++++++++++++++++--------------------- 1 file changed, 23 insertions(+), 21 deletions(-) diff --git a/ZendGuardLoader.spec b/ZendGuardLoader.spec index 75c0620..2306170 100644 --- a/ZendGuardLoader.spec +++ b/ZendGuardLoader.spec @@ -7,14 +7,15 @@ Summary: Zend Guard - PHP code guard Summary(pl.UTF-8): Zend Guard - optymalizator kodu PHP Name: ZendGuardLoader -Version: 5.5.0 +Version: 6.0.0 Release: 1 License: Zend License, distributable only if unmodified and for free (see LICENSE) Group: Libraries -Source0: http://downloads.zend.com/guard/5.5.0/%{name}-php-5.3-linux-glibc23-i386.tar.gz -# Source0-md5: f53e51ecb59e390be5551ff7cc8576b0 -Source1: http://downloads.zend.com/guard/5.5.0/%{name}-php-5.3-linux-glibc23-x86_64.tar.gz -# Source1-md5: 9408297e9e38d5ce2cca92c619b5ad50 +# http://mewbies.com/zend_ioncube/zend_guard_direct_download_links.txt +Source0: http://downloads.zend.com/guard/6.0.0/%{name}-70429-PHP-5.4-linux-glibc23-i386.tar.gz +# Source0-md5: 9a25ff3c2fa4cb37602ba6d6491e859e +Source1: http://downloads.zend.com/guard/6.0.0/%{name}-70429-PHP-5.4-linux-glibc23-x86_64.tar.gz +# Source1-md5: 09d0da0046eb70c3d704db1e0074098e URL: http://www.zend.com/products/zend_guard BuildRequires: rpmbuild(macros) >= 1.344 BuildRequires: tar >= 1:1.15.1 @@ -28,17 +29,18 @@ Zend Guard - PHP code guard. %description -l pl.UTF-8 Zend Guard - optymalizator kodu PHP. -%package -n php-%{name} +%package -n php%{?php_suffix}-%{name} Summary: Zend Guard for PHP 5.x Summary(pl.UTF-8): Zend Guard dla PHP 5.x Group: Libraries Requires: %{name} = %{version}-%{release} -Requires: php-common >= 4:5.3 +Requires: php%{?php_suffix}-common >= 4:5.4 +Requires: php%{?php_suffix}-common < 4:5.5 -%description -n php-%{name} +%description -n php%{?php_suffix}-%{name} Zend Guard for PHP 5.x. -%description -n php-%{name} -l pl.UTF-8 +%description -n php%{?php_suffix}-%{name} -l pl.UTF-8 Zend Guard dla PHP 5.x. %prep @@ -65,36 +67,36 @@ cat <<'EOF' > zendguardloaderpack.ini ; if you need to add options, edit %{name}.ini instead [Zend] zend_guard.version=%{version} -zend_extension=%{_libdir}/Zend/lib/GuardLoader-%{version}/php-5.3.x/ZendGuardLoader.so +zend_extension=%{_libdir}/Zend/lib/GuardLoader-%{version}/php-5.4.x/ZendGuardLoader.so EOF %install rm -rf $RPM_BUILD_ROOT -install -d $RPM_BUILD_ROOT{%{_bindir},%{_sysconfdir}/php} +install -d $RPM_BUILD_ROOT{%{_bindir},%{_sysconfdir}/php%{?php_suffix}} for d in php-*; do install -D $d/ZendGuardLoader.so $RPM_BUILD_ROOT%{_libdir}/Zend/lib/GuardLoader-%{version}/$d/ZendGuardLoader.so done -ln -s %{_sysconfdir}/php $RPM_BUILD_ROOT%{_libdir}/Zend%{_sysconfdir} +ln -s %{_sysconfdir}/php%{?php_suffix} $RPM_BUILD_ROOT%{_libdir}/Zend%{_sysconfdir} -install -d $RPM_BUILD_ROOT%{_sysconfdir}/php/conf.d -install zendguardloader.ini $RPM_BUILD_ROOT%{_sysconfdir}/php/conf.d/zendguardloader.ini -install zendguardloaderpack.ini $RPM_BUILD_ROOT%{_sysconfdir}/php/conf.d/zendguardloader_pack.ini +install -d $RPM_BUILD_ROOT%{_sysconfdir}/php%{?php_suffix}/conf.d +install zendguardloader.ini $RPM_BUILD_ROOT%{_sysconfdir}/php%{?php_suffix}/conf.d/zendguardloader.ini +install zendguardloaderpack.ini $RPM_BUILD_ROOT%{_sysconfdir}/php%{?php_suffix}/conf.d/zendguardloader_pack.ini %clean rm -rf $RPM_BUILD_ROOT -%preun -n php-%{name} +%preun -n php%{?php_suffix}-%{name} if [ "$1" = "0" ]; then %php_webserver_restart fi -%post -n php-%{name} +%post -n php%{?php_suffix}-%{name} # let %{_prefix}/lib/Zend%{_sysconfdir} point to php's config dir. php which installed first wins. # not sure how critical is existence of this etc link at all. if [ ! -L %{_libdir}/Zend%{_sysconfdir} ]; then -ln -snf %{_sysconfdir}/php %{_libdir}/Zend%{_sysconfdir} +ln -snf %{_sysconfdir}/php%{?php_suffix} %{_libdir}/Zend%{_sysconfdir} fi %php_webserver_restart @@ -115,7 +117,7 @@ fi %attr(755,root,root) %{_libdir}/Zend/lib/GuardLoader-%{version}/php-*/ZendGuardLoader.so %ghost %{_libdir}/Zend%{_sysconfdir} -%files -n php-%{name} +%files -n php%{?php_suffix}-%{name} %defattr(644,root,root,755) -%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/php/conf.d/zendguardloader.ini -%config %verify(not md5 mtime size) %{_sysconfdir}/php/conf.d/zendguardloader_pack.ini +%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/php%{?php_suffix}/conf.d/zendguardloader.ini +%config %verify(not md5 mtime size) %{_sysconfdir}/php%{?php_suffix}/conf.d/zendguardloader_pack.ini -- 2.43.0