Makefile revision 3996
ac4e70ff8955669341f435bc0a734a17c01af124Mark Andrews#
885f47576842cf3c569315b9a48bd9f0ca03f203Automatic Updater# CDDL HEADER START
71bd43eebd9d6e42dbcae62b730f5b6508d5acd8Automatic Updater#
59dd3b3cd954239d98ef52cd26328856cb6f2975Automatic Updater# The contents of this file are subject to the terms of the
59dd3b3cd954239d98ef52cd26328856cb6f2975Automatic Updater# Common Development and Distribution License (the "License").
7af91d15b2ce1ce32f7320f6d5cc3b83621c241aAutomatic Updater# You may not use this file except in compliance with the License.
7b67cfadd077feb0ec3e6c78385ba0d845a9789bMark Andrews#
59dd3b3cd954239d98ef52cd26328856cb6f2975Automatic Updater# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
a3b428812703d22a605a9f882e71ed65f0ffdc65Mark Andrews# or http://www.opensolaris.org/os/licensing.
bb93c8542756719b53096b9939e4041d0966026fAutomatic Updater# See the License for the specific language governing permissions
90ff38a0d8deaf5f9c2aa5916d99b2e572d28738Automatic Updater# and limitations under the License.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington#
ac4e70ff8955669341f435bc0a734a17c01af124Mark Andrews# When distributing Covered Code, include this CDDL HEADER in each
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington# If applicable, add the following below this CDDL HEADER, with the
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater# fields enclosed by brackets "[]" replaced with your own identifying
bc0a53583d92309bebcf93c408e2f3247ebd3d3cAutomatic Updater# information: Portions Copyright [yyyy] [name of copyright owner]
56874aef380a64a2c183b7c282c3e7a361d67fa1Automatic Updater#
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews# CDDL HEADER END
56874aef380a64a2c183b7c282c3e7a361d67fa1Automatic Updater#
4b2cb1422c7c600fbc13b1cb06a8b4693bc11af8Mark Andrews# Copyright (c) 2012, 2015, Oracle and/or its affiliates. All rights reserved.
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews#
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrewsinclude ../../../make-rules/shared-macros.mk
7eda3642eea03f1181e41540c7c8791a57759383Automatic Updater
4b2cb1422c7c600fbc13b1cb06a8b4693bc11af8Mark Andrews# NOTE:
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews# Currently the version numbers in the package manifests, one
efb0e886f18894a1d2489f1ad74ad14b579e11c7Mark Andrews# level up, are manually set because the COMPONENT_VERSION, like
efb0e886f18894a1d2489f1ad74ad14b579e11c7Mark Andrews# below, is not available at the top level where this is IPS
aa1d397c4736cd86540555193d71e55fa3b37b2aMark Andrews# published from.
91216cff91b34c9ff6e846dc23f248219cafe660Andreas Gustafsson
aa1d397c4736cd86540555193d71e55fa3b37b2aMark AndrewsCOMPONENT_NAME= php
aa1d397c4736cd86540555193d71e55fa3b37b2aMark AndrewsCOMPONENT_VERSION= 5.3.29
91216cff91b34c9ff6e846dc23f248219cafe660Andreas GustafssonCOMPONENT_SRC= $(COMPONENT_NAME)-$(COMPONENT_VERSION)
aa1d397c4736cd86540555193d71e55fa3b37b2aMark AndrewsCOMPONENT_ARCHIVE= $(COMPONENT_SRC).tar.bz2
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian WellingtonCOMPONENT_ARCHIVE_HASH= \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater sha256:c4e1cf6972b2a9c7f2777a18497d83bf713cdbecabb65d3ff62ba441aebb0091
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark AndrewsCOMPONENT_ARCHIVE_URL= http://us.php.net/get/$(COMPONENT_ARCHIVE)/from/this/mirror
fc3576328379e813ccf6b3a6e66d9bb701a79c83Automatic UpdaterCOMPONENT_PROJECT_URL= http://www.php.net/
298c514fff250c1a147176cfbbc1c0ca441d1ea5Automatic Updater
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews#
bbb069be941f649228760edcc241122933c066d2Automatic Updater# php documentation
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark AndrewsCOMPONENT_NAME_1= php_manual_en
3098364bcdd7a719fbafa5fc8d2cc9e90e5a5989Automatic UpdaterCOMPONENT_VERSION_1= 20120717
9d330c054e02f52cefd8dc0e71550b0fe07e077eAutomatic UpdaterCOMPONENT_SRC_1= $(COMPONENT_NAME_1)_$(COMPONENT_VERSION_1)
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark AndrewsCOMPONENT_ARCHIVE_1= $(COMPONENT_SRC_1).tar.gz
ca904804e43f663f08eb1ac9d6d617930b9a3cd3Automatic UpdaterCOMPONENT_ARCHIVE_HASH_1= \
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews sha256:4c5d45e5f49bb164d40154fdef57b3193e7b77e306055559e60615c8ca9a3c30
c0b771f68361b073388b85a689c12cbe502880eeAutomatic Updater#
4b2cb1422c7c600fbc13b1cb06a8b4693bc11af8Mark Andrews# This next download URL is completely hocus pocus.
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews# php.net does not freeze their documentation to match the software versions.
aa1d397c4736cd86540555193d71e55fa3b37b2aMark Andrews# So we need to take a snapshot of PHP's documentation by downloading what
91216cff91b34c9ff6e846dc23f248219cafe660Andreas Gustafsson# they currently have from this URL:
aa1d397c4736cd86540555193d71e55fa3b37b2aMark Andrews# COMPONENT_ARCHIVE_URL_1=http://us.php.net/get/php_manual_en.tar.gz/from/this/mirror
efb0e886f18894a1d2489f1ad74ad14b579e11c7Mark Andrews# Then move that download to the name being constructed in the variables
efb0e886f18894a1d2489f1ad74ad14b579e11c7Mark Andrews# above. Finally, forward a copy to the gatekeeping staff to place
aa1d397c4736cd86540555193d71e55fa3b37b2aMark Andrews# the copy in userland's download cache so that the following download URL
91216cff91b34c9ff6e846dc23f248219cafe660Andreas Gustafsson# will pick it up.
aa1d397c4736cd86540555193d71e55fa3b37b2aMark AndrewsCOMPONENT_ARCHIVE_URL_1=http://us.php.net/get/$(COMPONENT_ARCHIVE_1)/from/this/mirror
aa1d397c4736cd86540555193d71e55fa3b37b2aMark Andrews
91216cff91b34c9ff6e846dc23f248219cafe660Andreas Gustafssoninclude ./php.mk
aa1d397c4736cd86540555193d71e55fa3b37b2aMark Andrews
d145b64cacc8d9cda51f9924ec70cd4661c3e2cfAutomatic Updater
bb93c8542756719b53096b9939e4041d0966026fAutomatic Updaterinclude $(WS_MAKE_RULES)/prep.mk
723bfc0fc28c486c805de016c4475a35328eb8abAutomatic Updaterinclude $(WS_MAKE_RULES)/configure.mk
723bfc0fc28c486c805de016c4475a35328eb8abAutomatic Updaterinclude $(WS_MAKE_RULES)/ips.mk
723bfc0fc28c486c805de016c4475a35328eb8abAutomatic Updater
723bfc0fc28c486c805de016c4475a35328eb8abAutomatic Updaterinclude ../common.mk
2a31bd531072824ef252c18303859d6af7451b00Francis Dupont
2a31bd531072824ef252c18303859d6af7451b00Francis DupontCONFIGURE_OPTIONS += \
2a31bd531072824ef252c18303859d6af7451b00Francis Dupont $(COMMON_CONFIG_OPTIONS) \
2a31bd531072824ef252c18303859d6af7451b00Francis Dupont --disable-cgi \
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews --disable-fastcgi \
7af91d15b2ce1ce32f7320f6d5cc3b83621c241aAutomatic Updater --enable-discard-path \
7af91d15b2ce1ce32f7320f6d5cc3b83621c241aAutomatic Updater --enable-ftp=shared \
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews --enable-pdo=shared \
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews --with-apxs2=$(APACHE_USR_PREFIX)/bin/apxs \
885f47576842cf3c569315b9a48bd9f0ca03f203Automatic Updater --with-bz2=shared \
7af91d15b2ce1ce32f7320f6d5cc3b83621c241aAutomatic Updater --with-config-file-path=$(CONF_DIR) \
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews --with-config-file-scan-dir=$(MODULES_CONF_DIR) \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater --with-curl=shared \
7af91d15b2ce1ce32f7320f6d5cc3b83621c241aAutomatic Updater --with-curlwrappers \
efb0e886f18894a1d2489f1ad74ad14b579e11c7Mark Andrews --with-gd=shared \
efb0e886f18894a1d2489f1ad74ad14b579e11c7Mark Andrews --with-gettext=shared \
fe80a4909bf62b602feaf246866e9d29f7654194Automatic Updater --with-iconv=shared \
fe80a4909bf62b602feaf246866e9d29f7654194Automatic Updater --with-imap=shared,$(IMAP_DIR) \
fe80a4909bf62b602feaf246866e9d29f7654194Automatic Updater --with-imap-ssl=shared,/usr \
fe80a4909bf62b602feaf246866e9d29f7654194Automatic Updater --with-ldap=shared \
fe80a4909bf62b602feaf246866e9d29f7654194Automatic Updater --with-mysql=shared,mysqlnd \
fe80a4909bf62b602feaf246866e9d29f7654194Automatic Updater --with-mysql-sock=/tmp/mysql.sock \
aa1d397c4736cd86540555193d71e55fa3b37b2aMark Andrews --with-mysqli=shared,mysqlnd \
91216cff91b34c9ff6e846dc23f248219cafe660Andreas Gustafsson --with-openssl=shared \
aa1d397c4736cd86540555193d71e55fa3b37b2aMark Andrews --with-pear=$(PEAR_DIR) \
aa1d397c4736cd86540555193d71e55fa3b37b2aMark Andrews --with-pdo-mysql=shared,mysqlnd \
91216cff91b34c9ff6e846dc23f248219cafe660Andreas Gustafsson --with-pdo-sqlite=shared \
aa1d397c4736cd86540555193d71e55fa3b37b2aMark Andrews --with-snmp=shared,/usr \
91216cff91b34c9ff6e846dc23f248219cafe660Andreas Gustafsson --with-sqlite=shared \
aa1d397c4736cd86540555193d71e55fa3b37b2aMark Andrews --with-tidy=shared,/usr \
d145b64cacc8d9cda51f9924ec70cd4661c3e2cfAutomatic Updater --without-tsrm-pthreads
19b3dc94bce93fa76bd7e066f9298630dbc9dcb4Automatic Updater
bb93c8542756719b53096b9939e4041d0966026fAutomatic UpdaterCONFIGURE_ENV += $(CONF_ENVLINE)
bb93c8542756719b53096b9939e4041d0966026fAutomatic Updater
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic UpdaterCOMPONENT_POST_BUILD_ACTION = ( \
5ae0e2c8b72fa44237edeb37d1945b1c3535ca39Automatic Updater set -e; \
4cda4fd158d6ded5586bacea8c388445d99611eaAutomatic Updater cat $(BUILD_DIR_32)/scripts/phpize | \
3098364bcdd7a719fbafa5fc8d2cc9e90e5a5989Automatic Updater sed -e "s,^\#!/bin/sh,\#!$(CONFIG_SHELL)," | \
19b3dc94bce93fa76bd7e066f9298630dbc9dcb4Automatic Updater sed -e "s%^prefix=.*%prefix=$(BUILD_DIR_32)%" | \
d145b64cacc8d9cda51f9924ec70cd4661c3e2cfAutomatic Updater sed -e "s%^includedir=.*%includedir=$(BUILD_DIR_32)%" | \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater sed -e "s%^phpdir=.*%phpdir=$(BUILD_DIR_32)%" | \
5ae0e2c8b72fa44237edeb37d1945b1c3535ca39Automatic Updater sed -e "s%phpdir/phpize.m4%phpdir/scripts/phpize.m4%" | \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater sed -e "s%$PHP_AUTOCONF || exit 1%$PHP_AUTOCONF -f || exit 1%" | \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater sed -e "s%$PHP_AUTOHEADER || exit 1%$PHP_AUTOHEADER -f || exit 1%" | \
5ae0e2c8b72fa44237edeb37d1945b1c3535ca39Automatic Updater sed -e 's%(cd "$$phpdir" && cp $$FILES_BUILD "$$builddir"/build)%(cd "$$phpdir/build" \&\& cp $$FILES_BUILD "$$builddir"/build)%' | \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater sed -e "s%^builddir=.*%builddir=$(BUILD_DIR_32)%" \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater > phpize-proto ; \
bc0a53583d92309bebcf93c408e2f3247ebd3d3cAutomatic Updater chmod 755 phpize-proto ) ; \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater ( set -e; \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater cat $(BUILD_DIR_32)/scripts/php-config | \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater sed -e "s,^\#! /bin/sh,\#!$(CONFIG_SHELL)," | \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater sed -e "s%^prefix=.*%prefix=$(BUILD_DIR_32)%" | \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater sed -e "s%^include_dir=.*%include_dir=$(BUILD_DIR_32)%" \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater > php-config-proto ; \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater chmod 755 php-config-proto ) ; \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater ( set -e; \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater cat $(BUILD_DIR_32)/scripts/php-config | \
19b3dc94bce93fa76bd7e066f9298630dbc9dcb4Automatic Updater sed -e "s,^\#! /bin/sh,\#!$(CONFIG_SHELL)," | \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater sed -e "s%^prefix=.*%prefix=$(COMPONENT_DIR)/../php-nsapi/$(COMPONENT_SRC)%" | \
19b3dc94bce93fa76bd7e066f9298630dbc9dcb4Automatic Updater sed -e "s%^include_dir=.*%include_dir=$(COMPONENT_DIR)/../php-nsapi/$(COMPONENT_SRC)%" | \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater sed -e "s%^extension_dir=.*%extension_dir=$(ZTS_MODULES_DIR)%" \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater > php-config-proto.zts ; \
19b3dc94bce93fa76bd7e066f9298630dbc9dcb4Automatic Updater chmod 755 php-config-proto.zts )
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic UpdaterADD_APACHE2_MODULE_SUPPORT = ( \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater set -e; \
b0d566a2ce0f5a67f537ee7f8233f82f2584cc61Automatic Updater $(MKDIR) $(PROTO_DIR)/$(APACHE2_PHP); \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater $(INSTALL) -m 0644 $(COMPONENT_DIR)/../Solaris/php$(PHP_REL).conf \
71bd43eebd9d6e42dbcae62b730f5b6508d5acd8Automatic Updater $(PROTO_DIR)/$(APACHE2_PHP)/php$(PHP_REL).conf; \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater $(GSED) -i -e "s@<<VERSION>>@$(PHP_REL)@g" \
7262eb86f2b465822206122921e2f357218f0cfdAutomatic Updater $(PROTO_DIR)/$(APACHE2_PHP)/php$(PHP_REL).conf; \
96ea71632887c58a9d00f47eb318bf76b35903c3Mark Andrews $(SYMLINK) php$(PHP_REL).conf \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater $(PROTO_DIR)/$(APACHE2_PHP)/php.conf; \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater $(CP) $(PROTO_DIR)/$(APACHE2_EXTDIR)/libphp5.so \
bbb069be941f649228760edcc241122933c066d2Automatic Updater $(PROTO_DIR)/$(APACHE2_EXTDIR)/mod_php$(PHP_REL).so; \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater )
4cda4fd158d6ded5586bacea8c388445d99611eaAutomatic Updater
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews# Ship a default php.ini to simplify ease of use.
b0d566a2ce0f5a67f537ee7f8233f82f2584cc61Automatic Updater# Replace the php.ini-production symlink with a copy of the real file because
7af91d15b2ce1ce32f7320f6d5cc3b83621c241aAutomatic Updater# gpatch no longer follows symlinks.
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark AndrewsFIX_CONFIG_FILES = ( \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater set -e; \
5ae0e2c8b72fa44237edeb37d1945b1c3535ca39Automatic Updater cd $(BUILD_DIR_32); \
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews $(RM) php.ini-production; \
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews $(CP) $(SOURCE_DIR)/php.ini-production .; \
5ae0e2c8b72fa44237edeb37d1945b1c3535ca39Automatic Updater $(GPATCH) -p0 -o php.ini-patched -i ../../patches-other/php_ini.patch; \
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews $(GSED) -e "s@<<VERSION>>@$(PHP_REL)@g" < php.ini-patched > php.ini; \
c5a53da13bb2126dcbbd5b45ca4904eccafe6621Automatic Updater $(INSTALL) -m 644 php.ini $(PROTO_DIR)/$(CONF_DIR)/php.ini; \
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews )
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater
bc0a53583d92309bebcf93c408e2f3247ebd3d3cAutomatic UpdaterINSTALL_DOCS = ( \
5c0fc20d6e59216d9a142409e5fdb498153aeaa5Automatic Updater set -e; \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater $(MKDIR) $(PROTO_DIR)/$(DOCDIR); \
19b3dc94bce93fa76bd7e066f9298630dbc9dcb4Automatic Updater $(UNPACK) -r $(PROTO_DIR)/$(DOCDIR) $(COMPONENT_ARCHIVE_1); \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater )
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian WellingtonINSTALL_SAMPLES = ( \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater set -e; \
7eda3642eea03f1181e41540c7c8791a57759383Automatic Updater $(MKDIR) $(PROTO_DIR)/$(SCRIPTS_DIR); \
5c0fc20d6e59216d9a142409e5fdb498153aeaa5Automatic Updater $(MKDIR) $(COMPONENT_DIR)/tmp; \
5ae0e2c8b72fa44237edeb37d1945b1c3535ca39Automatic Updater cd $(COMPONENT_DIR); \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater $(GSED) -e "s,\<\<INSTALL_DIR\>\>,$(PHP_ROOT)," \
7eda3642eea03f1181e41540c7c8791a57759383Automatic Updater -e "s,\<\<CONF_DIR\>\>,$(CONFDIR)," \
00be0f9f61d4c6bf197d000bfa1a6b7e70ea0866Automatic Updater -e "s,\<\<NSAPI_CONF_DIR\>\>,$(NSAPI_CONFDIR)," \
91216cff91b34c9ff6e846dc23f248219cafe660Andreas Gustafsson -e "s,\<\<MODULES_CONF_DIR\>\>,$(MODULES_CONFDIR)," \
00be0f9f61d4c6bf197d000bfa1a6b7e70ea0866Automatic Updater -e "s,\<\<ZTS_MODULES_CONF_DIR\>\>,$(ZTS_MODULES_CONFDIR)," \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater < $(COMPONENT_DIR)/../Solaris/configure-sun-webserver \
5c0fc20d6e59216d9a142409e5fdb498153aeaa5Automatic Updater > tmp/tmp; \
71bd43eebd9d6e42dbcae62b730f5b6508d5acd8Automatic Updater $(INSTALL) -m 555 tmp/tmp \
5ae0e2c8b72fa44237edeb37d1945b1c3535ca39Automatic Updater $(PROTO_DIR)/$(SCRIPTS_DIR)/configure-sun-webserver; \
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington cd $(PROTO_DIR)/$(PHP_BIN); \
f0ecd0e64ffa2a8afef95d81275d46a845f15402Automatic Updater $(RM) configure-webserver7; \
3857cb6fcabeb79d85de4b3e3e4ab99912b701f8Mark Andrews $(SYMLINK) ../samples/scripts/configure-sun-webserver \
81c3cb9b921cda22a5a35fa32ca1bf35797b9a36Automatic Updater configure-webserver7; \
4f5257ba7afbe06e949d1577581de18b22ef6c05Automatic Updater )
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews
aa1d397c4736cd86540555193d71e55fa3b37b2aMark Andrews# patch installation to support pear installation.
91216cff91b34c9ff6e846dc23f248219cafe660Andreas GustafssonPATCH_PEAR = ( \
aa1d397c4736cd86540555193d71e55fa3b37b2aMark Andrews set -e; \
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington cd $(PROTO_DIR)/$(PHP_BIN); \
8ae412a86ed138263796195eed82a4716e7effcbMark Andrews $(GPATCH) -N -i $(COMPONENT_DIR)/patches-other/pear_pecl.patch; \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater $(GPATCH) -N -i $(COMPONENT_DIR)/patches-other/pear_php_config.patch; \
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews cd $(PROTO_DIR)/$(PHP_LIB)/build; \
3c5dffc581c882235485cf5eaf7cd6a5e07548bfAutomatic Updater $(GPATCH) -N -i $(COMPONENT_DIR)/patches-other/pear_Makefile_global.patch; \
4b2cb1422c7c600fbc13b1cb06a8b4693bc11af8Mark Andrews cd $(PROTO_DIR)/$(PEAR_DIR); \
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews $(GPATCH) -N -p0 -i $(COMPONENT_DIR)/patches-other/pear_Builder_php.patch; \
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews $(CP) $(COMPONENT_DIR)/config/pear/*.reg \
b0d566a2ce0f5a67f537ee7f8233f82f2584cc61Automatic Updater $(PROTO_DIR)/$(PEAR_DIR)/.channels/; \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater )
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews
4b2cb1422c7c600fbc13b1cb06a8b4693bc11af8Mark Andrews# Create symbolic links
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews# Not strictly necessary but makes the proto area more correct.
4b2cb1422c7c600fbc13b1cb06a8b4693bc11af8Mark AndrewsCREATE_SYMLINKS = ( \
c651f15b30f1dae5cc2f00878fb5da5b3a35a468Mark Andrews set -e; \
e076d0c88be69de7c190ab924d095e69d2e11f7aAndreas Gustafsson cd $(PROTO_DIR)/usr/php; \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater $(RM) bin lib include modules doc man; \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater $(SYMLINK) $(PHP_REL)/bin . ; \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater $(SYMLINK) $(PHP_REL)/lib . ; \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater $(SYMLINK) $(PHP_REL)/include . ; \
aa1d397c4736cd86540555193d71e55fa3b37b2aMark Andrews $(SYMLINK) $(PHP_REL)/modules . ; \
91216cff91b34c9ff6e846dc23f248219cafe660Andreas Gustafsson $(SYMLINK) $(PHP_REL)/doc . ; \
aa1d397c4736cd86540555193d71e55fa3b37b2aMark Andrews $(SYMLINK) $(PHP_REL)/man . ; \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater $(MKDIR) $(PROTO_DIR)/usr/bin; \
aa1d397c4736cd86540555193d71e55fa3b37b2aMark Andrews cd $(PROTO_DIR)/usr/bin; \
91216cff91b34c9ff6e846dc23f248219cafe660Andreas Gustafsson $(RM) php php-config phpize; \
aa1d397c4736cd86540555193d71e55fa3b37b2aMark Andrews $(SYMLINK) ../php/$(PHP_REL)/bin/php . ; \
efb0e886f18894a1d2489f1ad74ad14b579e11c7Mark Andrews $(SYMLINK) ../php/$(PHP_REL)/bin/php-config . ; \
efb0e886f18894a1d2489f1ad74ad14b579e11c7Mark Andrews $(SYMLINK) ../php/$(PHP_REL)/bin/phpize . ; \
ac4e70ff8955669341f435bc0a734a17c01af124Mark Andrews $(SYMLINK) ../php/$(PHP_REL)/bin/phar . ; \
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington )
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington
7af91d15b2ce1ce32f7320f6d5cc3b83621c241aAutomatic UpdaterCOMPONENT_POST_INSTALL_ACTION = ( \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater set -e; \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater $(ADD_APACHE2_MODULE_SUPPORT); \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater $(FIX_CONFIG_FILES); \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater $(FIX_CONFIG_FILES_2); \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater $(INSTALL_DOCS); \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater $(INSTALL_SAMPLES); \
bc0a4c01beede169df81a3ee5b614ed9e82339dbAutomatic Updater $(PATCH_PEAR); \
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington $(CREATE_SYMLINKS); \
ce9cad6bb04869c5e94d9dc721032b25117f9210Automatic Updater )
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington# This package contains all 3 versions of php:
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington# sapi, cgi, nsapi
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian WellingtonPKG_PROTO_DIRS += $(COMPONENT_DIR)/../php-nsapi/build/prototype/$(MACH)
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian WellingtonPKG_PROTO_DIRS += $(COMPONENT_DIR)/../php-cgi/build/prototype/$(MACH)
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian WellingtonCLEAN_PATHS += phpize-proto php-config-proto php-config-proto.zts tmp
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian WellingtonCLEAN_PATHS += php.ini-patched
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington# common targets
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtonconfigure: $(CONFIGURE_32)
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtonbuild: $(BUILD_32)
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtoninstall: $(INSTALL_32) PHP-NSAPI_INSTALL PHP-CGI_INSTALL
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington# Besides running this test target it is also strong advised to download
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington# and test with:
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington# Joomla! http://www.joomla.org/
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington# WordPress http://wordpress.org/
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellingtontest: $(TEST_32)
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington../imap/build/$(MACH32)/.built:
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington (cd ../imap ; $(MAKE) build)
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington../php-nsapi/build/$(MACH32)/.installed:
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington (cd ../php-nsapi ; $(MAKE) install)
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington../php-cgi/build/$(MACH32)/.installed:
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington (cd ../php-cgi ; $(MAKE) install)
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington$(BUILD_DIR_32)/.configured: ../imap/build/$(MACH32)/.built
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian WellingtonPHP-NSAPI_INSTALL: ../php-nsapi/build/$(MACH32)/.installed
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian WellingtonPHP-CGI_INSTALL: ../php-cgi/build/$(MACH32)/.installed
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington
9e3a7b0faf417a10f5f689edf288807b2d5eedc5Brian Wellington