A new user interface for you! Read more...

File dba-php-549-apc.spec of Package dba-php-549-apc

%define pkg_name        APC
%define real_vers       3.1.13

%define php_version     5.4.9
%define php_vers        549
%define prefix          /DBA/apache/PHP/%{php_version}
%define phpcmd          %{prefix}/bin/php
%define phpize          %{prefix}/bin/phpize
%define phpconf         %{prefix}/bin/php-config
%define maketest        0

Name:           dba-php-%{php_vers}-apc
Summary: 	Alternative PHP Cache
Version: 	%{real_vers}
Release: 	0
License: 	BSD
Group: 		Productivity/Networking/Web/Servers
URL: 		http://pecl.php.net/package/APC
Source: 	http://pecl.php.net/get/%{pkg_name}-%{version}.tgz
Source1: 	apc.ini
BuildRoot: 	%{_tmppath}/%{pkg_name}-%{real_vers}-build

%if 0%{?suse_version} >= 1100
BuildRequires:  -post-build-checks
%endif

BuildRequires:	dba-php-%{php_vers}
#!BuildIgnore:  dba-postgresql-839 dba-postgresql-842 dba-postgresql-845 dba-postgresql-846 dba-postgresql-904 dba-postgresql-910
#!BuildIgnore:  dba-openssl-098o dba-openssl-098r dba-openssl-098x dba-openssl-101c


%description
APC is a free, open, and robust framework for caching and optimizing PHP
intermediate code.

 Authors:
----------
    George Schlossnagle <george@omniti.com>
    Daniel Cowgill <dan@communityconnect.com>
    Rasmus Lerdorf <rasmus@php.net>



%prep
%setup -q -n %{pkg_name}-%{real_vers}


%build
CFLAGS="%{optflags} -fno-strict-aliasing"
CXXFLAGS="%{optflags} -fno-strict-aliasing"
%if 0%{?suse_version} > 1000
CFLAGS="$CFLAGS -fstack-protector"
CXXFLAGS="$CXXFLAGS -fstack-protector"
%endif

export CFLAGS
export CXXFLAGS

%{phpize}

%configure \
  --enable-apc-filehits \
  --enable-apc-mmap \
  --with-php-config=%{phpconf} 

%{__make} %{?jobs:-j%jobs}


%check
%if %maketest
%{__make} test PHP_EXECUTABLE=%{phpcmd}
%endif


%clean
%{__rm} -rf %{buildroot}


%install
# %makeinstall INSTALL_ROOT=%{buildroot}
%{__mkdir_p} %{buildroot}%{prefix}/conf
%{__mkdir_p} %{buildroot}%{prefix}/lib/php/extensions
%{__install} -m 0755 ./.libs/apc.so %{buildroot}%{prefix}/lib/php/extensions/
%{__install} -m 0644 %{S:1} %{buildroot}%{prefix}/conf/apc.ini
%{__rm} -rf %{buildroot}%{prefix}/include/php/ext


%files
%defattr(-,root,root,-)
%dir %{prefix}/conf
%dir %{prefix}/lib/php/extensions
%{prefix}/conf/apc.ini
%{prefix}/lib/php/extensions/apc.so


%changelog
* Fri Nov 23 2012 Holger Manthey <holger.manthey@bertelsmann.de>
- inital version