[php-pecl-ncurses: 1/2] PHP 5.4.0 Build
Remi Collet
remi at fedoraproject.org
Fri Jan 20 18:04:31 UTC 2012
commit c18ffabf52b6340525bb46625e047f251311ac4c
Author: remi <fedora at famillecollet.com>
Date: Fri Jan 20 19:02:51 2012 +0100
PHP 5.4.0 Build
php-pecl-ncurses.spec | 45 ++++++++++++++++++++++++---------------------
1 files changed, 24 insertions(+), 21 deletions(-)
---
diff --git a/php-pecl-ncurses.spec b/php-pecl-ncurses.spec
index ae000f6..a87e86a 100644
--- a/php-pecl-ncurses.spec
+++ b/php-pecl-ncurses.spec
@@ -6,7 +6,7 @@
Summary: Terminal screen handling and optimization package
Name: php-pecl-ncurses
Version: 1.0.1
-Release: 3%{?dist}
+Release: 4%{?dist}
License: PHP
Group: Development/Languages
URL: http://pecl.php.net/package/ncurses
@@ -26,10 +26,11 @@ Requires: php(zend-abi) = %{php_zend_api}
Requires: php(api) = %{php_core_api}
-%{?filter_setup:
-%filter_provides_in %{php_extdir}/.*\.so$
-%filter_setup
-}
+# RPM 4.8
+%{?filter_provides_in: %filter_provides_in %{php_extdir}/.*\.so$}
+%{?filter_setup}
+# RPM 4.9
+%global __provides_exclude_from %{?__provides_exclude_from:%__provides_exclude_from|}%{php_extdir}/.*\\.so$
%description
@@ -47,7 +48,10 @@ line.
%setup -c -q
%{_bindir}/php -n %{SOURCE2} package.xml >CHANGELOG
-cd %{pecl_name}-%{version}
+cat >%{pecl_name}.ini << 'EOF'
+; Enable %{pecl_name} extension module
+extension=%{pecl_name}.so
+EOF
%build
@@ -55,36 +59,31 @@ cd %{pecl_name}-%{version}
phpize
%configure --enable-ncursesw
-%{__make} %{?_smp_mflags}
+make %{?_smp_mflags}
%install
-cd %{pecl_name}-%{version}
-%{__rm} -rf %{buildroot}
-%{__make} install INSTALL_ROOT=%{buildroot}
+rm -rf %{buildroot}
-# Drop in the bit of configuration
-%{__mkdir_p} %{buildroot}%{_sysconfdir}/php.d
-%{__cat} > %{buildroot}%{_sysconfdir}/php.d/%{pecl_name}.ini << 'EOF'
-; Enable %{pecl_name} extension module
-extension=%{pecl_name}.so
-EOF
+make -C %{pecl_name}-%{version} \
+ install INSTALL_ROOT=%{buildroot}
# Install XML package description
-# use 'name' rather than 'pecl_name' to avoid conflict with pear extensions
-%{__mkdir_p} %{buildroot}%{pecl_xmldir}
-%{__install} -m 644 ../package.xml %{buildroot}%{pecl_xmldir}/%{name}.xml
+install -Dpm 644 package.xml %{buildroot}%{pecl_xmldir}/%{name}.xml
+
+# install config file
+install -Dpm 644 %{pecl_name}.ini %{buildroot}%{_sysconfdir}/php.d/%{pecl_name}.ini
%check
cd %{pecl_name}-%{version}
TEST_PHP_EXECUTABLE=$(which php) php run-tests.php \
- -n -q -d extension_dir=modules \
+ -n -q -d extension_dir=%{buildroot}%{php_extdir} \
-d extension=%{pecl_name}.so \
%clean
-%{__rm} -rf %{buildroot}
+rm -rf %{buildroot}
%if 0%{?pecl_install:1}
@@ -110,6 +109,10 @@ fi
%changelog
+* Thu Jan 19 2012 Remi Collet <remi at fedoraproject.org> - 1.0.1-4
+- build against php 5.4
+- fix filters
+
* Wed Feb 09 2011 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 1.0.1-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
More information about the scm-commits
mailing list