[foreign] RFR 8229122: 4 panama foreign tests fail on Mac OS Mojave

Henry Jen henry.jen at oracle.com
Thu Oct 10 14:50:10 UTC 2019


If we only need /usr/include, that patch is fine. When we need other headers from system Frameworks, we need to use following for jextract instead of -I.

-C -isysroot -C /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk

The actually path should be obtained from `xcrun —show-sdk-path`, but above works after install command line tools.

Cheers,
Henry


> On Aug 7, 2019, at 4:39 AM, sundararajan.athijegannathan at oracle.com wrote:
> 
> Updated again: http://cr.openjdk.java.net/~sundar/8229122/webrev.02/index.html
> 
> PS. JextractToolProviderTest was not using mac test logic.
> 
> Thanks,
> 
> -Sundar
> 
> On 07/08/19 4:01 pm, sundararajan.athijegannathan at oracle.com wrote:
>> Updated: http://cr.openjdk.java.net/~sundar/8229122/webrev.01/index.html
>> 
>> Thanks,
>> 
>> -Sundar
>> 
>> On 07/08/19 2:49 pm, Maurizio Cimadamore wrote:
>>> 
>>> Looks good - a possible improvement would be to define the two constants:
>>> 
>>> inal static boolean macWithNoUsrInclude = System.getProperty("os.name").equals("Mac OS X") &&
>>> + !Files.isDirectory(Paths.get("/usr/include"));
>>> + static final String MAC_INCLUDE_ROOT = "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk";
>>> 
>>> In a standalone interface/class, and then implement/import it from the affected tests, which would avoid the duplicated logic somewhat.
>>> 
>>> Maurizio
>>> 
>>> 
>>> On 07/08/2019 03:02, sundararajan.athijegannathan at oracle.com wrote:
>>>> Please review.
>>>> 
>>>> 4 panama foreign tests fail because /usr/include is missing in Mojave. For now, fixing the tests with explicit -I option for SDK header directory.
>>>> 
>>>> Bug: https://bugs.openjdk.java.net/browse/JDK-8229122
>>>> 
>>>> Webrev: http://cr.openjdk.java.net/~sundar/8229122/webrev.00/
>>>> 
>>>> Thanks,
>>>> 
>>>> -Sundar
>>>> 



More information about the panama-dev mailing list