1 # |
|
2 # CDDL HEADER START |
|
3 # |
|
4 # The contents of this file are subject to the terms of the |
|
5 # Common Development and Distribution License (the "License"). |
|
6 # You may not use this file except in compliance with the License. |
|
7 # |
|
8 # You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE |
|
9 # or http://www.opensolaris.org/os/licensing. |
|
10 # See the License for the specific language governing permissions |
|
11 # and limitations under the License. |
|
12 # |
|
13 # When distributing Covered Code, include this CDDL HEADER in each |
|
14 # file and include the License file at usr/src/OPENSOLARIS.LICENSE. |
|
15 # If applicable, add the following below this CDDL HEADER, with the |
|
16 # fields enclosed by brackets "[]" replaced with your own identifying |
|
17 # information: Portions Copyright [yyyy] [name of copyright owner] |
|
18 # |
|
19 # CDDL HEADER END |
|
20 # |
|
21 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. |
|
22 # |
|
23 include ../../make-rules/shared-macros.mk |
|
24 |
|
25 TPNO_PHP_5_2= 17129 |
|
26 TPNO_PHP_APC= 17127 |
|
27 TPNO_PHP_IDN= 17128 |
|
28 TPNO_PHP_MEMCACHE= 17130 |
|
29 TPNO_PHP_SUHOSIN= 17131 |
|
30 TPNO_PHP_TCPWRAP= 17132 |
|
31 TPNO_PHP_XDEBUG= 17133 |
|
32 |
|
33 include $(WS_MAKE_RULES)/ips.mk |
|
34 |
|
35 ## |
|
36 ## This Makefile for local usage only. |
|
37 ## The full build will NOT execute this Makefile. |
|
38 ## |
|
39 |
|
40 # PHP 5.2 |
|
41 # |
|
42 # Build ordering: |
|
43 # 1) imap -> install |
|
44 # 2) php-sapi -> install |
|
45 # 3) php-nsapi -> install |
|
46 # 3) php-cgi -> install |
|
47 # 4) php-sapi -> publish (packages sapi, nsapi, cgi in 1 package) |
|
48 # 5) APC-zts -> install |
|
49 # 6) APC -> publish (packages APC-zts, APC in 1 package) |
|
50 # 5) idn-zts -> install |
|
51 # 6) idn -> publish (packages idn-zts, idn in 1 package) |
|
52 # 5) memcache-zts -> install |
|
53 # 6) memcache -> publish (packages memcache-zts, memcache in 1 pack) |
|
54 # 5) suhosin-zts -> install |
|
55 # 6) suhosin -> publish (packages suhosin-zts, suhosin in 1 package) |
|
56 # 5) tcpwrap-zts -> install |
|
57 # 6) tcpwrap -> publish (packages tcpwrap-zts, tcpwrap in 1 package) |
|
58 # 5) xdebug-zts -> install |
|
59 # 6) xdebug -> publish (packages xdebug-zts, xdebug in 1 package) |
|
60 # |
|
61 # The numbers indicate parallelism possible in the build. |
|
62 # The other way to build this would be: |
|
63 # 1) imap -> build |
|
64 # 2) php-sapi -> install |
|
65 # 3) php-nsapi -> install |
|
66 # 4) all others -> install (in parallel) |
|
67 # 5) all -> publish (in parallel) |
|
68 # So after imap, php-sapi, php-nsapi build serially in that order |
|
69 # then it doesn't matter. |
|
70 |
|
71 # PHP is built 3 ways: |
|
72 # php-sapi - Server API |
|
73 # php-cgi - CGI |
|
74 # php-nsapi - Netscape Server API |
|
75 # This is the Netscape group (aka webstack group) |
|
76 # that Sun purchased from AOL long ago. |
|
77 # I believe this Netscape server is still alive |
|
78 # and offered by Oracle. |
|
79 # These PHP's are built from the same source, patched the same way, |
|
80 # but configured differently. |
|
81 |
|
82 # More relevant to the full USERLAND build is the dependency tree |
|
83 # for say starting the build down in an extension module: |
|
84 # To publish the APC extension: |
|
85 # 1) build imap |
|
86 # 2) install php-sapi |
|
87 # 3) install APC |
|
88 # 4) install php-nsapi |
|
89 # 5) install APC-zts |
|
90 # 6) publish APC |
|
91 |
|
92 # SFW build of php |
|
93 # 1) build_imap - Because php needs headers and libc-client.a |
|
94 # Must be built first. |
|
95 # 2) build_modphp5 - php SAPI |
|
96 # $(PHP_DIR)/libs/libphp5.so |
|
97 # $(PHP_DIR)/config.status |
|
98 # $(PHP_DIR)/configure |
|
99 # unroll php archive |
|
100 # patch |
|
101 # ./buildconf |
|
102 # edit configure |
|
103 # copy php source tree for php_fast/cgi build |
|
104 # unroll webserver7-spi |
|
105 # [Sun Java System Web Server 7 (formerly known |
|
106 # as Sun ONE/iPlanet Enterprise Server)] |
|
107 # [now Oracle iPlanet Web Server 7] |
|
108 # copy php source tree for php_nsapi build |
|
109 # $(PHP_NSAPI)/configure |
|
110 # [stuff...] |
|
111 # ./configure |
|
112 # 3) build_cgi - php cgi/fastcgi |
|
113 # 4) build_nsapi - php nsapi (netscape SAPI - old sun webserver product) |
|
114 # (still applicable) |
|
115 # I think so - http://blogs.oracle.com/natarajan/entry/php_plug_in_for_oracle |
|
116 # (now known as Oracle iPlanet Web Server 7) |
|
117 # |
|
118 # 5) install_php - this is called AFTER php builds and installs |
|
119 # cd $(PHP_DIR); make install |
|
120 # cd $(PHP_NSAPI); make libphp5.la install-modules |
|
121 # ./install-php5 |
|
122 # don't need fix_bin_scripts() |
|
123 # [paths already correct and some things don't exist.] |
|
124 # looks like i DO NEED the pear patches |
|
125 |
|
126 COMPONENT_NAME= php |
|
127 COMPONENT_VERSION= 5.2.17 |
|
128 COMPONENT_PROJECT_URL= http://www.php.net/ |
|
129 COMPONENT_BUGDB= utility/php |
|
130 |
|
131 PKG_PROTO_DIRS += APC/build/prototype/$(MACH) |
|
132 PKG_PROTO_DIRS += APC-zts/build/prototype/$(MACH) |
|
133 PKG_PROTO_DIRS += idn/build/prototype/$(MACH) |
|
134 PKG_PROTO_DIRS += idn-zts/build/prototype/$(MACH) |
|
135 PKG_PROTO_DIRS += memcache/build/prototype/$(MACH) |
|
136 PKG_PROTO_DIRS += memcache-zts/build/prototype/$(MACH) |
|
137 PKG_PROTO_DIRS += php-cgi/build/prototype/$(MACH) |
|
138 PKG_PROTO_DIRS += php-nsapi/build/prototype/$(MACH) |
|
139 PKG_PROTO_DIRS += php-sapi/build/prototype/$(MACH) |
|
140 PKG_PROTO_DIRS += suhosin/build/prototype/$(MACH) |
|
141 PKG_PROTO_DIRS += suhosin-zts/build/prototype/$(MACH) |
|
142 PKG_PROTO_DIRS += tcpwrap/build/prototype/$(MACH) |
|
143 PKG_PROTO_DIRS += tcpwrap-zts/build/prototype/$(MACH) |
|
144 PKG_PROTO_DIRS += xdebug/build/prototype/$(MACH) |
|
145 PKG_PROTO_DIRS += xdebug-zts/build/prototype/$(MACH) |
|
146 |
|
147 # Do not apply the standard license transforms for this component. The |
|
148 # license actions are already tagged with the attributes, in the various |
|
149 # .p5m files. |
|
150 LICENSE_TRANSFORMS = |
|
151 |
|
152 # for now, everything with a Makefile should be built |
|
153 SUBDIRS = $(shell echo */Makefile | sed -e 's;/Makefile;;g') |
|
154 |
|
155 .PHONY: $(SUBDIRS) |
|
156 |
|
157 download: TARGET = download |
|
158 prep: TARGET = prep |
|
159 install: TARGET = install |
|
160 clean: TARGET = clean |
|
161 clobber: TARGET = clobber |
|
162 test: TARGET = test |
|
163 publish: TARGET = publish |
|
164 |
|
165 build: install |
|
166 |
|
167 .DEFAULT: publish |
|
168 |
|
169 download:: $(SUBDIRS) |
|
170 prep install test publish: $(SUBDIRS) |
|
171 |
|
172 clean: $(SUBDIRS) |
|
173 $(RM) -r $(BUILD_DIR) |
|
174 |
|
175 clobber: $(SUBDIRS) clean |
|
176 |
|
177 $(SUBDIRS): FORCE |
|
178 @cd $@ && echo "$(TARGET) $@" && $(MAKE) $(TARGET) |
|
179 |
|
180 # declare module dependencies |
|
181 APC: php-sapi |
|
182 APC-zts: php-sapi php-nsapi |
|
183 idn: php-sapi |
|
184 idn-zts: php-sapi php-nsapi |
|
185 memcache: php-sapi |
|
186 memcache-zts: php-sapi php-nsapi |
|
187 php-cgi: php-sapi |
|
188 php-nsapi: php-sapi |
|
189 php-sapi: imap |
|
190 suhosin: php-sapi |
|
191 suhosin-zts: php-sapi php-nsapi |
|
192 tcpwrap: php-sapi |
|
193 tcpwrap-zts: php-sapi php-nsapi |
|
194 xdebug: php-sapi |
|
195 xdebug-zts: php-sapi php-nsapi |
|
196 |
|
197 FORCE: |
|
198 |
|
199 REQUIRED_PACKAGES += compress/bzip2 |
|
200 REQUIRED_PACKAGES += developer/lexer/flex |
|
201 REQUIRED_PACKAGES += developer/parser/bison |
|
202 REQUIRED_PACKAGES += database/mysql-55/library |
|
203 REQUIRED_PACKAGES += image/library/libjpeg |
|
204 REQUIRED_PACKAGES += image/library/libpng |
|
205 REQUIRED_PACKAGES += library/libidn |
|
206 REQUIRED_PACKAGES += library/libtool/libltdl |
|
207 REQUIRED_PACKAGES += library/libxml2 |
|
208 REQUIRED_PACKAGES += library/libxslt |
|
209 REQUIRED_PACKAGES += library/security/openssl |
|
210 REQUIRED_PACKAGES += library/zlib |
|
211 REQUIRED_PACKAGES += shell/bash |
|
212 REQUIRED_PACKAGES += shell/ksh93 |
|
213 REQUIRED_PACKAGES += system/library |
|
214 REQUIRED_PACKAGES += system/library/freetype-2 |
|
215 REQUIRED_PACKAGES += system/library/math |
|
216 REQUIRED_PACKAGES += system/library/security/libmcrypt |
|
217 REQUIRED_PACKAGES += system/linker |
|
218 REQUIRED_PACKAGES += system/management/snmp/net-snmp |
|
219 REQUIRED_PACKAGES += text/tidy |
|
220 REQUIRED_PACKAGES += web/curl |
|
221 REQUIRED_PACKAGES += x11/library/libx11 |
|
222 REQUIRED_PACKAGES += x11/library/libxpm |
|