|
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 |
|
22 # |
|
23 # Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. |
|
24 # |
|
25 |
|
26 # Build intl extension separately to use Studio for proper linkage with ICU |
|
27 |
|
28 include ../../../../make-rules/shared-macros.mk |
|
29 include $(WS_COMPONENTS)/php/php-metadata.mk |
|
30 |
|
31 include $(WS_MAKE_RULES)/prep.mk |
|
32 include $(WS_MAKE_RULES)/configure.mk |
|
33 |
|
34 # CLEAN_PATHS by default only gets SOURCE_DIR, which we don't want to delete. |
|
35 # (removing BUILD_DIR is a separate rule in configure.mk) |
|
36 CLEAN_PATHS= |
|
37 |
|
38 # putting this line here - with no way to compute SOURCE_DIR in prep.mk - |
|
39 # means .prep goes in php56/intl. |
|
40 SOURCE_DIR = $(PHP_SOURCE_DIR)/ext/intl |
|
41 CLEAN_PATHS += .prep |
|
42 |
|
43 # phpize.mk will cloney SOURCE_DIR into BUILD_DIR_64 |
|
44 include $(PHP_TOP_DIR)/phpize.mk |
|
45 |
|
46 CONFIGURE_OPTIONS += --enable-intl=shared |
|
47 |
|
48 # The build tools (libtool?) insist on passing "-lCrun -lCstd" flags. These are |
|
49 # legacy Solaris Studio C++ runtime and standard libraries, which is wrong. |
|
50 # The only expedient method I found of removing these flags is to edit the |
|
51 # generated Makefile after configure runs. |
|
52 COMPONENT_POST_CONFIGURE_ACTION += \ |
|
53 $(GSED) -i -e 's/-lCrun//g' -e 's/-lCstd//g' $(BUILD_DIR_64)/Makefile |
|
54 |
|
55 CONFIGURE_ENV += CXXFLAGS="$(CXXFLAGS)" |
|
56 |
|
57 COMPONENT_TEST_TARGETS = test |
|
58 |
|
59 configure: $(CONFIGURE_64) |
|
60 build: $(BUILD_64) |
|
61 install: $(INSTALL_64) |
|
62 test: $(TEST_64) |
|
63 |
|
64 REQUIRED_PACKAGES += library/icu |
|
65 REQUIRED_PACKAGES += system/library/math |