Print this page
OS-2559 illumos-extra should provide native node in proto.strap
Split |
Close |
Expand all |
Collapse all |
--- old/openssl1x/Makefile
+++ new/openssl1x/Makefile
1 1 #
2 2 # CDDL HEADER START
3 3 #
4 4 # The contents of this file are subject to the terms of the
5 5 # Common Development and Distribution License (the "License").
6 6 # You may not use this file except in compliance with the License.
7 7 #
8 8 # You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9 9 # or http://www.opensolaris.org/os/licensing.
10 10 # See the License for the specific language governing permissions
11 11 # and limitations under the License.
12 12 #
13 13 # When distributing Covered Code, include this CDDL HEADER in each
14 14 # file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15 15 # If applicable, add the following below this CDDL HEADER, with the
16 16 # fields enclosed by brackets "[]" replaced with your own identifying
17 17 # information: Portions Copyright [yyyy] [name of copyright owner]
18 18 #
19 19 # CDDL HEADER END
20 20 #
21 21 # Copyright (c) 2009, 2010, Oracle and/or its affiliates. All rights reserved.
22 22 # Copyright (c) 2012-2013, Joyent, Inc. All rights reserved.
23 23 #
24 24
25 25 VER = openssl-1.0.1d
26 26 LIBVER = 1.0.0
27 27
28 28 include ../Makefile.defs
29 29
30 30 SHELL = /bin/bash
31 31 BUILD64 = yes
32 32 UNPACK_SENTINEL = Configure
33 33 AUTOCONF_OUT = crypto/opensslconf.h
34 34
35 35 MT_CPPFLAGS = -D_REENTRANT
36 36 SHARED_CFLAGS = -fPIC -DPIC
37 37 SHARED_LDFLAGS = -fPIC -shared
38 38
39 39 PKCS11_SRCS = \
40 40 hw_pk11_err.c \
41 41 hw_pk11_err.h \
42 42 hw_pk11_pub.c \
43 43 hw_pk11_uri.c \
44 44 hw_pk11_uri.h \
45 45 hw_pk11.c \
46 46 hw_pk11.h
47 47
48 48 PKCS11_DST.32 = $(VER.32)/crypto/engine
49 49 PKCS11_DST.64 = $(VER.64)/crypto/engine
50 50
51 51 PKCS11.32 = $(PKCS11_SRCS:%=$(PKCS11_DST.32)/%)
52 52 PKCS11.64 = $(PKCS11_SRCS:%=$(PKCS11_DST.64)/%)
53 53
54 54 CHECK_LIBS = \
55 55 $(VER.32)/libsunw_crypto.so.$(LIBVER) \
56 56 $(VER.32)/libsunw_ssl.so.$(LIBVER) \
57 57 $(VER.64)/libsunw_crypto.so.$(LIBVER) \
58 58 $(VER.64)/libsunw_ssl.so.$(LIBVER)
59 59
60 60 #
61 61 # There are races between the building of assembly language sources and
62 62 # the assembly of those files. Disable parallel build.
63 63 #
64 64 PARALLEL =
65 65
66 66 CPPFLAGS += \
67 67 -DSOLARIS_OPENSSL \
68 68 -DNO_WINDOWS_BRAINDEATH \
69 69 -include openssl/sunw_prefix.h
70 70
71 71 CFLAGS += \
72 72 -O3 \
73 73 -march=pentium \
74 74 -Wall \
75 75 -Werror \
↓ open down ↓ |
75 lines elided |
↑ open up ↑ |
76 76 -DPK11_LIB_LOCATION=\\"/usr/lib/libpkcs11.so.1\\"
77 77
78 78 CFLAGS.64 += \
79 79 -O3 \
80 80 -Wall \
81 81 -Werror \
82 82 -DPK11_LIB_LOCATION=\\"/usr/lib/64/libpkcs11.so.1\\"
83 83
84 84 LIBS += -lsocket -lnsl
85 85
86 +ifeq ($(STRAP),strap)
87 + LDFLAGS += $(SYSLIBDIRS:%=-R$(DESTDIR)/%)
88 + LDFLAGS.64 += $(SYSLIBDIRS:%=-R$(DESTDIR)/%/64)
89 +endif
90 +
86 91 PATCHES = Patches/*
87 92
88 93 AUTOCONF_ENV =
89 94 AUTOCONF_OPTS += \
90 95 --openssldir=/etc/openssl \
91 96 --install_prefix=$(DESTDIR) \
92 97 no-ec \
93 98 no-ecdh \
94 99 no-ecdsa \
95 100 no-rc3 \
96 101 no-rc5 \
97 102 no-mdc2 \
98 103 no-idea \
99 104 no-hw_4758_cca \
100 105 no-hw_aep \
101 106 no-hw_atalla \
102 107 no-hw_chil \
103 108 no-hw_gmp \
104 109 no-hw_ncipher \
105 110 no-hw_nuron \
106 111 no-hw_padlock \
107 112 no-hw_sureware \
108 113 no-hw_ubsec \
109 114 no-hw_cswift \
110 115 enable-md2 \
111 116 threads \
112 117 shared
113 118
114 119 AUTOCONF_OPTS.32 += \
115 120 smartos-x86-gcc
116 121
117 122 AUTOCONF_OPTS.64 += \
118 123 smartos64-x86_64-gcc
119 124
120 125 $(PKCS11_DST.32)/%: engine_pkcs11/%
121 126 cp $< $@
122 127
123 128 $(PKCS11_DST.64)/%: engine_pkcs11/%
124 129 cp $< $@
125 130
126 131 $(VER.32)/%: %
127 132 cp $< $@
128 133
129 134 $(VER.64)/%: %
130 135 cp $< $@
131 136
132 137 $(VER.32)/configure: $(VER.32)/Configure Makefile $(PKCS11.32) \
133 138 $(VER.32)/sunw_prefix.h
134 139 sed -e 's#@@CC@@#$(GCC)#g' \
135 140 -e 's#@@CPPFLAGS@@#$(CPPFLAGS)#g' \
136 141 -e 's#@@CFLAGS@@#$(CFLAGS)#g' \
137 142 -e 's#@@MT_CPPFLAGS@@#$(MT_CPPFLAGS)#g' \
138 143 -e 's#@@LDFLAGS@@#$(LDFLAGS)#g' \
139 144 -e 's#@@LIBS@@#$(LIBS)#g' \
140 145 -e 's#@@SHARED_CFLAGS@@#$(SHARED_CFLAGS)#g' \
141 146 -e 's#@@SHARED_LDFLAGS@@#$(SHARED_LDFLAGS)#g' < $< > $@
142 147 chmod +x $@
143 148
144 149 $(VER.64)/configure: $(VER.64)/Configure Makefile $(PKCS11.64) \
145 150 $(VER.64)/sunw_prefix.h
146 151 sed -e 's#@@CC@@#$(GCC.64)#g' \
147 152 -e 's#@@CPPFLAGS@@#$(CPPFLAGS)#g' \
148 153 -e 's#@@CFLAGS@@#$(CFLAGS.64)#g' \
149 154 -e 's#@@MT_CPPFLAGS@@#$(MT_CPPFLAGS)#g' \
150 155 -e 's#@@LDFLAGS@@#$(LDFLAGS.64)#g' \
151 156 -e 's#@@LIBS@@#$(LIBS)#g' \
152 157 -e 's#@@SHARED_CFLAGS@@#$(SHARED_CFLAGS)#g' \
153 158 -e 's#@@SHARED_LDFLAGS@@#$(SHARED_LDFLAGS)#g' < $< > $@
154 159 chmod +x $@
155 160
156 161 all: all_autoconf
157 162
158 163 check: $(CHECK_LIBS:%=%.check)
159 164
160 165 %.check: %
161 166 syms="$$(/usr/bin/nm -ph $< | \
162 167 awk '$$2 == T && $$3 != _init && $$3 != _fini { print $$3 }' | \
163 168 grep -v ^sunw_)"; \
164 169 if [[ -n "$$syms" ]]; then \
165 170 echo "Unprefixed symbols found in $<: $$syms"; \
166 171 exit 1; \
167 172 else \
168 173 touch $@; \
169 174 fi
170 175
171 176 $(CHECK_LIBS): all
172 177
173 178 install_32: all check
174 179 DESTDIR=$(DESTDIR) VERDIR=$(VER.32) LIBVER=$(LIBVER) \
175 180 ksh93 ./install-sfw
176 181
177 182 install_64: all check
178 183 DESTDIR=$(DESTDIR) VERDIR=$(VER.64) LIBVER=$(LIBVER) \
179 184 ksh93 ./install-sfw-64
180 185
181 186 install: install_32 install_64
182 187
183 188 include ../Makefile.targ
↓ open down ↓ |
88 lines elided |
↑ open up ↑ |
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX