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