1 |
olemarkus 11/05/01 20:15:53 |
2 |
|
3 |
Added: src_prepare-snapshots.eblit |
4 |
Log: |
5 |
Added SVN snapshot ebuild |
6 |
|
7 |
(Portage version: 2.1.9.46/cvs/Linux x86_64) |
8 |
|
9 |
Revision Changes Path |
10 |
1.1 dev-lang/php/files/eblits/src_prepare-snapshots.eblit |
11 |
|
12 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-lang/php/files/eblits/src_prepare-snapshots.eblit?rev=1.1&view=markup |
13 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-lang/php/files/eblits/src_prepare-snapshots.eblit?rev=1.1&content-type=text/plain |
14 |
|
15 |
Index: src_prepare-snapshots.eblit |
16 |
=================================================================== |
17 |
# Copyright 1999-2011 Gentoo Foundation |
18 |
# Distributed under the terms of the GNU General Public License v2 |
19 |
# $Header: /var/cvsroot/gentoo-x86/dev-lang/php/files/eblits/src_prepare-snapshots.eblit,v 1.1 2011/05/01 20:15:52 olemarkus Exp $ |
20 |
|
21 |
eblit-php-src_prepare() { |
22 |
# USE=sharedmem (session/mod_mm to be exact) tries to mmap() this path |
23 |
# ([empty session.save_path]/session_mm_[sapi][gid].sem) |
24 |
# there is no easy way to circumvent that, all php calls during |
25 |
# install use -n, so no php.ini file will be used. |
26 |
# As such, this is the easiest way to get around |
27 |
addpredict /session_mm_cli250.sem |
28 |
addpredict /session_mm_cli0.sem |
29 |
|
30 |
# kolab support (support for imap annotations) |
31 |
use kolab && epatch "${WORKDIR}/${PV}/opt/imap-kolab-annotations.patch" |
32 |
|
33 |
# Change PHP branding |
34 |
sed -re "s|^(PHP_EXTRA_VERSION=\").*(\")|\1${PHP_EXTRA_BRANDING}-pl${PR/r/}-gentoo\2|g" \ |
35 |
-i configure.in || die "Unable to change PHP branding" |
36 |
|
37 |
# Apply generic PHP patches |
38 |
EPATCH_SOURCE="${WORKDIR}/patches/generic" EPATCH_SUFFIX="patch" \ |
39 |
EPATCH_FORCE="yes" \ |
40 |
EPATCH_MULTI_MSG="Applying generic patches and fixes from upstream..." epatch |
41 |
|
42 |
# Patch PHP to show Gentoo as the server platform |
43 |
sed -e 's/PHP_UNAME=`uname -a | xargs`/PHP_UNAME=`uname -s -n -r -v | xargs`/g' \ |
44 |
-i configure.in || die "Failed to fix server platform name" |
45 |
|
46 |
# Prevent PHP from activating the Apache config, |
47 |
# as we will do that ourselves |
48 |
sed -i \ |
49 |
-e "s,-i -a -n php${PHP_MV},-i -n php${PHP_MV},g" \ |
50 |
-e "s,-i -A -n php${PHP_MV},-i -n php${PHP_MV},g" \ |
51 |
configure sapi/apache2filter/config.m4 sapi/apache2handler/config.m4 |
52 |
|
53 |
# Patch PHP to support heimdal instead of mit-krb5 |
54 |
if has_version "app-crypt/heimdal" ; then |
55 |
sed -e 's|gssapi_krb5|gssapi|g' -i acinclude.m4 \ |
56 |
|| die "Failed to fix heimdal libname" |
57 |
sed -e 's|PHP_ADD_LIBRARY(k5crypto, 1, $1)||g' -i acinclude.m4 \ |
58 |
|| die "Failed to fix heimdal crypt library reference" |
59 |
fi |
60 |
|
61 |
# Suhosin support |
62 |
if [[ -n $SUHOSIN_VERSION ]] ; then |
63 |
if use suhosin ; then |
64 |
epatch "${WORKDIR}/${SUHOSIN_PATCH}" |
65 |
fi |
66 |
else |
67 |
ewarn "Please note that this version of PHP does not yet come with a suhosin patch" |
68 |
fi |
69 |
|
70 |
#Add user patches #357637 |
71 |
epatch_user |
72 |
|
73 |
# rebuild the whole autotools stuff as we are heavily patching it |
74 |
# (suhosin, fastbuild, ...) |
75 |
|
76 |
# eaclocal doesn't accept --force, so we try to force re-generation |
77 |
# this way |
78 |
rm aclocal.m4 |
79 |
|
80 |
# work around divert() issues with newer autoconf, bug #281697 |
81 |
if has_version '>=sys-devel/autoconf-2.64' ; then |
82 |
sed -i -r \ |
83 |
-e 's:^((m4_)?divert)[(]([0-9]*)[)]:\1(600\3):' \ |
84 |
$(grep -l divert $(find . -name '*.m4') configure.in) || die |
85 |
fi |
86 |
eautoreconf --force -W no-cross |
87 |
} |