Hello

Please review this fix for zero vm building on macos.

The issue comes from the libffi, it’s headers are located inside 
usr/include/ffi/ folder in Macos.sdk, so it can’t be found by configure script.

If one wants to use system’s libffi and pass path to libffi via configure 
argument as --with-libffi-include=/usr/include/ffi, then it won’t be found by 
configure because clang will look exactly in /usr/include/ffi, but not in 
macos.sdk
The system, at least on 10.15 doesn’t have /usr/includes at all.

This patch makes jdk to look for ffi/ffi.h header in case of Macos/clang and no 
--with-libffi-include argument.

However there is one issue with this patch, if --with-libffi-include passed 
then c++ code will still try to include <ffi/ffi.h>

I’m not sure which way is the best for such rare case. it could be possible to 
define include filename in configure and pass it via -D and CFLAGS to c++ code.


The webrev - http://cr.openjdk.java.net/~vkempik/8248495/webrev.00/

The bug - https://bugs.openjdk.java.net/browse/JDK-8248495

Thanks, Vladimir

Reply via email to