904N/A#
904N/A# CDDL HEADER START
904N/A#
904N/A# The contents of this file are subject to the terms of the
904N/A# Common Development and Distribution License (the "License").
904N/A# You may not use this file except in compliance with the License.
904N/A#
904N/A# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
904N/A# or http://www.opensolaris.org/os/licensing.
904N/A# See the License for the specific language governing permissions
904N/A# and limitations under the License.
904N/A#
904N/A# When distributing Covered Code, include this CDDL HEADER in each
904N/A# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
904N/A# If applicable, add the following below this CDDL HEADER, with the
904N/A# fields enclosed by brackets "[]" replaced with your own identifying
904N/A# information: Portions Copyright [yyyy] [name of copyright owner]
904N/A#
904N/A# CDDL HEADER END
904N/A#
3777N/A# Copyright (c) 2012, 2015, Oracle and/or its affiliates. All rights reserved.
904N/A#
904N/A
904N/Ainclude ../../../make-rules/shared-macros.mk
904N/A
904N/ACOMPONENT_NAME= php
3777N/ACOMPONENT_VERSION= 5.3.29
904N/ACOMPONENT_SRC= $(COMPONENT_NAME)-$(COMPONENT_VERSION)
904N/ACOMPONENT_ARCHIVE= $(COMPONENT_SRC).tar.bz2
904N/ACOMPONENT_ARCHIVE_HASH= \
3777N/A sha256:c4e1cf6972b2a9c7f2777a18497d83bf713cdbecabb65d3ff62ba441aebb0091
904N/ACOMPONENT_ARCHIVE_URL= http://us.php.net/get/$(COMPONENT_ARCHIVE)/from/this/mirror
904N/ACOMPONENT_PROJECT_URL= http://www.php.net/
904N/A
904N/A#
904N/A# webserver7-spi only for php NSAPI
904N/A#
904N/ACOMPONENT_NAME_1= webserver7-spi
904N/A#COMPONENT_VERSION_1= NONE
904N/ACOMPONENT_SRC_1= $(COMPONENT_NAME_1)
904N/ACOMPONENT_ARCHIVE_1= $(COMPONENT_NAME_1).tar.bz2
904N/ACOMPONENT_ARCHIVE_HASH_1= \
904N/A sha256:9739fe99ed270955546313322775940c6b7e8eb802707d248342406ebe5b1c97
904N/A#
904N/A# The Netscape server?
904N/A# Came from Sun's Netscape (web stack) group originally?
904N/ACOMPONENT_ARCHIVE_URL_1= $(EXTERNAL_ARCHIVE_MIRROR)/$(COMPONENT_ARCHIVE_1)
904N/A
904N/APATCH_DIR = ../php-sapi/patches
904N/A
2429N/Ainclude ../php-sapi/php.mk
2429N/A
3996N/Ainclude $(WS_MAKE_RULES)/prep.mk
3996N/Ainclude $(WS_MAKE_RULES)/configure.mk
3996N/Ainclude $(WS_MAKE_RULES)/ips.mk
904N/A
904N/Ainclude ../common.mk
904N/A
904N/ACOMPONENT_POST_UNPACK_ACTION += && ( \
3469N/A set -e; \
904N/A $(RM) -r $(COMPONENT_DIR)/$(COMPONENT_SRC_1); \
904N/A cd $(COMPONENT_DIR); \
904N/A $(UNPACK) $(UNPACK_ARGS) ./$(COMPONENT_ARCHIVE_1); \
904N/A )
904N/A
904N/ACONFIGURE_OPTIONS += \
904N/A --disable-all \
904N/A $(COMMON_CONFIG_OPTIONS) \
904N/A --with-config-file-path=$(CONF_DIR) \
904N/A --with-config-file-scan-dir=$(CONF_DIR)/conf.d \
904N/A --disable-cgi \
904N/A --disable-fastcgi \
904N/A --enable-discard-path \
904N/A --enable-maintainer-zts \
904N/A --enable-ftp=shared \
904N/A --enable-pdo=shared \
904N/A --with-bz2=shared \
904N/A --with-curl=shared \
904N/A --with-gd=shared \
904N/A --with-gettext=shared \
904N/A --with-iconv=shared \
904N/A --with-imap=shared,$(IMAP_DIR) \
904N/A --with-imap-ssl=shared,/usr \
904N/A --with-ldap=shared \
2429N/A --with-mysql=shared,mysqlnd \
904N/A --with-mysql-sock=/tmp/mysql.sock \
2429N/A --with-mysqli=shared,mysqlnd \
904N/A --with-nsapi=$(COMPONENT_DIR)/webserver7-spi \
904N/A --with-openssl=shared \
904N/A --with-pear=$(PEAR_DIR) \
2429N/A --with-pdo-mysql=shared,mysqlnd \
904N/A --with-pdo-sqlite=shared \
904N/A --with-snmp=shared,/usr \
904N/A --with-sqlite3=shared \
904N/A --with-tidy=shared,/usr
904N/A
904N/ACONFIGURE_ENV += $(ZTS_CONF_ENVLINE)
904N/A
904N/ACOMPONENT_POST_BUILD_ACTION = ( \
3469N/A set -e; \
904N/A cat $(BUILD_DIR_32)/scripts/phpize | \
904N/A sed -e "s,^\#!/bin/sh,\#!$(CONFIG_SHELL)," | \
2429N/A sed -e "s%^prefix=.*%prefix=$(BUILD_DIR_32)%" | \
2429N/A sed -e "s%^includedir=.*%includedir=$(BUILD_DIR_32)%" | \
2429N/A sed -e "s%^phpdir=.*%phpdir=$(BUILD_DIR_32)%" | \
904N/A sed -e "s%phpdir/phpize.m4%phpdir/scripts/phpize.m4%" | \
904N/A sed -e 's%cd "$$phpdir" && cp $$FILES_BUILD "$$builddir"/build%cd "$$phpdir/build" \&\& cp $$FILES_BUILD "$$builddir"/build%' \
904N/A > phpize-proto.zts ; \
904N/A chmod 755 phpize-proto.zts )
904N/A
904N/AADD_NSAPI_MODULE_SUPPORT = ( \
3469N/A set -e; \
904N/A $(MKDIR) $(PROTO_DIR)/$(TOP_DIR)/nsapi/; \
904N/A $(CP) $(BUILD_DIR_32)/libs/libphp5.so \
904N/A $(PROTO_DIR)/$(TOP_DIR)/nsapi/libphp5.so; \
904N/A )
904N/A
904N/AFIX_CONFIG_FILES = ( \
3469N/A set -e; \
904N/A cd $(COMPONENT_DIR); \
904N/A $(GSED) -e "s@extension_dir = \(.*\)@extension_dir=$(PHP_ROOT_ZTS_EXT)@"< ../php-sapi/build/prototype/$(MACH)/$(CONFDIR)/php.ini > php.ini; \
904N/A $(MKDIR) $(PROTO_DIR)/$(NSAPI_CONFDIR); \
904N/A $(INSTALL) -m 644 php.ini $(PROTO_DIR)/$(NSAPI_CONFDIR); \
904N/A )
904N/A
904N/ACOMPONENT_INSTALL_TARGETS = libphp5.la install-modules
904N/A
904N/ACOMPONENT_POST_INSTALL_ACTION = ( \
3469N/A set -e; \
904N/A $(ADD_NSAPI_MODULE_SUPPORT); \
904N/A $(FIX_CONFIG_FILES); \
904N/A )
904N/A
904N/ACLEAN_PATHS += webserver7-spi phpize-proto.zts php.ini
904N/A
4171N/A# Test results not quite stable but good enough for human eyes
4171N/A$(SKIP_TEST_AT_TOP_LEVEL)
4171N/A
3777N/Aconfigure: $(CONFIGURE_32)
3777N/A
904N/Abuild: $(BUILD_32)
904N/A
904N/Ainstall: $(INSTALL_32)
904N/A
4171N/A# These test and compare results are not quite stable enough
4171N/A# to use in automated testing but good enough to eye
4171N/A# ball and get a sense that php is working correctly.
4171N/A# Individual tests can be run afterwards.
4171N/A# Several random tests may PASS/FAIL on each run thus invalidating
4171N/A# test and compare results.
4171N/A# To use the master test result file do:
4171N/A# $ gmake build
4171N/A# $ gmake -i -k test
4171N/A# because very likely the comparison phase will fail.
4171N/A
4171N/A# test failures; keep going
4171N/ACOMPONENT_TEST_ARGS += -k -i
4171N/A
4171N/A# different results for different architectures
4171N/ACOMPONENT_TEST_MASTER = $(COMPONENT_TEST_RESULTS_DIR)/results-$(MACH$(BITS)).master
4171N/A
904N/Atest: $(TEST_32)
904N/A
904N/A# php-sapi does the publish
904N/Apublish: install