在CentOS5中构建OpenJDK 9

时间:2019-01-30 01:17:05

标签: java makefile redhat-openjdk

我试图在Centos 5中构建OpenJDK9。我曾经使用过

sh ./configure --disable-warnings-as-errors
make all

我遇到以下错误。

Building target 'all' in configuration 'linux-x86_64-normal-server-release'
/root/jdk9/build/linux-x86_64-normal-server- 
release/support/native/java.base/libjava/io_util_md.o: In function 
`handleSetLength':
/root/jdk9/jdk/src/java.base/unix/native/libjava/io_util_md.c:228: 
undefined reference to `fallocate64'
collect2: ld returned 1 exit status
/usr/bin/objcopy: '/root/jdk9/build/linux-x86_64-normal-server- 
release/support/modules_libs/java.base/libjava.so': No such file
gmake[3]: *** [/root/jdk9/build/linux-x86_64-normal-server- 
release/support/modules_libs/java.base/libjava.so] Error 1
gmake[2]: *** [java.base-libs] Error 2

ERROR: Build failed for target 'all' in configuration 'linux-x86_64-normal- 
server-release' (exit code 2)

=== Output from failing command(s) repeated here ===
* For target support_native_java.base_libjava_BUILD_LIBJAVA_link:
/root/jdk9/build/linux-x86_64-normal-server- 
release/support/native/java.base/libjava/io_util_md.o: In function 
`handleSetLength':
/root/jdk9/jdk/src/java.base/unix/native/libjava/io_util_md.c:228: 
undefined reference to `fallocate64'
collect2: ld returned 1 exit status

* All command lines available in /root/jdk9/build/linux-x86_64-normal- 
server-release/make-support/failure-logs.
=== End of repeated output ===

No indication of failed target found.
Hint: Try searching the build log for '] Error'.
Hint: See common/doc/building.html#troubleshooting for assistance.

make[1]: *** [main] Error 2
make: *** [all] Error 2

我还尝试了其他make目标,例如make映像和make install。但是仍然出现相同的错误。我的GCC版本是gcc(GCC)4.4.7,我手动安装了它,因为默认情况下Centos 5具有较旧的版本。

0 个答案:

没有答案