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