]>
Commit | Line | Data |
---|---|---|
3899c70b JK |
1 | # |
2 | # TODO: | |
5b4e4f20 | 3 | # - use the release snapshots (the jdk8u repo?) instead of latest 'b' tag |
3899c70b JK |
4 | # - make it build |
5 | # - make it install | |
6 | # - fix BuildRequires | |
5b4e4f20 | 7 | # - fix build with system giflib |
3899c70b JK |
8 | # |
9 | ||
10 | %bcond_with bootstrap # build a bootstrap version, using icedtea6 | |
11 | %bcond_without cacerts # don't include the default CA certificates | |
12 | ||
13 | %if %{with bootstrap} | |
14 | %define use_jdk icedtea7 | |
15 | %else | |
16 | %define use_jdk openjdk8 | |
17 | %endif | |
18 | ||
19 | # class data version seen with file(1) that this jvm is able to load | |
20 | %define _classdataversion 51.0 | |
21 | ||
22 | Summary: Open-source implementation of the Java Platform, Standard Edition | |
23 | Summary(pl.UTF-8): Wolnoźródłowa implementacja Java 8 SE | |
24 | Name: openjdk8 | |
25 | %define minor 132 | |
26 | Version: 1.8.0.%{minor} | |
27 | Release: 0.1 | |
28 | License: GPL v2 | |
29 | Group: Development/Languages/Java | |
30 | Source0: openjdk8-b%{minor}.tar.bz2 | |
31 | # Source0-md5: 7ae143bc2b840f1bfbfa15a1dcbcc371 | |
32 | Source1: openjdk8-corba-b%{minor}.tar.bz2 | |
33 | # Source1-md5: a54c4b046d4f9b7dc0e64b79b734d2f3 | |
34 | Source2: openjdk8-hotspot-b%{minor}.tar.bz2 | |
35 | # Source2-md5: 1368abb3e02079bb7cd802d2bef136b4 | |
36 | Source3: openjdk8-jaxp-b%{minor}.tar.bz2 | |
37 | # Source3-md5: dccca275bad921fc036221ba36f9596e | |
38 | Source4: openjdk8-jaxws-b%{minor}.tar.bz2 | |
39 | # Source5-md5: faf2d077d9c41a8c11a2b038fb5d2e50 | |
40 | Source5: openjdk8-jdk-b%{minor}.tar.bz2 | |
41 | # Source5-md5: a14e4f9a26a229fdc59dc77cf9754fee | |
42 | Source6: openjdk8-langtools-b%{minor}.tar.bz2 | |
43 | # Source6-md5: 6f6dd27e4ca48a49c0c2ec16310c44f3 | |
44 | Source7: openjdk8-nashorn-b%{minor}.tar.bz2 | |
45 | # Source7-md5: 19581a68b0ffa30d8a23f384fcb8c91d | |
46 | Source10: make-cacerts.sh | |
5b4e4f20 JK |
47 | Patch0: adjust-mflags.patch |
48 | Patch1: format_strings.patch | |
3899c70b JK |
49 | URL: http://openjdk.java.net/ |
50 | BuildRequires: alsa-lib-devel | |
51 | BuildRequires: ant | |
52 | BuildRequires: autoconf | |
53 | BuildRequires: automake | |
54 | BuildRequires: bash | |
55 | %{?with_cacerts:BuildRequires: ca-certificates-update} | |
56 | BuildRequires: cups-devel | |
57 | BuildRequires: /usr/bin/jar | |
58 | BuildRequires: freetype-devel >= 2.3 | |
59 | BuildRequires: gawk | |
5b4e4f20 | 60 | #BuildRequires: giflib-devel >= 5.1 |
3899c70b | 61 | BuildRequires: glibc-misc |
3899c70b | 62 | %buildrequires_jdk |
3899c70b | 63 | BuildRequires: libjpeg-devel |
3899c70b JK |
64 | BuildRequires: lsb-release |
65 | BuildRequires: pkgconfig | |
66 | BuildRequires: rpmbuild(macros) >= 1.557 | |
3899c70b JK |
67 | BuildRequires: unzip |
68 | BuildRequires: util-linux | |
69 | BuildRequires: xorg-lib-libX11-devel | |
70 | BuildRequires: xorg-lib-libXinerama-devel | |
71 | BuildRequires: xorg-lib-libXp-devel | |
72 | BuildRequires: xorg-lib-libXrender-devel | |
73 | BuildRequires: xorg-lib-libXt-devel | |
74 | BuildRequires: xorg-lib-libXtst-devel | |
75 | BuildRequires: xorg-proto-printproto-devel | |
76 | BuildRequires: xorg-proto-xproto-devel | |
77 | BuildRequires: zip | |
78 | BuildRequires: zlib-devel | |
79 | Requires: %{name}-appletviewer = %{version}-%{release} | |
80 | Requires: %{name}-jdk = %{version}-%{release} | |
81 | Suggests: %{name}-jre-X11 | |
82 | Suggests: icedtea-web | |
83 | Obsoletes: icedtea6 | |
84 | Obsoletes: icedtea7 | |
85 | Obsoletes: java5-sun | |
86 | Obsoletes: java5-sun-jre | |
87 | Obsoletes: java5-sun-jre-jdbc | |
88 | Obsoletes: java5-sun-jre-X11 | |
89 | Obsoletes: java5-sun-tools | |
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 | |
95 | Obsoletes: java-sun-jre-alsa | |
96 | Obsoletes: java-sun-jre-jdbc | |
97 | Obsoletes: java-sun-jre-X11 | |
98 | Obsoletes: java-sun-tools | |
99 | Obsoletes: oracle-java7 | |
100 | Obsoletes: oracle-java7-jre | |
101 | Obsoletes: oracle-java7-jre-alsa | |
102 | Obsoletes: oracle-java7-jre-jdbc | |
103 | Obsoletes: oracle-java7-jre-X11 | |
104 | Obsoletes: oracle-java7-tools | |
105 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
106 | ||
107 | %define dstreldir %{name}-%{version} | |
108 | %define dstdir %{_jvmdir}/%{dstreldir} | |
109 | %define jrereldir %{dstreldir}/jre | |
110 | %define jredir %{_jvmdir}/%{jrereldir} | |
111 | %define jvmjardir %{_jvmjardir}/%{name}-%{version} | |
112 | ||
113 | %ifarch %{x8664} | |
114 | %define jre_arch amd64 | |
115 | %endif | |
116 | %ifarch %{ix86} | |
117 | %define jre_arch i386 | |
118 | %endif | |
119 | %ifarch x32 | |
120 | %define jre_arch x32 | |
121 | %endif | |
122 | ||
123 | # to break artificial subpackage dependency loops | |
124 | %define _noautoreq 'libmawt.so' java\\\\(ClassDataVersion\\\\) | |
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 = %{_version} | |
148 | Provides: jdk = %{_version} | |
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: oracle-java7 | |
158 | Obsoletes: jdk | |
159 | Obsoletes: kaffe | |
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-4 | |
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 = %{_version} | |
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: oracle-java7-jre | |
223 | Obsoletes: 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 = %{_version} | |
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-4 | |
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 | %if "%{_rpmversion}" >= "5" | |
373 | BuildArch: noarch | |
374 | %endif | |
375 | ||
376 | %description jdk-sources | |
377 | Source code for the OpenJDK development kit and Java standard library. | |
378 | ||
379 | %description jdk-sources -l pl.UTF-8 | |
380 | Kod źródłowy narzędzi programistycznych OpenJDK oraz standardowej | |
381 | biblioteki Javy. | |
382 | ||
383 | %package examples | |
384 | Summary: OpenJDK - examples | |
385 | Summary(pl.UTF-8): OpenJDK - przykłady | |
386 | Group: Documentation | |
387 | %if "%{_rpmversion}" >= "5" | |
388 | BuildArch: noarch | |
389 | %endif | |
390 | ||
391 | %description examples | |
392 | Code examples for OpenJDK. | |
393 | ||
394 | %description examples -l pl.UTF-8 | |
395 | Przykłady dla OpenJDK. | |
396 | ||
397 | %prep | |
398 | %setup -qn jdk8-jdk8-b%{minor} -a1 -a2 -a3 -a4 -a5 -a6 -a7 | |
399 | ||
400 | for d in *-jdk8-b* ; do | |
401 | ln -s "$d" "${d%%-jdk8-b*}" | |
402 | done | |
403 | ||
5b4e4f20 JK |
404 | %patch0 -p1 |
405 | %patch1 -p1 | |
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 | ||
414 | unset JAVA_HOME | |
5b4e4f20 | 415 | export SHELL=/bin/bash |
3899c70b JK |
416 | |
417 | mkdir -p build-bin | |
418 | export PATH="$(pwd)/build-bin:$PATH" | |
419 | ||
5b4e4f20 JK |
420 | chmod a+x configure |
421 | ||
422 | %configure \ | |
423 | --with-extra-cflags="%{rpmcflags}" \ | |
424 | --with-extra-cxxflags="%{rpmcxxflags}" \ | |
425 | --with-extra-ldflags="%{rpmldflags}" \ | |
426 | --with-giflib=bundled \ | |
427 | --with-zlib=system | |
428 | ||
429 | specdir="$(dirname build/*-release/spec.gmk)" | |
430 | cat > $specdir/custom-spec.gmk <<EOF | |
431 | SHELL=/bin/bash | |
432 | EOF | |
433 | [ -d tmp-bin ] || ln -s "$specdir/jdk/bin" tmp-bin | |
434 | ||
435 | %{__make} \ | |
436 | LOG=debug | |
3899c70b JK |
437 | |
438 | %{?with_cacerts:%{__sh} %{SOURCE10}} | |
439 | ||
440 | %install | |
441 | rm -rf $RPM_BUILD_ROOT | |
442 | install -d $RPM_BUILD_ROOT{%{_bindir},%{dstdir},%{_mandir}/ja} \ | |
443 | $RPM_BUILD_ROOT{%{jvmjardir},%{_examplesdir}/%{name}-%{version},%{_javasrcdir}} \ | |
444 | $RPM_BUILD_ROOT%{_sysconfdir}/%{name} | |
445 | ||
446 | # install the 'JDK image', it contains the JRE too | |
447 | cp -a openjdk.build/j2sdk-image/* $RPM_BUILD_ROOT%{dstdir} | |
448 | ||
449 | # convenience symlinks without version number | |
450 | ln -s %{dstreldir} $RPM_BUILD_ROOT%{_jvmdir}/%{name} | |
451 | ln -s %{jrereldir} $RPM_BUILD_ROOT%{_jvmdir}/%{name}-jre | |
452 | ||
453 | ln -s %{dstreldir} $RPM_BUILD_ROOT%{_jvmdir}/java | |
454 | ||
455 | # move JDK sources and demo to /usr/src | |
456 | mv $RPM_BUILD_ROOT%{dstdir}/demo $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version} | |
457 | mv $RPM_BUILD_ROOT%{dstdir}/sample $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version} | |
458 | mv $RPM_BUILD_ROOT%{dstdir}/src.zip $RPM_BUILD_ROOT%{_javasrcdir}/%{name}-jdk.zip | |
459 | ||
460 | # move manual pages to its place | |
461 | mv $RPM_BUILD_ROOT%{dstdir}/man/ja_JP.UTF-8/man1 $RPM_BUILD_ROOT%{_mandir}/ja/man1 | |
462 | rmdir $RPM_BUILD_ROOT%{dstdir}/man/ja_JP.UTF-8 | |
463 | rm $RPM_BUILD_ROOT%{dstdir}/man/ja | |
464 | mv $RPM_BUILD_ROOT%{dstdir}/man/man1 $RPM_BUILD_ROOT%{_mandir}/man1 | |
465 | rmdir $RPM_BUILD_ROOT%{dstdir}/man | |
466 | ||
467 | # replace duplicates with symlinks, link to %{_bindir} | |
468 | for path in $RPM_BUILD_ROOT%{dstdir}/bin/*; do | |
469 | filename=$(basename $path) | |
470 | if diff -q "$path" "$RPM_BUILD_ROOT%{jredir}/bin/$filename" > /dev/null; then | |
471 | ln -sf "../jre/bin/$filename" "$path" | |
472 | ln -sf "%{jredir}/bin/$filename" $RPM_BUILD_ROOT%{_bindir} | |
473 | else | |
474 | ln -sf "%{dstdir}/bin/$filename" $RPM_BUILD_ROOT%{_bindir} | |
475 | fi | |
476 | done | |
477 | ln -sf ../jre/lib/jexec $RPM_BUILD_ROOT%{dstdir}/lib/jexec | |
478 | ||
479 | # keep configuration in /etc (not all *.properties go there) | |
480 | for config in management security content-types.properties \ | |
481 | logging.properties net.properties sound.properties; do | |
482 | ||
483 | mv $RPM_BUILD_ROOT%{jredir}/lib/$config $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/$config | |
484 | ln -s %{_sysconfdir}/%{name}/$config $RPM_BUILD_ROOT%{jredir}/lib/$config | |
485 | done | |
486 | ||
487 | ln -sf %{jredir}/lib/jsse.jar $RPM_BUILD_ROOT%{jvmjardir}/jsse.jar | |
488 | ln -sf %{jredir}/lib/jsse.jar $RPM_BUILD_ROOT%{jvmjardir}/jcert.jar | |
489 | ln -sf %{jredir}/lib/jsse.jar $RPM_BUILD_ROOT%{jvmjardir}/jnet.jar | |
490 | ln -sf %{jredir}/lib/jce.jar $RPM_BUILD_ROOT%{jvmjardir}/jce.jar | |
491 | for f in jndi jndi-ldap jndi-cos jndi-rmi jaas jdbc-stdext jdbc-stdext-3.0 \ | |
492 | sasl jaxp_parser_impl jaxp_transform_impl jaxp jmx activation xml-commons-apis \ | |
493 | jndi-dns jndi-rmi; do | |
494 | ln -sf %{jredir}/lib/rt.jar $RPM_BUILD_ROOT%{jvmjardir}/$f.jar | |
495 | done | |
496 | ||
497 | # some apps (like opera) looks for it in different place | |
498 | ln -s server/libjvm.so $RPM_BUILD_ROOT%{jredir}/lib/%{jre_arch}/libjvm.so | |
499 | ||
500 | # uses /usr/share/javazi if present and we require that package | |
501 | %{__rm} -r $RPM_BUILD_ROOT%{jredir}/lib/zi | |
502 | ||
503 | %{__rm} $RPM_BUILD_ROOT%{dstdir}/{,jre/}{ASSEMBLY_EXCEPTION,LICENSE,THIRD_PARTY_README} | |
504 | ||
505 | %{?with_cacerts:install cacerts $RPM_BUILD_ROOT%{_sysconfdir}/%{name}/security} | |
506 | ||
507 | %clean | |
508 | rm -rf $RPM_BUILD_ROOT | |
509 | ||
510 | %files | |
511 | %defattr(644,root,root,755) | |
512 | %doc THIRD_PARTY_README ASSEMBLY_EXCEPTION | |
513 | ||
514 | %files jdk | |
515 | %defattr(644,root,root,755) | |
516 | %attr(755,root,root) %{_bindir}/apt | |
517 | %attr(755,root,root) %{_bindir}/extcheck | |
518 | %attr(755,root,root) %{_bindir}/idlj | |
519 | %attr(755,root,root) %{_bindir}/jarsigner | |
520 | %attr(755,root,root) %{_bindir}/java-rmi.cgi | |
521 | %attr(755,root,root) %{_bindir}/javac | |
522 | %attr(755,root,root) %{_bindir}/javadoc | |
523 | %attr(755,root,root) %{_bindir}/javah | |
524 | %attr(755,root,root) %{_bindir}/javap | |
525 | %attr(755,root,root) %{_bindir}/jcmd | |
526 | %attr(755,root,root) %{_bindir}/jconsole | |
527 | %attr(755,root,root) %{_bindir}/jdb | |
528 | %attr(755,root,root) %{_bindir}/jhat | |
529 | %attr(755,root,root) %{_bindir}/jinfo | |
530 | %attr(755,root,root) %{_bindir}/jmap | |
531 | %attr(755,root,root) %{_bindir}/jps | |
532 | %attr(755,root,root) %{_bindir}/jrunscript | |
533 | %attr(755,root,root) %{_bindir}/jsadebugd | |
534 | %attr(755,root,root) %{_bindir}/jstack | |
535 | %attr(755,root,root) %{_bindir}/jstat | |
536 | %attr(755,root,root) %{_bindir}/jstatd | |
537 | %attr(755,root,root) %{_bindir}/native2ascii | |
538 | %attr(755,root,root) %{_bindir}/rmic | |
539 | %attr(755,root,root) %{_bindir}/schemagen | |
540 | %attr(755,root,root) %{_bindir}/serialver | |
541 | %attr(755,root,root) %{_bindir}/wsgen | |
542 | %attr(755,root,root) %{_bindir}/wsimport | |
543 | %attr(755,root,root) %{_bindir}/xjc | |
544 | %{_jvmdir}/java | |
545 | %{_mandir}/man1/apt.1* | |
546 | %{_mandir}/man1/extcheck.1* | |
547 | %{_mandir}/man1/idlj.1* | |
548 | %{_mandir}/man1/jarsigner.1* | |
549 | %{_mandir}/man1/javac.1* | |
550 | %{_mandir}/man1/javadoc.1* | |
551 | %{_mandir}/man1/javah.1* | |
552 | %{_mandir}/man1/javap.1* | |
553 | %{_mandir}/man1/jcmd.1* | |
554 | %{_mandir}/man1/jconsole.1* | |
555 | %{_mandir}/man1/jdb.1* | |
556 | %{_mandir}/man1/jhat.1* | |
557 | %{_mandir}/man1/jinfo.1* | |
558 | %{_mandir}/man1/jmap.1* | |
559 | %{_mandir}/man1/jps.1* | |
560 | %{_mandir}/man1/jrunscript.1* | |
561 | %{_mandir}/man1/jsadebugd.1* | |
562 | %{_mandir}/man1/jstack.1* | |
563 | %{_mandir}/man1/jstat.1* | |
564 | %{_mandir}/man1/jstatd.1* | |
565 | %{_mandir}/man1/native2ascii.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/apt.1* | |
573 | %lang(ja) %{_mandir}/ja/man1/extcheck.1* | |
574 | %lang(ja) %{_mandir}/ja/man1/idlj.1* | |
575 | %lang(ja) %{_mandir}/ja/man1/jarsigner.1* | |
576 | %lang(ja) %{_mandir}/ja/man1/javac.1* | |
577 | %lang(ja) %{_mandir}/ja/man1/javadoc.1* | |
578 | %lang(ja) %{_mandir}/ja/man1/javah.1* | |
579 | %lang(ja) %{_mandir}/ja/man1/javap.1* | |
580 | %lang(ja) %{_mandir}/ja/man1/jcmd.1* | |
581 | %lang(ja) %{_mandir}/ja/man1/jconsole.1* | |
582 | %lang(ja) %{_mandir}/ja/man1/jdb.1* | |
583 | %lang(ja) %{_mandir}/ja/man1/jhat.1* | |
584 | %lang(ja) %{_mandir}/ja/man1/jinfo.1* | |
585 | %lang(ja) %{_mandir}/ja/man1/jmap.1* | |
586 | %lang(ja) %{_mandir}/ja/man1/jps.1* | |
587 | %lang(ja) %{_mandir}/ja/man1/jrunscript.1* | |
588 | %lang(ja) %{_mandir}/ja/man1/jsadebugd.1* | |
589 | %lang(ja) %{_mandir}/ja/man1/jstack.1* | |
590 | %lang(ja) %{_mandir}/ja/man1/jstat.1* | |
591 | %lang(ja) %{_mandir}/ja/man1/jstatd.1* | |
592 | %lang(ja) %{_mandir}/ja/man1/native2ascii.1* | |
593 | %lang(ja) %{_mandir}/ja/man1/schemagen.1* | |
594 | %lang(ja) %{_mandir}/ja/man1/serialver.1* | |
595 | %lang(ja) %{_mandir}/ja/man1/rmic.1* | |
596 | %lang(ja) %{_mandir}/ja/man1/wsgen.1* | |
597 | %lang(ja) %{_mandir}/ja/man1/wsimport.1* | |
598 | %lang(ja) %{_mandir}/ja/man1/xjc.1* | |
599 | ||
600 | %files jdk-base | |
601 | %defattr(644,root,root,755) | |
602 | %doc openjdk.build/j2sdk-image/THIRD_PARTY_README | |
603 | %doc openjdk.build/j2sdk-image/ASSEMBLY_EXCEPTION | |
604 | %dir %{dstdir} | |
605 | %{_jvmdir}/%{name} | |
606 | %attr(755,root,root) %{dstdir}/bin/appletviewer | |
607 | %attr(755,root,root) %{dstdir}/bin/apt | |
608 | %attr(755,root,root) %{dstdir}/bin/extcheck | |
609 | %attr(755,root,root) %{dstdir}/bin/idlj | |
610 | %attr(755,root,root) %{dstdir}/bin/jar | |
611 | %attr(755,root,root) %{dstdir}/bin/jarsigner | |
612 | %attr(755,root,root) %{dstdir}/bin/java-rmi.cgi | |
613 | %attr(755,root,root) %{dstdir}/bin/javac | |
614 | %attr(755,root,root) %{dstdir}/bin/javadoc | |
615 | %attr(755,root,root) %{dstdir}/bin/javah | |
616 | %attr(755,root,root) %{dstdir}/bin/javap | |
617 | %attr(755,root,root) %{dstdir}/bin/jconsole | |
618 | %attr(755,root,root) %{dstdir}/bin/jcmd | |
619 | %attr(755,root,root) %{dstdir}/bin/jdb | |
620 | %attr(755,root,root) %{dstdir}/bin/jhat | |
621 | %attr(755,root,root) %{dstdir}/bin/jinfo | |
622 | %attr(755,root,root) %{dstdir}/bin/jmap | |
623 | %attr(755,root,root) %{dstdir}/bin/jps | |
624 | %attr(755,root,root) %{dstdir}/bin/jrunscript | |
625 | %attr(755,root,root) %{dstdir}/bin/jsadebugd | |
626 | %attr(755,root,root) %{dstdir}/bin/jstack | |
627 | %attr(755,root,root) %{dstdir}/bin/jstat | |
628 | %attr(755,root,root) %{dstdir}/bin/jstatd | |
629 | %attr(755,root,root) %{dstdir}/bin/native2ascii | |
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 | |
637 | %dir %{dstdir}/lib | |
638 | %{dstdir}/lib/ct.sym | |
639 | %{dstdir}/lib/dt.jar | |
640 | %{dstdir}/lib/ir.idl | |
641 | %{dstdir}/lib/jconsole.jar | |
642 | %attr(755,root,root) %{dstdir}/lib/jexec | |
643 | %{dstdir}/lib/orb.idl | |
644 | %ifnarch x32 | |
645 | %{dstdir}/lib/sa-jdi.jar | |
646 | %endif | |
647 | %{dstdir}/lib/tools.jar | |
648 | %dir %{dstdir}/lib/%{jre_arch} | |
649 | %dir %{dstdir}/lib/%{jre_arch}/jli | |
650 | %attr(755,root,root) %{dstdir}/lib/%{jre_arch}/jli/*.so | |
651 | %{dstdir}/tapset | |
652 | ||
653 | %files jre | |
654 | %defattr(644,root,root,755) | |
655 | %attr(755,root,root) %{_bindir}/java | |
656 | %attr(755,root,root) %{_bindir}/keytool | |
657 | %attr(755,root,root) %{_bindir}/orbd | |
658 | %attr(755,root,root) %{_bindir}/pack200 | |
659 | %attr(755,root,root) %{_bindir}/rmid | |
660 | %attr(755,root,root) %{_bindir}/rmiregistry | |
661 | %attr(755,root,root) %{_bindir}/servertool | |
662 | %attr(755,root,root) %{_bindir}/tnameserv | |
663 | %attr(755,root,root) %{_bindir}/unpack200 | |
664 | %{_mandir}/man1/java.1* | |
665 | %{_mandir}/man1/keytool.1* | |
666 | %{_mandir}/man1/orbd.1* | |
667 | %{_mandir}/man1/pack200.1* | |
668 | %{_mandir}/man1/rmid.1* | |
669 | %{_mandir}/man1/rmiregistry.1* | |
670 | %{_mandir}/man1/servertool.1* | |
671 | %{_mandir}/man1/tnameserv.1* | |
672 | %{_mandir}/man1/unpack200.1* | |
673 | %lang(ja) %{_mandir}/ja/man1/java.1* | |
674 | %lang(ja) %{_mandir}/ja/man1/keytool.1* | |
675 | %lang(ja) %{_mandir}/ja/man1/orbd.1* | |
676 | %lang(ja) %{_mandir}/ja/man1/pack200.1* | |
677 | %lang(ja) %{_mandir}/ja/man1/rmid.1* | |
678 | %lang(ja) %{_mandir}/ja/man1/rmiregistry.1* | |
679 | %lang(ja) %{_mandir}/ja/man1/servertool.1* | |
680 | %lang(ja) %{_mandir}/ja/man1/tnameserv.1* | |
681 | %lang(ja) %{_mandir}/ja/man1/unpack200.1* | |
682 | ||
683 | %files jre-base | |
684 | %defattr(644,root,root,755) | |
685 | %doc openjdk.build/j2sdk-image/THIRD_PARTY_README | |
686 | %doc openjdk.build/j2sdk-image/ASSEMBLY_EXCEPTION | |
687 | %dir %{_sysconfdir}/%{name} | |
688 | %config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/%{name}/* | |
689 | %dir %{dstdir} | |
690 | %{dstdir}/release | |
691 | %dir %{jredir} | |
692 | %{_jvmdir}/%{name}-jre | |
693 | %dir %{jredir}/bin | |
694 | %dir %{dstdir}/bin | |
695 | %attr(755,root,root) %{jredir}/bin/java | |
696 | %attr(755,root,root) %{dstdir}/bin/java | |
697 | %attr(755,root,root) %{jredir}/bin/keytool | |
698 | %attr(755,root,root) %{dstdir}/bin/keytool | |
699 | %attr(755,root,root) %{jredir}/bin/orbd | |
700 | %attr(755,root,root) %{dstdir}/bin/orbd | |
701 | %attr(755,root,root) %{jredir}/bin/pack200 | |
702 | %attr(755,root,root) %{dstdir}/bin/pack200 | |
703 | %attr(755,root,root) %{jredir}/bin/rmid | |
704 | %attr(755,root,root) %{dstdir}/bin/rmid | |
705 | %attr(755,root,root) %{jredir}/bin/rmiregistry | |
706 | %attr(755,root,root) %{dstdir}/bin/rmiregistry | |
707 | %attr(755,root,root) %{jredir}/bin/servertool | |
708 | %attr(755,root,root) %{dstdir}/bin/servertool | |
709 | %attr(755,root,root) %{jredir}/bin/tnameserv | |
710 | %attr(755,root,root) %{dstdir}/bin/tnameserv | |
711 | %attr(755,root,root) %{jredir}/bin/unpack200 | |
712 | %attr(755,root,root) %{dstdir}/bin/unpack200 | |
713 | %dir %{jredir}/lib | |
714 | %dir %{jredir}/lib/applet | |
715 | %{jredir}/lib/cmm | |
716 | %{jredir}/lib/ext | |
717 | %dir %{jredir}/lib/%{jre_arch} | |
718 | %ifnarch %{x8664} x32 | |
719 | %dir %{jredir}/lib/%{jre_arch}/client | |
720 | %{jredir}/lib/%{jre_arch}/client/Xusage.txt | |
721 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/client/*.so | |
722 | %endif | |
723 | %dir %{jredir}/lib/%{jre_arch}/headless | |
724 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/headless/*.so | |
725 | %dir %{jredir}/lib/%{jre_arch}/jli | |
726 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/jli/*.so | |
727 | %dir %{jredir}/lib/%{jre_arch}/server | |
728 | %{jredir}/lib/%{jre_arch}/server/Xusage.txt | |
729 | %ifnarch x32 | |
730 | %{jredir}/lib/%{jre_arch}/server/classes.jsa | |
731 | %endif | |
732 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/server/*.so | |
733 | %{jredir}/lib/%{jre_arch}/jvm.cfg | |
734 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libattach.so | |
735 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libawt.so | |
736 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libdt_socket.so | |
737 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libhprof.so | |
738 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libinstrument.so | |
739 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libj2gss.so | |
740 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libj2krb5.so | |
741 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libj2pcsc.so | |
742 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libj2pkcs11.so | |
743 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libjaas_unix.so | |
744 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libjava.so | |
745 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libjavajpeg.so | |
746 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libjavalcms.so | |
747 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libjavasctp.so | |
748 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libjava_crw_demo.so | |
749 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libjawt.so | |
750 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libjdwp.so | |
751 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libjsdt.so | |
752 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libjsig.so | |
753 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libjsound.so | |
754 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libjvm.so | |
755 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libmanagement.so | |
756 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libmlib_image.so | |
757 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libnet.so | |
758 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libnio.so | |
759 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libnpt.so | |
760 | %ifnarch x32 | |
761 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libsaproc.so | |
762 | %endif | |
763 | %{?with_sunec:%attr(755,root,root) %{jredir}/lib/%{jre_arch}/libsunec.so} | |
764 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libunpack.so | |
765 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libverify.so | |
766 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libzip.so | |
767 | %{jredir}/lib/images | |
768 | %{jredir}/lib/management | |
769 | %{jredir}/lib/security | |
770 | ||
771 | %if %{with webstart} | |
772 | %{jredir}/lib/about.jar | |
773 | %{jredir}/lib/about.jnlp | |
774 | %endif | |
775 | %{jredir}/lib/calendars.properties | |
776 | %{jredir}/lib/charsets.jar | |
777 | %{jredir}/lib/classlist | |
778 | %{jredir}/lib/content-types.properties | |
779 | %{jredir}/lib/currency.data | |
780 | %{jredir}/lib/flavormap.properties | |
781 | %{jredir}/lib/fontconfig.* | |
782 | %{jredir}/lib/jce.jar | |
783 | %attr(755, root, root) %{jredir}/lib/jexec | |
784 | %{jredir}/lib/jsse.jar | |
785 | %{jredir}/lib/jvm.hprof.txt | |
786 | %{jredir}/lib/logging.properties | |
787 | %{jredir}/lib/management-agent.jar | |
788 | %{jredir}/lib/meta-index | |
789 | %{jredir}/lib/net.properties | |
790 | %{jredir}/lib/psfont.properties.ja | |
791 | %{jredir}/lib/psfontj2d.properties | |
792 | %{jredir}/lib/resources.jar | |
793 | %{jredir}/lib/rhino.jar | |
794 | %{jredir}/lib/rt.jar | |
795 | %{jredir}/lib/sound.properties | |
796 | %{jredir}/lib/tz.properties | |
797 | %{jvmjardir} | |
798 | ||
799 | %files jre-X11 | |
800 | %defattr(644,root,root,755) | |
801 | %attr(755,root,root) %{_bindir}/policytool | |
802 | %{_mandir}/man1/policytool.1* | |
803 | %lang(ja) %{_mandir}/ja/man1/policytool.1* | |
804 | ||
805 | %files jre-base-X11 | |
806 | %defattr(644,root,root,755) | |
807 | %attr(755,root,root) %{jredir}/bin/policytool | |
808 | %attr(755,root,root) %{dstdir}/bin/policytool | |
809 | %dir %{jredir}/lib/%{jre_arch}/xawt | |
810 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/xawt/*.so | |
811 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libsplashscreen.so | |
812 | ||
813 | %files jre-base-alsa | |
814 | %defattr(644,root,root,755) | |
815 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libjsoundalsa.so | |
816 | ||
817 | %files jre-base-freetype | |
818 | %defattr(644,root,root,755) | |
819 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libfontmanager.so | |
820 | ||
821 | %files jre-base-gtk | |
822 | %defattr(644,root,root,755) | |
823 | %attr(755,root,root) %{jredir}/lib/%{jre_arch}/libjavagtk.so | |
824 | ||
825 | %files jar | |
826 | %defattr(644,root,root,755) | |
827 | %attr(755,root,root) %{_bindir}/jar | |
828 | %{_mandir}/man1/jar.1* | |
829 | %lang(ja) %{_mandir}/ja/man1/jar.1* | |
830 | ||
831 | %files appletviewer | |
832 | %defattr(644,root,root,755) | |
833 | %attr(755,root,root) %{_bindir}/appletviewer | |
834 | %{_mandir}/man1/appletviewer.1* | |
835 | %lang(ja) %{_mandir}/ja/man1/appletviewer.1* | |
836 | ||
837 | %files jdk-sources | |
838 | %defattr(644,root,root,755) | |
839 | %{_javasrcdir}/%{name}-jdk.zip | |
840 | ||
841 | %files examples | |
842 | %defattr(644,root,root,755) | |
843 | %{_examplesdir}/%{name}-%{version} |