You are right there's no check. One could be added by a motivated party ..
The minimum for Linux may be as old as 1.2.3  but safer is 2.3.1 since we rely on that for AAT font support. I can't (quickly) speak to any important bug fixes in later releases we may need, just API / functionality.

-phi.

On 9/15/21 12:47 PM, Andrew John Hughes wrote:
On Tue, 16 Mar 2021 16:56:22 GMT, Phil Race <p...@openjdk.org> wrote:

 From a build perspective this partially reverts 
https://bugs.openjdk.java.net/browse/JDK-8249821 except that it keeps
the harfbuzz sources separate and still supports building and running against a 
system harfbuzz which is only of interest or relevance on Linux.

I ended up having to go this way because its is the least unsatisfactory 
solution.
I did not want us to build a devkit to link against a system linux only to find 
we couldn't use it at runtime
because too many systems have to old a version of harfbuzz.

This solves the Manjaro Linux problem and I've manually verified building 
against a system hardbuxz on Ubuntu 20.10

There are couple of incidental fixes in here too
- "libharfbuzz" should not have been in the EXTRA_HEADERS var when building 
against a system version
- harfbuzz/hb-ucdn is gone and should not be listed as a header directory 
needed to build the bundled copy
- I expect it also resolves https://bugs.openjdk.java.net/browse/JDK-8262502
Phil Race has updated the pull request incrementally with one additional commit 
since the last revision:

   8255790: GTKL&F: Java 16 crashes on initialising GTKL&F on Manjaro Linux
You mention that "too many systems have to old a version of harfbuzz".
Is the required version defined somewhere? There's no check in configure for 
either a version or a required symbol:
https://github.com/openjdk/jdk/blob/cbffecc61e4a9ac1172926ef4f20d918d73adde9/make/autoconf/lib-bundled.m4#L291

With undefined symbols also being left to runtime (hence why JDK-8272332 
doesn't show up during build), it seems this could lead to sporadic runtime 
failures if OpenJDK is unknowingly built against a harfbuzz that is too old.

-------------

PR: https://git.openjdk.java.net/jdk/pull/2982

Reply via email to