]>
Commit | Line | Data |
---|---|---|
2692550d JP |
1 | %bcond_with bootstrap # build a bootstrap version, using icedtea6 |
2 | %bcond_without cacerts # don't include the default CA certificates | |
3899c70b JK |
3 | |
4 | %if %{with bootstrap} | |
91e281dc | 5 | %define use_jdk openjdk8 |
3899c70b | 6 | %else |
2692550d JP |
7 | %define use_jdk openjdk9 |
8 | %endif | |
9 | ||
10 | %ifarch %{x8664} | |
11 | %define with_aot 1 | |
3899c70b JK |
12 | %endif |
13 | ||
74861363 JP |
14 | %ifarch x32 |
15 | %define with_zero 1 | |
16 | %endif | |
17 | ||
3899c70b | 18 | # class data version seen with file(1) that this jvm is able to load |
2692550d JP |
19 | %define _classdataversion 53.0 |
20 | ||
21 | %define ver_u 9.0.4 | |
22 | %define ver_b 12 | |
23 | ||
d8978afb | 24 | # JDK/JRE version, as returned with `java -version`, '_' replaced with '.' |
2692550d | 25 | %define _jdkversion %{ver_u} |
3899c70b | 26 | |
83cf7429 | 27 | Summary: Open-source implementation of the Java Platform, Standard Edition |
2692550d JP |
28 | Summary(pl.UTF-8): Wolnoźródłowa implementacja Java 9 SE |
29 | Name: openjdk9 | |
30 | Version: %{ver_u}.%{ver_b} | |
4dea4bf8 | 31 | Release: 3 |
3899c70b JK |
32 | License: GPL v2 |
33 | Group: Development/Languages/Java | |
2692550d JP |
34 | Source0: https://hg.openjdk.java.net/jdk-updates/jdk9u/archive/jdk-%{ver_u}+%{ver_b}.tar.bz2?/%{name}-%{version}.tar.bz2 |
35 | # Source0-md5: f71280d31603efeffdadea56fab8436e | |
36 | Source1: https://hg.openjdk.java.net/jdk-updates/jdk9u/corba/archive/jdk-%{ver_u}+%{ver_b}.tar.bz2?/%{name}-corba-%{version}.tar.bz2 | |
37 | # Source1-md5: 2bc0a490f71eaa17fcae9387b354ccfd | |
38 | Source2: https://hg.openjdk.java.net/jdk-updates/jdk9u/hotspot/archive/jdk-%{ver_u}+%{ver_b}.tar.bz2?/%{name}-hotspot-%{version}.tar.bz2 | |
39 | # Source2-md5: 37ff0144a673417c793d282d12aba6a1 | |
40 | Source3: https://hg.openjdk.java.net/jdk-updates/jdk9u/jaxp/archive/jdk-%{ver_u}+%{ver_b}.tar.bz2?/%{name}-jaxp-%{version}.tar.bz2 | |
41 | # Source3-md5: c6c4ee8ef80f10fc4fbc9d151436c89a | |
42 | Source4: https://hg.openjdk.java.net/jdk-updates/jdk9u/jaxws/archive/jdk-%{ver_u}+%{ver_b}.tar.bz2?/%{name}-jaxws-%{version}.tar.bz2 | |
43 | # Source4-md5: 3cf0375c3bba7d028c8408e41bbbb352 | |
44 | Source5: https://hg.openjdk.java.net/jdk-updates/jdk9u/jdk/archive/jdk-%{ver_u}+%{ver_b}.tar.bz2?/%{name}-jdk-%{version}.tar.bz2 | |
45 | # Source5-md5: 74d33ad39f5b67596c5269585811cfab | |
46 | Source6: https://hg.openjdk.java.net/jdk-updates/jdk9u/langtools/archive/jdk-%{ver_u}+%{ver_b}.tar.bz2?/%{name}-langtools-%{version}.tar.bz2 | |
47 | # Source6-md5: 95d7011a050602218b5400c632339e2c | |
48 | Source7: https://hg.openjdk.java.net/jdk-updates/jdk9u/nashorn/archive/jdk-%{ver_u}+%{ver_b}.tar.bz2?/%{name}-nashorn-%{version}.tar.bz2 | |
49 | # Source7-md5: 5fbaceceb82449806263ba99188b7139 | |
3899c70b | 50 | Source10: make-cacerts.sh |
2692550d JP |
51 | Patch0: libpath.patch |
52 | Patch1: make-4.3.patch | |
53 | Patch2: x32.patch | |
54 | Patch3: aarch64.patch | |
76fd6e23 | 55 | Patch4: default-assumemp.patch |
e27f9dd8 | 56 | Patch5: glibc-2.34.patch |
5491470b | 57 | Patch6: gcc11.patch |
b2950e84 | 58 | URL: http://openjdk.java.net/ |
9910e19d | 59 | BuildRequires: /usr/bin/jar |
b2950e84 JK |
60 | BuildRequires: alsa-lib-devel |
61 | BuildRequires: ant | |
62 | BuildRequires: autoconf | |
63 | BuildRequires: bash | |
64 | %{?with_cacerts:BuildRequires: ca-certificates-update} | |
65 | BuildRequires: cups-devel | |
2692550d | 66 | BuildRequires: elfutils-devel |
b2950e84 JK |
67 | BuildRequires: freetype-devel >= 2.3 |
68 | BuildRequires: gawk | |
665079f5 | 69 | BuildRequires: giflib-devel >= 5.1 |
b2950e84 | 70 | BuildRequires: glibc-misc |
83cf7429 | 71 | %{?buildrequires_jdk} |
991454fa | 72 | BuildRequires: lcms2-devel |
3899c70b | 73 | BuildRequires: libjpeg-devel |
991454fa | 74 | BuildRequires: libpng-devel |
3899c70b | 75 | BuildRequires: lsb-release |
991454fa | 76 | BuildRequires: pcsc-lite-devel |
3899c70b | 77 | BuildRequires: pkgconfig |
58e78be3 | 78 | BuildRequires: rpm-build >= 4.6 |
3899c70b | 79 | BuildRequires: rpmbuild(macros) >= 1.557 |
3899c70b JK |
80 | BuildRequires: unzip |
81 | BuildRequires: util-linux | |
82 | BuildRequires: xorg-lib-libX11-devel | |
83 | BuildRequires: xorg-lib-libXinerama-devel | |
84 | BuildRequires: xorg-lib-libXp-devel | |
85 | BuildRequires: xorg-lib-libXrender-devel | |
86 | BuildRequires: xorg-lib-libXt-devel | |
87 | BuildRequires: xorg-lib-libXtst-devel | |
88 | BuildRequires: xorg-proto-printproto-devel | |
89 | BuildRequires: xorg-proto-xproto-devel | |
90 | BuildRequires: zip | |
91 | BuildRequires: zlib-devel | |
92 | Requires: %{name}-appletviewer = %{version}-%{release} | |
93 | Requires: %{name}-jdk = %{version}-%{release} | |
94 | Suggests: %{name}-jre-X11 | |
95 | Suggests: icedtea-web | |
96 | Obsoletes: icedtea6 | |
97 | Obsoletes: icedtea7 | |
3899c70b JK |
98 | Obsoletes: java-gcj-compat |
99 | Obsoletes: java-gcj-compat-devel | |
100 | Obsoletes: java-sun | |
101 | Obsoletes: java-sun-demos | |
102 | Obsoletes: java-sun-jre | |
9910e19d | 103 | Obsoletes: java-sun-jre-X11 |
3899c70b JK |
104 | Obsoletes: java-sun-jre-alsa |
105 | Obsoletes: java-sun-jre-jdbc | |
3899c70b | 106 | Obsoletes: java-sun-tools |
9910e19d JK |
107 | Obsoletes: java5-sun |
108 | Obsoletes: java5-sun-jre | |
109 | Obsoletes: java5-sun-jre-X11 | |
110 | Obsoletes: java5-sun-jre-jdbc | |
111 | Obsoletes: java5-sun-tools | |
3899c70b JK |
112 | Obsoletes: oracle-java7 |
113 | Obsoletes: oracle-java7-jre | |
9910e19d | 114 | Obsoletes: oracle-java7-jre-X11 |
3899c70b JK |
115 | Obsoletes: oracle-java7-jre-alsa |
116 | Obsoletes: oracle-java7-jre-jdbc | |
3899c70b JK |
117 | Obsoletes: oracle-java7-tools |
118 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
119 | ||
120 | %define dstreldir %{name}-%{version} | |
121 | %define dstdir %{_jvmdir}/%{dstreldir} | |
3899c70b JK |
122 | %define jvmjardir %{_jvmjardir}/%{name}-%{version} |
123 | ||
3899c70b JK |
124 | # to break artificial subpackage dependency loops |
125 | %define _noautoreq 'libmawt.so' java\\\\(ClassDataVersion\\\\) | |
126 | ||
2692550d JP |
127 | # openjdk build system handles _FORTIFY_SOURCE internally |
128 | %undefine _fortify_cflags | |
129 | ||
3899c70b JK |
130 | %description |
131 | Open-source implementation of the Java Platform, Standard Edition. | |
132 | ||
133 | This is a meta-package which provides, by its dependencies, all the | |
134 | OpenJDK components including the OpenJDK, Java 8 developement kit and | |
135 | runtime environment. | |
136 | ||
137 | %description -l pl.UTF-8 | |
138 | Wolnoźródłowa implementacja Java 8 SE. | |
139 | ||
140 | To jest meta-pakiet, który, za pośrednictwem zależności, dostarcza | |
141 | wszystkie komponenty OpenJDK, w tym środowisko programistyczne | |
142 | (OpenJDK) i uruchomieniowe (JRE). | |
143 | ||
144 | %package jdk | |
145 | Summary: OpenJDK - software development kit | |
146 | Summary(pl.UTF-8): OpenJDK - środowisko programistyczne | |
147 | Group: Development/Languages/Java | |
148 | Requires: %{name}-jar = %{version}-%{release} | |
149 | Requires: %{name}-jdk-base = %{version}-%{release} | |
150 | Requires: %{name}-jre = %{version}-%{release} | |
d8978afb JK |
151 | Provides: j2sdk = %{_jdkversion} |
152 | Provides: jdk = %{_jdkversion} | |
3899c70b JK |
153 | Obsoletes: blackdown-java-sdk |
154 | Obsoletes: ibm-java | |
155 | Obsoletes: icedtea6-jdk | |
156 | Obsoletes: icedtea7-jdk | |
157 | Obsoletes: java-blackdown | |
158 | Obsoletes: java-gcj-compat-devel | |
159 | Obsoletes: java-sun | |
160 | Obsoletes: java5-sun | |
3899c70b JK |
161 | Obsoletes: jdk |
162 | Obsoletes: kaffe | |
9910e19d | 163 | Obsoletes: oracle-java7 |
3899c70b JK |
164 | |
165 | %description jdk | |
166 | This package symlinks OpenJDK development tools provided by | |
167 | %{name}-jdk-base to system-wide directories like %{_bindir}, making | |
168 | OpenJDK the default JDK. | |
169 | ||
170 | %description jdk -l pl.UTF-8 | |
171 | Ten pakiet tworzy symboliczne dowiązania do narzędzi programistycznych | |
172 | OpenJDK, dostarczanych przez pakiet %{name}-jdk-base, w standardowych | |
173 | systemowych ścieżkach takich jak %{_bindir}, sprawiając tym samym, że | |
174 | OpenJDK staje się domyślnym JDK w systemie. | |
175 | ||
176 | %package jdk-base | |
177 | Summary: OpenJDK - software development kit | |
178 | Summary(pl.UTF-8): Kod OpenJDK - środowisko programistyczne | |
179 | Group: Development/Languages/Java | |
180 | Requires: %{name}-jre-base = %{version}-%{release} | |
2692550d | 181 | Requires: jpackage-utils >= 0:1.7.5-8 |
3899c70b JK |
182 | Provides: jdk(%{name}) |
183 | ||
184 | %description jdk-base | |
185 | OpenJDK development tools built using free software only. | |
186 | ||
187 | %description jdk-base -l pl.UTF-8 | |
188 | OpenJDK skompilowane wyłącznie przy użyciu wolnego oprogramowania. | |
189 | ||
190 | %package jre | |
191 | Summary: OpenJDK - runtime environment | |
192 | Summary(pl.UTF-8): OpenJDK - środowisko uruchomieniowe | |
193 | Group: Development/Languages/Java | |
194 | Requires: %{name}-jre-base = %{version}-%{release} | |
195 | Requires: nss >= 1:3.13.4 | |
196 | # Require zoneinfo data provided by java-tzdata subpackage. | |
197 | Requires: java-tzdata | |
198 | Provides: java | |
199 | Provides: java(ClassDataVersion) = %{_classdataversion} | |
200 | Provides: java(jaas) = %{version} | |
201 | Provides: java(jaf) = 1.1.1 | |
202 | Provides: java(jaxp) = 1.3 | |
203 | Provides: java(jaxp_parser_impl) | |
204 | Provides: java(jce) = %{version} | |
205 | Provides: java(jdbc-stdext) = %{version} | |
206 | Provides: java(jdbc-stdext) = 3.0 | |
207 | Provides: java(jmx) = 1.4 | |
208 | Provides: java(jndi) = %{version} | |
209 | Provides: java(jsse) = %{version} | |
210 | Provides: java1.4 | |
d8978afb | 211 | Provides: jre = %{_jdkversion} |
3899c70b JK |
212 | Obsoletes: icedtea6-jre |
213 | Obsoletes: icedtea7-jre | |
76fd6e23 AM |
214 | Obsoletes: icedtea8-jre |
215 | Obsoletes: jaas | |
216 | Obsoletes: jaf | |
217 | Obsoletes: java5-sun-jre | |
3899c70b | 218 | Obsoletes: java-gcj-compat |
76fd6e23 AM |
219 | Obsoletes: java-jaxp |
220 | Obsoletes: java-jdbc-stdext | |
3899c70b | 221 | Obsoletes: java-sun-jre |
76fd6e23 AM |
222 | Obsoletes: jce |
223 | Obsoletes: jdbc-stdext | |
224 | Obsoletes: jmx | |
225 | Obsoletes: jndi | |
b2950e84 | 226 | Obsoletes: jre |
76fd6e23 | 227 | Obsoletes: jsse |
9910e19d | 228 | Obsoletes: oracle-java7-jre |
3899c70b JK |
229 | |
230 | %description jre | |
231 | This package symlinks OpenJDK runtime environment tools provided by | |
232 | %{name}-jre-base to system-wide directories like %{_bindir}, making | |
233 | OpenJDK the default JRE. | |
234 | ||
235 | %description jre -l pl.UTF-8 | |
236 | Ten pakiet tworzy symboliczne dowiązania do środowiska | |
237 | uruchomieniowego OpenJDK, dostarczanych przez pakiet %{name}-jre-base, | |
238 | w standardowych systemowych ścieżkach takich jak %{_bindir}, | |
239 | sprawiając tym samym, że OpenJDK staje się domyślnym JRE w systemie. | |
240 | ||
241 | %package jre-X11 | |
242 | Summary: OpenJDK - runtime environment - X11 support | |
243 | Summary(pl.UTF-8): OpenJDK - środowisko uruchomieniowe - obsługa X11 | |
244 | Group: Development/Languages/Java | |
245 | Requires: %{name}-jre = %{version}-%{release} | |
246 | Requires: %{name}-jre-base-X11 = %{version}-%{release} | |
d8978afb | 247 | Provides: jre-X11 = %{_jdkversion} |
3899c70b JK |
248 | Obsoletes: icedtea6-jre-X11 |
249 | Obsoletes: icedtea7-jre-X11 | |
250 | Obsoletes: java-sun-jre-X11 | |
251 | Obsoletes: oracle-java7-jre-X11 | |
252 | ||
253 | %description jre-X11 | |
254 | X11 support for OpenJDK runtime environment built using free software | |
255 | only. | |
256 | ||
257 | %description jre-X11 -l pl.UTF-8 | |
258 | Biblioteki X11 dla środowiska OpenJDK zbudowany wyłocznie przy uzyciu | |
259 | wolnego oprogramowania. | |
260 | ||
261 | %package jre-base | |
262 | Summary: OpenJDK - runtime environment | |
263 | Summary(pl.UTF-8): OpenJDK - środowisko uruchomieniowe | |
264 | Group: Development/Languages/Java | |
2692550d | 265 | Requires: jpackage-utils >= 0:1.7.5-8 |
3899c70b JK |
266 | Provides: jre(%{name}) |
267 | ||
268 | %description jre-base | |
269 | OpenJDK runtime environment built using free software only. | |
270 | ||
271 | %description jre-base -l pl.UTF-8 | |
272 | Środowisko uruchomieniowe OpenJDK zbudowany wyłącznie przy użyciu | |
273 | wolnego oprogramowania. | |
274 | ||
275 | %package jre-base-X11 | |
276 | Summary: OpenJDK - runtime environment - X11 support | |
277 | Summary(pl.UTF-8): OpenJDK - środowisko uruchomieniowe - obsługa X11 | |
278 | Group: Development/Languages/Java | |
279 | Requires: %{name}-jre-base = %{version}-%{release} | |
280 | Requires: %{name}-jre-base-freetype = %{version}-%{release} | |
281 | ||
282 | %description jre-base-X11 | |
283 | X11 support for OpenJDK runtime environment built using free software | |
284 | only. | |
285 | ||
286 | %description jre-base-X11 -l pl.UTF-8 | |
287 | Biblioteki X11 dla środowiska OpenJDK zbudowany wyłocznie przy uzyciu | |
288 | wolnego oprogramowania. | |
289 | ||
290 | %package jre-base-alsa | |
291 | Summary: OpenJDK - runtime environment - ALSA support | |
292 | Summary(pl.UTF-8): OpenJDK - środowisko uruchomieniowe - obsługa ALSA | |
293 | Group: Development/Languages/Java | |
294 | Requires: %{name}-jre-base = %{version}-%{release} | |
295 | ||
296 | %description jre-base-alsa | |
297 | ALSA sound support for OpenJDK runtime environment build using free | |
298 | software only. | |
299 | ||
300 | %description jre-base-alsa -l pl.UTF-8 | |
301 | Biblioteki ALSA rozszerzające środowisko OpenJDK o obsługę dźwięku | |
302 | zbudowane przy uzyciu wyłącznie wolnego oprogramowania. | |
303 | ||
304 | %package jre-base-freetype | |
305 | Summary: OpenJDK - runtime environment - font support | |
306 | Summary(pl.UTF-8): OpenJDK - środowisko uruchomieniowe - obsługa fontów | |
307 | Group: Development/Languages/Java | |
308 | Requires: %{name}-jre-base = %{version}-%{release} | |
309 | ||
310 | %description jre-base-freetype | |
311 | Font handling library for OpenJDK runtime environment built using free | |
312 | software only. | |
313 | ||
314 | %description jre-base-freetype -l pl.UTF-8 | |
315 | Biblioteki obsługi czcionek dla OpenJDK zbudowane wyłącznie przy | |
316 | użyciu wolnego oprogramowania. | |
317 | ||
318 | %package jre-base-gtk | |
319 | Summary: OpenJDK - runtime environment - GTK support | |
320 | Summary(pl.UTF-8): OpenJDK - środowisko uruchomieniowe - obsługa GTK | |
321 | Group: Development/Languages/Java | |
322 | Requires: %{name}-jre-base = %{version}-%{release} | |
323 | ||
324 | %description jre-base-gtk | |
325 | GTK support for OpenJDK runtime environment. | |
326 | ||
327 | %description jre-base-gtk -l pl.UTF-8 | |
328 | Biblioteki GTK dla OpenJDK. | |
329 | ||
330 | %package jar | |
331 | Summary: OpenJDK - JAR tool | |
332 | Summary(pl.UTF-8): OpenJDK - narzędzie JAR | |
333 | Group: Development/Languages/Java | |
334 | Requires: %{name}-jdk-base = %{version}-%{release} | |
335 | Provides: jar | |
336 | Obsoletes: fastjar | |
337 | Obsoletes: icedtea6-jar | |
338 | Obsoletes: icedtea7-jar | |
339 | Obsoletes: jar | |
340 | ||
341 | %description jar | |
342 | JAR tool from OpenJDK built using free software only. | |
343 | ||
344 | JAR is an archiver used to merge Java classes into a single library. | |
345 | ||
346 | %description jar -l pl.UTF-8 | |
347 | Narzędzie jar z OpenJDK zbudowane przy uzyciu wyłącznie wolnego | |
348 | oprogramowania. | |
349 | ||
350 | JAR jest narzędziem pozwalającym wykonywać podstawowe operacje na | |
351 | archiwach javy .jar takie jak na przykład tworzenie lub rozpakowywanie | |
352 | archiwów. | |
353 | ||
354 | %package appletviewer | |
355 | Summary: OpenJDK - appletviewer tool | |
356 | Summary(pl.UTF-8): OpenJDK - narzędzie appletviewer | |
357 | Group: Development/Languages/Java | |
358 | Requires: %{name}-jdk-base = %{version}-%{release} | |
359 | Requires: %{name}-jre-X11 = %{version}-%{release} | |
360 | Obsoletes: icedtea6-appletviewer | |
361 | Obsoletes: icedtea7-appletviewer | |
362 | Obsoletes: java-sun-appletviewer | |
363 | Obsoletes: oracle-java7-appletviewer | |
364 | ||
365 | %description appletviewer | |
366 | Appletviewer from OpenJDK build using free software only. | |
367 | ||
368 | %description appletviewer -l pl.UTF-8 | |
369 | Appletviewer pozwala uruchamiać aplety javy niezależnie od | |
370 | przeglądarki www. Ten appletviewer pochodzi z zestawu narzędzi OpenJDK | |
371 | i został zbudowany wyłącznie przy użyciu wolnego oprogramowania. | |
372 | ||
373 | %package jdk-sources | |
374 | Summary: OpenJDK - sources | |
375 | Summary(pl.UTF-8): OpenJDK - kod źródłowy | |
376 | Group: Documentation | |
3899c70b | 377 | BuildArch: noarch |
3899c70b JK |
378 | |
379 | %description jdk-sources | |
380 | Source code for the OpenJDK development kit and Java standard library. | |
381 | ||
382 | %description jdk-sources -l pl.UTF-8 | |
383 | Kod źródłowy narzędzi programistycznych OpenJDK oraz standardowej | |
384 | biblioteki Javy. | |
385 | ||
386 | %package examples | |
387 | Summary: OpenJDK - examples | |
388 | Summary(pl.UTF-8): OpenJDK - przykłady | |
389 | Group: Documentation | |
3899c70b | 390 | BuildArch: noarch |
3899c70b JK |
391 | |
392 | %description examples | |
393 | Code examples for OpenJDK. | |
394 | ||
395 | %description examples -l pl.UTF-8 | |
396 | Przykłady dla OpenJDK. | |
397 | ||
398 | %prep | |
2692550d | 399 | %setup -qn jdk9u-jdk-%{ver_u}+%{ver_b} -a1 -a2 -a3 -a4 -a5 -a6 -a7 |
3899c70b | 400 | |
2692550d JP |
401 | for d in *-jdk-%{ver_u}+%{ver_b}* ; do |
402 | mv "$d" "${d%%-jdk-%{ver_u}+%{ver_b}}" | |
3899c70b JK |
403 | done |
404 | ||
5b4e4f20 JK |
405 | %patch0 -p1 |
406 | %patch1 -p1 | |
d12f28e3 | 407 | %patch2 -p1 |
2692550d | 408 | %ifarch aarch64 |
ce94f011 | 409 | %patch3 -p1 |
2692550d | 410 | %endif |
76fd6e23 | 411 | %patch4 -p1 |
e27f9dd8 | 412 | %patch5 -p1 |
5491470b | 413 | %patch6 -p1 |
5b4e4f20 | 414 | |
3899c70b JK |
415 | %build |
416 | # Make sure we have /proc mounted - otherwise idlc will fail later. | |
417 | if [ ! -f /proc/self/stat ]; then | |
418 | echo "You need to have /proc mounted in order to build this package!" | |
419 | exit 1 | |
420 | fi | |
421 | ||
991454fa | 422 | cd common/autoconf |
bd96d31d | 423 | rm generated-configure.sh |
991454fa JK |
424 | %{__autoconf} -o generated-configure.sh |
425 | cd ../.. | |
426 | ||
3899c70b | 427 | mkdir -p build-bin |
b3255d96 | 428 | |
b3255d96 JK |
429 | # unset CLASSPATH to be safe, gnustep puts garbage there, which openjdk hates |
430 | unset CLASSPATH | |
431 | ||
d12f28e3 | 432 | export SHELL=/bin/bash |
3899c70b | 433 | |
5b4e4f20 JK |
434 | chmod a+x configure |
435 | ||
2dab85d0 | 436 | # disable-debug-symbols so openjdk debuginfo handling won't conflict with ours |
5b4e4f20 | 437 | %configure \ |
74861363 | 438 | %{?with_zero:--with-jvm-variants=zero} \ |
2692550d JP |
439 | --with-boot-jdk="%{java_home}" \ |
440 | --with-extra-cflags="%{rpmcppflags} %{rpmcflags} -fcommon -fno-tree-dse" \ | |
441 | --with-extra-cxxflags="%{rpmcppflags} %{rpmcxxflags} -fcommon -fno-tree-dse" \ | |
5b4e4f20 | 442 | --with-extra-ldflags="%{rpmldflags}" \ |
2692550d | 443 | --with-native-debug-symbols=none \ |
c0e7c813 | 444 | --disable-full-docs \ |
2692550d JP |
445 | --disable-javac-server \ |
446 | --disable-hotspot-gtest \ | |
447 | --disable-warnings-as-errors \ | |
448 | --with-jobs="%{__jobs}" \ | |
665079f5 | 449 | --with-giflib=system \ |
991454fa JK |
450 | --with-libjpeg=system \ |
451 | --with-libpng=system \ | |
452 | --with-lcms=system \ | |
2692550d JP |
453 | --with-zlib=system \ |
454 | --with-version-pre="" \ | |
455 | --with-version-opt="" \ | |
456 | --with-version-build="%{release}" | |
5b4e4f20 JK |
457 | |
458 | specdir="$(dirname build/*-release/spec.gmk)" | |
459 | cat > $specdir/custom-spec.gmk <<EOF | |
2dab85d0 | 460 | # OpenJDK build system depends on bash |
5b4e4f20 JK |
461 | SHELL=/bin/bash |
462 | EOF | |
2dab85d0 | 463 | [ -L tmp-bin ] || ln -s "$specdir/jdk/bin" tmp-bin |
5b4e4f20 | 464 | |
2692550d | 465 | %{__make} -j1 all \ |
2dab85d0 JK |
466 | LOG=debug \ |
467 | # these are normally set when --disable-debug-symbols is not used \ | |
468 | LIBMANAGEMENT_OPTIMIZATION=LOW \ | |
469 | LIBHPROF_OPTIMIZATION=LOW \ | |
470 | LIBVERIFY_OPTIMIZATION=LOW | |
3899c70b | 471 | |
052665c9 JK |
472 | # smoke test |
473 | tmp-bin/java -version | |
474 | ||
d12f28e3 | 475 | export PATH="$(pwd)/build-bin:$PATH" |
3899c70b JK |
476 | %{?with_cacerts:%{__sh} %{SOURCE10}} |
477 | ||
478 | %install | |
479 | rm -rf $RPM_BUILD_ROOT | |
480 | install -d $RPM_BUILD_ROOT{%{_bindir},%{dstdir},%{_mandir}/ja} \ | |
481 | $RPM_BUILD_ROOT{%{jvmjardir},%{_examplesdir}/%{name}-%{version},%{_javasrcdir}} \ | |
482 | $RPM_BUILD_ROOT%{_sysconfdir}/%{name} | |
483 | ||
484 | # install the 'JDK image', it contains the JRE too | |
2692550d JP |
485 | cp -a build/*-release/images/jdk/* $RPM_BUILD_ROOT%{dstdir} |
486 | ||
487 | find $RPM_BUILD_ROOT%{dstdir} -name '*.diz' -delete | |
3899c70b JK |
488 | |
489 | # convenience symlinks without version number | |
490 | ln -s %{dstreldir} $RPM_BUILD_ROOT%{_jvmdir}/%{name} | |
2692550d | 491 | ln -s %{dstreldir} $RPM_BUILD_ROOT%{_jvmdir}/%{name}-jre |
3899c70b JK |
492 | |
493 | ln -s %{dstreldir} $RPM_BUILD_ROOT%{_jvmdir}/java | |
494 | ||
9910e19d | 495 | # move JDK sources and demo to %{_prefix}/src |
3899c70b | 496 | mv $RPM_BUILD_ROOT%{dstdir}/demo $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version} |
2692550d | 497 | mv $RPM_BUILD_ROOT%{dstdir}/lib/src.zip $RPM_BUILD_ROOT%{_javasrcdir}/%{name}-jdk.zip |
3899c70b JK |
498 | |
499 | # move manual pages to its place | |
500 | mv $RPM_BUILD_ROOT%{dstdir}/man/ja_JP.UTF-8/man1 $RPM_BUILD_ROOT%{_mandir}/ja/man1 | |
501 | rmdir $RPM_BUILD_ROOT%{dstdir}/man/ja_JP.UTF-8 | |
502 | rm $RPM_BUILD_ROOT%{dstdir}/man/ja | |
503 | mv $RPM_BUILD_ROOT%{dstdir}/man/man1 $RPM_BUILD_ROOT%{_mandir}/man1 | |
504 | rmdir $RPM_BUILD_ROOT%{dstdir}/man | |
505 | ||
506 | # replace duplicates with symlinks, link to %{_bindir} | |
507 | for path in $RPM_BUILD_ROOT%{dstdir}/bin/*; do | |
508 | filename=$(basename $path) | |
2692550d | 509 | ln -sf "%{dstdir}/bin/$filename" $RPM_BUILD_ROOT%{_bindir} |
3899c70b | 510 | done |
3899c70b | 511 | |
9910e19d | 512 | # keep configuration in %{_sysconfdir} (not all *.properties go there) |
2692550d | 513 | for config in management security \ |
3899c70b JK |
514 | logging.properties net.properties sound.properties; do |
515 | ||
2692550d JP |
516 | mv $RPM_BUILD_ROOT%{dstdir}/conf/$config $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/$config |
517 | ln -s %{_sysconfdir}/%{name}/$config $RPM_BUILD_ROOT%{dstdir}/conf/$config | |
3899c70b JK |
518 | done |
519 | ||
3899c70b JK |
520 | %{?with_cacerts:install cacerts $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/security} |
521 | ||
522 | %clean | |
523 | rm -rf $RPM_BUILD_ROOT | |
524 | ||
525 | %files | |
526 | %defattr(644,root,root,755) | |
3899c70b JK |
527 | |
528 | %files jdk | |
529 | %defattr(644,root,root,755) | |
2692550d | 530 | %{?with_aot:%attr(755,root,root) %{_bindir}/jaotc} |
3899c70b | 531 | %attr(755,root,root) %{_bindir}/jarsigner |
3899c70b JK |
532 | %attr(755,root,root) %{_bindir}/javac |
533 | %attr(755,root,root) %{_bindir}/javadoc | |
534 | %attr(755,root,root) %{_bindir}/javah | |
535 | %attr(755,root,root) %{_bindir}/javap | |
536 | %attr(755,root,root) %{_bindir}/jcmd | |
537 | %attr(755,root,root) %{_bindir}/jconsole | |
538 | %attr(755,root,root) %{_bindir}/jdb | |
2692550d | 539 | %attr(755,root,root) %{_bindir}/jdeprscan |
d12f28e3 | 540 | %attr(755,root,root) %{_bindir}/jdeps |
74861363 | 541 | %{!?with_zero:%attr(755,root,root) %{_bindir}/jhsdb} |
2692550d | 542 | %attr(755,root,root) %{_bindir}/jimage |
3899c70b | 543 | %attr(755,root,root) %{_bindir}/jinfo |
2692550d | 544 | %attr(755,root,root) %{_bindir}/jlink |
3899c70b | 545 | %attr(755,root,root) %{_bindir}/jmap |
2692550d | 546 | %attr(755,root,root) %{_bindir}/jmod |
3899c70b | 547 | %attr(755,root,root) %{_bindir}/jps |
2692550d | 548 | %attr(755,root,root) %{_bindir}/jshell |
3899c70b JK |
549 | %attr(755,root,root) %{_bindir}/jstack |
550 | %attr(755,root,root) %{_bindir}/jstat | |
551 | %attr(755,root,root) %{_bindir}/jstatd | |
3899c70b JK |
552 | %attr(755,root,root) %{_bindir}/rmic |
553 | %attr(755,root,root) %{_bindir}/schemagen | |
554 | %attr(755,root,root) %{_bindir}/serialver | |
555 | %attr(755,root,root) %{_bindir}/wsgen | |
556 | %attr(755,root,root) %{_bindir}/wsimport | |
557 | %attr(755,root,root) %{_bindir}/xjc | |
558 | %{_jvmdir}/java | |
3899c70b JK |
559 | %{_mandir}/man1/jarsigner.1* |
560 | %{_mandir}/man1/javac.1* | |
561 | %{_mandir}/man1/javadoc.1* | |
562 | %{_mandir}/man1/javah.1* | |
563 | %{_mandir}/man1/javap.1* | |
564 | %{_mandir}/man1/jcmd.1* | |
565 | %{_mandir}/man1/jconsole.1* | |
566 | %{_mandir}/man1/jdb.1* | |
d12f28e3 | 567 | %{_mandir}/man1/jdeps.1* |
3899c70b JK |
568 | %{_mandir}/man1/jinfo.1* |
569 | %{_mandir}/man1/jmap.1* | |
570 | %{_mandir}/man1/jps.1* | |
3899c70b JK |
571 | %{_mandir}/man1/jstack.1* |
572 | %{_mandir}/man1/jstat.1* | |
573 | %{_mandir}/man1/jstatd.1* | |
3899c70b JK |
574 | %{_mandir}/man1/schemagen.1* |
575 | %{_mandir}/man1/serialver.1* | |
576 | %{_mandir}/man1/rmic.1* | |
577 | %{_mandir}/man1/wsgen.1* | |
578 | %{_mandir}/man1/wsimport.1* | |
579 | %{_mandir}/man1/xjc.1* | |
3899c70b JK |
580 | %lang(ja) %{_mandir}/ja/man1/jarsigner.1* |
581 | %lang(ja) %{_mandir}/ja/man1/javac.1* | |
582 | %lang(ja) %{_mandir}/ja/man1/javadoc.1* | |
583 | %lang(ja) %{_mandir}/ja/man1/javah.1* | |
584 | %lang(ja) %{_mandir}/ja/man1/javap.1* | |
585 | %lang(ja) %{_mandir}/ja/man1/jcmd.1* | |
586 | %lang(ja) %{_mandir}/ja/man1/jconsole.1* | |
587 | %lang(ja) %{_mandir}/ja/man1/jdb.1* | |
d12f28e3 | 588 | %lang(ja) %{_mandir}/ja/man1/jdeps.1* |
3899c70b JK |
589 | %lang(ja) %{_mandir}/ja/man1/jinfo.1* |
590 | %lang(ja) %{_mandir}/ja/man1/jmap.1* | |
591 | %lang(ja) %{_mandir}/ja/man1/jps.1* | |
3899c70b JK |
592 | %lang(ja) %{_mandir}/ja/man1/jstack.1* |
593 | %lang(ja) %{_mandir}/ja/man1/jstat.1* | |
594 | %lang(ja) %{_mandir}/ja/man1/jstatd.1* | |
3899c70b JK |
595 | %lang(ja) %{_mandir}/ja/man1/schemagen.1* |
596 | %lang(ja) %{_mandir}/ja/man1/serialver.1* | |
597 | %lang(ja) %{_mandir}/ja/man1/rmic.1* | |
598 | %lang(ja) %{_mandir}/ja/man1/wsgen.1* | |
599 | %lang(ja) %{_mandir}/ja/man1/wsimport.1* | |
600 | %lang(ja) %{_mandir}/ja/man1/xjc.1* | |
601 | ||
602 | %files jdk-base | |
603 | %defattr(644,root,root,755) | |
3899c70b JK |
604 | %dir %{dstdir} |
605 | %{_jvmdir}/%{name} | |
606 | %attr(755,root,root) %{dstdir}/bin/appletviewer | |
2692550d | 607 | %{?with_aot:%attr(755,root,root) %{dstdir}/bin/jaotc} |
3899c70b JK |
608 | %attr(755,root,root) %{dstdir}/bin/jar |
609 | %attr(755,root,root) %{dstdir}/bin/jarsigner | |
3899c70b JK |
610 | %attr(755,root,root) %{dstdir}/bin/javac |
611 | %attr(755,root,root) %{dstdir}/bin/javadoc | |
612 | %attr(755,root,root) %{dstdir}/bin/javah | |
613 | %attr(755,root,root) %{dstdir}/bin/javap | |
614 | %attr(755,root,root) %{dstdir}/bin/jconsole | |
615 | %attr(755,root,root) %{dstdir}/bin/jcmd | |
616 | %attr(755,root,root) %{dstdir}/bin/jdb | |
2692550d | 617 | %attr(755,root,root) %{dstdir}/bin/jdeprscan |
d12f28e3 | 618 | %attr(755,root,root) %{dstdir}/bin/jdeps |
74861363 | 619 | %{!?with_zero:%attr(755,root,root) %{dstdir}/bin/jhsdb} |
2692550d | 620 | %attr(755,root,root) %{dstdir}/bin/jimage |
3899c70b | 621 | %attr(755,root,root) %{dstdir}/bin/jinfo |
2692550d | 622 | %attr(755,root,root) %{dstdir}/bin/jlink |
3899c70b | 623 | %attr(755,root,root) %{dstdir}/bin/jmap |
2692550d | 624 | %attr(755,root,root) %{dstdir}/bin/jmod |
3899c70b | 625 | %attr(755,root,root) %{dstdir}/bin/jps |
2692550d | 626 | %attr(755,root,root) %{dstdir}/bin/jshell |
3899c70b JK |
627 | %attr(755,root,root) %{dstdir}/bin/jstack |
628 | %attr(755,root,root) %{dstdir}/bin/jstat | |
629 | %attr(755,root,root) %{dstdir}/bin/jstatd | |
3899c70b JK |
630 | %attr(755,root,root) %{dstdir}/bin/rmic |
631 | %attr(755,root,root) %{dstdir}/bin/schemagen | |
632 | %attr(755,root,root) %{dstdir}/bin/serialver | |
633 | %attr(755,root,root) %{dstdir}/bin/wsgen | |
634 | %attr(755,root,root) %{dstdir}/bin/wsimport | |
635 | %attr(755,root,root) %{dstdir}/bin/xjc | |
636 | %{dstdir}/include | |
2692550d JP |
637 | %{dstdir}/jmods |
638 | %{?with_aot:%attr(755,root,root) %{dstdir}/lib/libjelfshim.so} | |
3899c70b | 639 | %{dstdir}/lib/ct.sym |
3899c70b JK |
640 | |
641 | %files jre | |
642 | %defattr(644,root,root,755) | |
2692550d | 643 | %attr(755,root,root) %{_bindir}/idlj |
3899c70b | 644 | %attr(755,root,root) %{_bindir}/java |
d12f28e3 | 645 | %attr(755,root,root) %{_bindir}/jjs |
2692550d | 646 | %attr(755,root,root) %{_bindir}/jrunscript |
3899c70b JK |
647 | %attr(755,root,root) %{_bindir}/keytool |
648 | %attr(755,root,root) %{_bindir}/orbd | |
649 | %attr(755,root,root) %{_bindir}/pack200 | |
650 | %attr(755,root,root) %{_bindir}/rmid | |
651 | %attr(755,root,root) %{_bindir}/rmiregistry | |
652 | %attr(755,root,root) %{_bindir}/servertool | |
653 | %attr(755,root,root) %{_bindir}/tnameserv | |
654 | %attr(755,root,root) %{_bindir}/unpack200 | |
2692550d | 655 | %{_mandir}/man1/idlj.1* |
3899c70b | 656 | %{_mandir}/man1/java.1* |
d12f28e3 | 657 | %{_mandir}/man1/jjs.1* |
2692550d | 658 | %{_mandir}/man1/jrunscript.1* |
3899c70b JK |
659 | %{_mandir}/man1/keytool.1* |
660 | %{_mandir}/man1/orbd.1* | |
661 | %{_mandir}/man1/pack200.1* | |
662 | %{_mandir}/man1/rmid.1* | |
663 | %{_mandir}/man1/rmiregistry.1* | |
664 | %{_mandir}/man1/servertool.1* | |
665 | %{_mandir}/man1/tnameserv.1* | |
666 | %{_mandir}/man1/unpack200.1* | |
2692550d | 667 | %lang(ja) %{_mandir}/ja/man1/idlj.1* |
3899c70b | 668 | %lang(ja) %{_mandir}/ja/man1/java.1* |
d12f28e3 | 669 | %lang(ja) %{_mandir}/ja/man1/jjs.1* |
2692550d | 670 | %lang(ja) %{_mandir}/ja/man1/jrunscript.1* |
3899c70b JK |
671 | %lang(ja) %{_mandir}/ja/man1/keytool.1* |
672 | %lang(ja) %{_mandir}/ja/man1/orbd.1* | |
673 | %lang(ja) %{_mandir}/ja/man1/pack200.1* | |
674 | %lang(ja) %{_mandir}/ja/man1/rmid.1* | |
675 | %lang(ja) %{_mandir}/ja/man1/rmiregistry.1* | |
676 | %lang(ja) %{_mandir}/ja/man1/servertool.1* | |
677 | %lang(ja) %{_mandir}/ja/man1/tnameserv.1* | |
678 | %lang(ja) %{_mandir}/ja/man1/unpack200.1* | |
679 | ||
680 | %files jre-base | |
681 | %defattr(644,root,root,755) | |
3899c70b JK |
682 | %dir %{_sysconfdir}/%{name} |
683 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/* | |
684 | %dir %{dstdir} | |
685 | %{dstdir}/release | |
3899c70b | 686 | %{_jvmdir}/%{name}-jre |
3899c70b | 687 | %dir %{dstdir}/bin |
2692550d | 688 | %attr(755,root,root) %{dstdir}/bin/idlj |
3899c70b | 689 | %attr(755,root,root) %{dstdir}/bin/java |
d12f28e3 | 690 | %attr(755,root,root) %{dstdir}/bin/jjs |
2692550d | 691 | %attr(755,root,root) %{dstdir}/bin/jrunscript |
3899c70b | 692 | %attr(755,root,root) %{dstdir}/bin/keytool |
3899c70b | 693 | %attr(755,root,root) %{dstdir}/bin/orbd |
3899c70b | 694 | %attr(755,root,root) %{dstdir}/bin/pack200 |
3899c70b | 695 | %attr(755,root,root) %{dstdir}/bin/rmid |
3899c70b | 696 | %attr(755,root,root) %{dstdir}/bin/rmiregistry |
3899c70b | 697 | %attr(755,root,root) %{dstdir}/bin/servertool |
3899c70b | 698 | %attr(755,root,root) %{dstdir}/bin/tnameserv |
3899c70b | 699 | %attr(755,root,root) %{dstdir}/bin/unpack200 |
2692550d JP |
700 | %{dstdir}/conf |
701 | %{dstdir}/legal | |
702 | %dir %{dstdir}/lib | |
703 | %dir %{dstdir}/lib/jli | |
704 | %attr(755,root,root) %{dstdir}/lib/jli/libjli.so | |
705 | %{dstdir}/lib/security | |
706 | %dir %{dstdir}/lib/server | |
707 | %attr(755,root,root) %{dstdir}/lib/server/*.so | |
708 | %{dstdir}/lib/server/Xusage.txt | |
161e81b6 | 709 | %{!?with_zero:%{dstdir}/lib/classlist} |
2692550d JP |
710 | %{dstdir}/lib/jrt-fs.jar |
711 | %{dstdir}/lib/jvm.cfg | |
712 | %attr(755,root,root) %{dstdir}/lib/libattach.so | |
713 | %attr(755,root,root) %{dstdir}/lib/libawt.so | |
714 | %attr(755,root,root) %{dstdir}/lib/libawt_headless.so | |
715 | %attr(755,root,root) %{dstdir}/lib/libdt_socket.so | |
716 | %attr(755,root,root) %{dstdir}/lib/libinstrument.so | |
717 | %attr(755,root,root) %{dstdir}/lib/libj2gss.so | |
718 | %attr(755,root,root) %{dstdir}/lib/libj2pcsc.so | |
719 | %attr(755,root,root) %{dstdir}/lib/libj2pkcs11.so | |
720 | %attr(755,root,root) %{dstdir}/lib/libjaas_unix.so | |
721 | %attr(755,root,root) %{dstdir}/lib/libjava.so | |
722 | %attr(755,root,root) %{dstdir}/lib/libjimage.so | |
723 | %attr(755,root,root) %{dstdir}/lib/liblcms.so | |
724 | %attr(755,root,root) %{dstdir}/lib/libmanagement_agent.so | |
725 | %attr(755,root,root) %{dstdir}/lib/libmanagement_ext.so | |
726 | %attr(755,root,root) %{dstdir}/lib/libprefs.so | |
727 | %attr(755,root,root) %{dstdir}/lib/librmi.so | |
728 | %attr(755,root,root) %{dstdir}/lib/libsctp.so | |
729 | %attr(755,root,root) %{dstdir}/lib/libsunec.so | |
730 | %attr(755,root,root) %{dstdir}/lib/libjavajpeg.so | |
731 | %attr(755,root,root) %{dstdir}/lib/libjdwp.so | |
732 | %attr(755,root,root) %{dstdir}/lib/libjsig.so | |
733 | %attr(755,root,root) %{dstdir}/lib/libjsound.so | |
734 | %attr(755,root,root) %{dstdir}/lib/libmanagement.so | |
735 | %attr(755,root,root) %{dstdir}/lib/libmlib_image.so | |
736 | %attr(755,root,root) %{dstdir}/lib/libnet.so | |
737 | %attr(755,root,root) %{dstdir}/lib/libnio.so | |
74861363 | 738 | %{!?with_zero:%attr(755,root,root) %{dstdir}/lib/libsaproc.so} |
2692550d JP |
739 | %{?with_sunec:%attr(755,root,root) %{dstdir}/lib/libsunec.so} |
740 | %attr(755,root,root) %{dstdir}/lib/libunpack.so | |
741 | %attr(755,root,root) %{dstdir}/lib/libverify.so | |
742 | %attr(755,root,root) %{dstdir}/lib/libzip.so | |
743 | %attr(755,root,root) %{dstdir}/lib/jexec | |
744 | %{dstdir}/lib/modules | |
745 | %{dstdir}/lib/psfont.properties.ja | |
746 | %{dstdir}/lib/psfontj2d.properties | |
747 | %{dstdir}/lib/tzdb.dat | |
3899c70b JK |
748 | %{jvmjardir} |
749 | ||
750 | %files jre-X11 | |
751 | %defattr(644,root,root,755) | |
752 | %attr(755,root,root) %{_bindir}/policytool | |
753 | %{_mandir}/man1/policytool.1* | |
754 | %lang(ja) %{_mandir}/ja/man1/policytool.1* | |
755 | ||
756 | %files jre-base-X11 | |
757 | %defattr(644,root,root,755) | |
3899c70b | 758 | %attr(755,root,root) %{dstdir}/bin/policytool |
2692550d JP |
759 | %attr(755,root,root) %{dstdir}/lib/libsplashscreen.so |
760 | %attr(755,root,root) %{dstdir}/lib/libawt_xawt.so | |
761 | %attr(755,root,root) %{dstdir}/lib/libjawt.so | |
3899c70b JK |
762 | |
763 | %files jre-base-alsa | |
764 | %defattr(644,root,root,755) | |
2692550d | 765 | %attr(755,root,root) %{dstdir}/lib/libjsoundalsa.so |
3899c70b JK |
766 | |
767 | %files jre-base-freetype | |
768 | %defattr(644,root,root,755) | |
2692550d | 769 | %attr(755,root,root) %{dstdir}/lib/libfontmanager.so |
3899c70b JK |
770 | |
771 | %files jar | |
772 | %defattr(644,root,root,755) | |
773 | %attr(755,root,root) %{_bindir}/jar | |
774 | %{_mandir}/man1/jar.1* | |
775 | %lang(ja) %{_mandir}/ja/man1/jar.1* | |
776 | ||
777 | %files appletviewer | |
778 | %defattr(644,root,root,755) | |
779 | %attr(755,root,root) %{_bindir}/appletviewer | |
780 | %{_mandir}/man1/appletviewer.1* | |
781 | %lang(ja) %{_mandir}/ja/man1/appletviewer.1* | |
782 | ||
783 | %files jdk-sources | |
784 | %defattr(644,root,root,755) | |
785 | %{_javasrcdir}/%{name}-jdk.zip | |
786 | ||
787 | %files examples | |
788 | %defattr(644,root,root,755) | |
789 | %{_examplesdir}/%{name}-%{version} |