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
|
# $Id: /local/php5-mysqli/debian/packages 336 2005-07-04T15:11:06.825194Z dexter $
# If the debian/rules or debian/control file is missing, rebuild the file:
#
# $ yada rebuild control
# $ yada rebuild rules
%define zendmoduleapi_version %`egrep '\#define ZEND_MODULE_API_NO ' /usr/include/php5/Zend/zend_modules.h | sed 's/\#define ZEND_MODULE_API_NO //'`
# zendmoduleapi_version=%{zendmoduleapi_version}
%define zendextensionapi_version %`egrep '\#define ZEND_EXTENSION_API_NO[[:space:]]*' /usr/include/php5/Zend/zend_extensions.h | sed 's/\#define ZEND_EXTENSION_API_NO[[:space:]]*//'`
# zendextensionapi_version=%{zendextensionapi_version}
%define phpapi_version %`grep '\#define PHP_API_VERSION ' /usr/include/php5/main/php.h | sed 's/\#define PHP_API_VERSION //'`
# phpapi_version=%{phpapi_version}
%define phpcommon_version %`echo %{VERSION} | sed 's/-[^-]*$//'`
# phpcommon_version=%{phpcommon_version}
Source: php5-mysqli
Section: interpreters
Priority: extra
Maintainer: Piotr Roszatycki <dexter@debian.org>
Standards-Version: 3.6.2
Upstream-Source: <URL:http://www.php.net/downloads.php>
Home-Page: <URL:http://www.php.net/>
Description: MySQLi - new MySQL interface for PHP 5
Copyright: .
+----------------------------------------------------------------------+
| PHP Version 5 |
+----------------------------------------------------------------------+
| Copyright (c) 1997-2004 The PHP Group |
+----------------------------------------------------------------------+
| This source file is subject to version 3.0 of the PHP license, |
| that is bundled with this package in the file LICENSE, and is |
| available through the world-wide-web at the following url: |
| http://www.php.net/license/3_0.txt. |
| If you did not receive a copy of the PHP license and are unable to |
| obtain it through the world-wide-web, please send a note to |
| license@php.net so we can mail you a copy immediately. |
+----------------------------------------------------------------------+
| Author: Georg Richter <georg@php.net> |
+----------------------------------------------------------------------+
Build-Depends: php5-dev
Build-Depends: libmysqlclient14-dev
Build: sh
CFLAGS="-Wall -g -fsigned-char"
if [ "${DEB_BUILD_OPTIONS#*noopt}" != "$DEB_BUILD_OPTIONS" ]; then
CFLAGS="$CFLAGS -O0"
else
CFLAGS="$CFLAGS -O2"
fi
.
cd ext/*
phpize
CFLAGS="$CFLAGS" \
./configure --with-mysqli=/usr/bin/mysql_config --enable-embedded-mysqli=no \
--enable-debug --with-layout=GNU --disable-rpath --disable-static
make
Clean: sh
cd ext/*
make distclean || true
%define package mysqli
%define extname MySQLi
# some of modules are available only for specific SAPI
%define sapilist_default apache apache2 cgi cli fcgi
%define sapilist %{sapilist_%{?sapilist_%{package}:%{package}}%{!?sapilist_%{package}:default}}
# some of packages have different dsoname name
%define dsoname_default %{package}
%define dsoname %{dsoname_%{?dsoname_%{package}:%{package}}%{!?dsoname_%{package}:default}}
# some of packages depends on other modules
%define depends_default
%define depends %{depends_%{?depends_%{package}:%{package}}%{!?depends_%{package}:default}}
# the priority for package
%define priority_default 500
%define priority %{priority_%{?priority_%{package}:%{package}}%{!?priority_%{package}:default}}
# Macros:
# package=%{package}
# extname=%{extname}
# dsoname=%{dsoname}
# sapilist=%{sapilist}
# depends=%{depends}
# priority=%{priority}
Package: php5-%{package}
Architecture: any
# Depends: php5-common (= %{phpcommon_version}),
Depends: zendmoduleapi-%{zendmoduleapi_version}
Depends: %`for i in %{depends}; do printf 'php5-%s, ' $i; done`
Depends: []
Description: %{extname} module for php5
This package provides a new interface module for MySQL database connections
directly from PHP scripts.
.
The package is linked against newer libmysqlclient14 which conflicts with
libmysqlclient12, so mysql and mysqli modules can't be used together in the
same environment.
Install: bash
sapilist=""
for SAPI in %{sapilist}; do
sapilist="$sapilist $SAPI"
done
sapilist=$(eval echo $sapilist)
pushd ext/*
make install INSTALL_ROOT="$ROOT"
popd
cat << END > $ROOT/usr/lib/php5/%{zendmoduleapi_version}/%{dsoname}.info
package="%{package}"
extname="%{extname}"
dsoname="%{dsoname}"
sapilist="$sapilist"
depends="%{depends}"
priority="%{priority}"
END
for f in ext/%{dsoname}/package.xml ext/%{dsoname}/[ABCDEFGHIJKLMNOPQRSTUVWXYZ]*; do
if [ -s "$f" ]; then
yada install -doc "$f"
fi
done
Finalize: sh
chmod -x $ROOT/usr/lib/php5/*/*.so
Postinst: sh
if [ "$1" = "configure" ] && [ -z "$2" ]; then
for SAPI in %{sapilist}; do
if [ -f /etc/php5/$SAPI/php.ini ]; then
php5-modconf $SAPI enable %{dsoname}
fi
done
fi
Prerm: sh
if [ "$1" = "remove" ]; then
for SAPI in %{sapilist}; do
if [ -f /etc/php5/$SAPI/php.ini ]; then
php5-modconf $SAPI disable %{dsoname} quiet
fi
done
fi
Overrides:
description-synopsis-starts-with-a-capital-letter
|