diff options
author | André Draszik <andre.draszik@jci.com> | 2018-03-06 11:01:53 +0200 |
---|---|---|
committer | Maxin B. John <maxin.john@intel.com> | 2018-03-06 11:03:09 +0200 |
commit | 3668ba76f44bc778ba4446236088c22948a644d0 (patch) | |
tree | cc3291774f0e41350f22a1e5e0196e08f14500a3 /recipes-core/openjdk/patches-openjdk-8/musl-0001-hotspot-stop-using-obsolete-isnanf.patch | |
parent | f8be3065f7c5dbd73516394c0bcd2c7ba1777abf (diff) | |
download | meta-java-3668ba76f44bc778ba4446236088c22948a644d0.tar.gz |
openjdk-8: fix musl build
Add various patches to make it work in musl. Some of them are generic
enough to be applied for all builds, some need to be specific to musl.
Signed-off-by: André Draszik <andre.draszik@jci.com>
Signed-off-by: Maxin B. John <maxin.john@intel.com>
Diffstat (limited to 'recipes-core/openjdk/patches-openjdk-8/musl-0001-hotspot-stop-using-obsolete-isnanf.patch')
-rw-r--r-- | recipes-core/openjdk/patches-openjdk-8/musl-0001-hotspot-stop-using-obsolete-isnanf.patch | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/recipes-core/openjdk/patches-openjdk-8/musl-0001-hotspot-stop-using-obsolete-isnanf.patch b/recipes-core/openjdk/patches-openjdk-8/musl-0001-hotspot-stop-using-obsolete-isnanf.patch new file mode 100644 index 0000000..e165170 --- /dev/null +++ b/recipes-core/openjdk/patches-openjdk-8/musl-0001-hotspot-stop-using-obsolete-isnanf.patch | |||
@@ -0,0 +1,42 @@ | |||
1 | From 1624e2dd3739fe208efa13b31abf4bc53ae2e5c1 Mon Sep 17 00:00:00 2001 | ||
2 | From: =?UTF-8?q?Andr=C3=A9=20Draszik?= <andre.draszik at jci.com <https://lists.yoctoproject.org/listinfo/yocto>> | ||
3 | Date: Tue, 27 Feb 2018 11:24:44 +0000 | ||
4 | Subject: [PATCH 1/9] hotspot: stop using obsolete isnanf() | ||
5 | MIME-Version: 1.0 | ||
6 | Content-Type: text/plain; charset=UTF-8 | ||
7 | Content-Transfer-Encoding: 8bit | ||
8 | |||
9 | Compiling against musl-libc gives the following error: | ||
10 | | hotspot/src/share/vm/utilities/globalDefinitions_gcc.hpp: In function 'int g_isnan(float)': | ||
11 | | hotspot/src/share/vm/utilities/globalDefinitions_gcc.hpp:238:39: error: 'isnanf' was not declared in this scope | ||
12 | | inline int g_isnan(float f) { return isnanf(f); } | ||
13 | | ^~~~~~ | ||
14 | |||
15 | isnanf() is obsolete, and musl doesn't implement it. isnan() | ||
16 | is the right thing to use for all types (float and double), | ||
17 | replacing isnanf(), even on glibc. | ||
18 | |||
19 | Do so. | ||
20 | |||
21 | Upstream-Status: Pending | ||
22 | Signed-off-by: André Draszik <andre.draszik at jci.com <https://lists.yoctoproject.org/listinfo/yocto>> | ||
23 | --- | ||
24 | hotspot/src/share/vm/utilities/globalDefinitions_gcc.hpp | 2 +- | ||
25 | 1 file changed, 1 insertion(+), 1 deletion(-) | ||
26 | |||
27 | diff --git a/hotspot/src/share/vm/utilities/globalDefinitions_gcc.hpp b/hotspot/src/share/vm/utilities/globalDefinitions_gcc.hpp | ||
28 | index efa0b4e1..6df2302e 100644 | ||
29 | --- a/hotspot/src/share/vm/utilities/globalDefinitions_gcc.hpp | ||
30 | +++ b/hotspot/src/share/vm/utilities/globalDefinitions_gcc.hpp | ||
31 | @@ -235,7 +235,7 @@ inline int g_isnan(double f) { return isnand(f); } | ||
32 | #elif defined(__APPLE__) | ||
33 | inline int g_isnan(double f) { return isnan(f); } | ||
34 | #elif defined(LINUX) || defined(_ALLBSD_SOURCE) | ||
35 | -inline int g_isnan(float f) { return isnanf(f); } | ||
36 | +inline int g_isnan(float f) { return isnan(f); } | ||
37 | inline int g_isnan(double f) { return isnan(f); } | ||
38 | #else | ||
39 | #error "missing platform-specific definition here" | ||
40 | -- | ||
41 | 2.16.2 | ||
42 | |||