<AWT Dev> RFR: Allow using a system installed libpng

Andrew Hughes gnu.andrew at redhat.com
Wed Feb 12 17:47:02 UTC 2014


----- Original Message -----
> On 2014-02-10 18:43, Andrew Hughes wrote:
> > You're already using it:
> >
> > PKG_CHECK_MODULES([LIBFFI], [libffi])
> >
> > Why that's in LIB_SETUP_STATIC_LINK_LIBSTDCPP, I have no idea.
> Because libraries.m4 is in need of a long overdue cleanup. :-(
> >
> >> * Second, I believe the original intention was to allow for a third
> >> option, --with-libX=<dir>, which would point to an location in which the
> >> library is installed, similar to how e.g. --with-alsa works.
> >>
> > Yes, but you don't allow that:
> >
> >      AC_MSG_ERROR([Invalid value for --with-zlib: ${with_zlib}, use
> >      'system' or 'bundled'])
> >
> > so using --with-x is confusing if someone does specify a directory.
> Yes. As I said, that was the original intention -- not the current
> implementation. Once again, the code in libraries.m4 is in dire need of
> some TLC. Getting it in better shape *is* on my agenda, but it tends to
> be pushed down all the time.
> 
> So from my point of view, Omair's patch is good. It provides additional
> value. It does not solve all problems in libraries.m4, nor is it the
> complete answer on how --with-libpng will behave in the future. But it
> is a good step on the way. I'm willing to sponsor the patch. But I won't
> do that if you object to accepting it. (After all, from Oracle's point
> of view there's no real need for this patch.) I'm also not very much
> interested in working out this specific patch to perfection, when the
> whole of libraries.m4 needs so much work. So, it's a bit of "take it or
> leave it".
> 
> To be extremely clear: Andrew, do you object to bringing Omairs patch,
> as it is, into OpenJDK?
> 

Yes.

I can agree with leaving the option format until others are changed too; it
would only make things inconsistent to change it. However, I do object to
hardcoding "-lpng" into the Makefiles. Even if configure doesn't yet use
pkg-config for libpng, it should at least pass LIBPNG_LDFLAGS into the
build, so any future alterations don't have to change the JDK makefiles
again. I'm not sure this current patch would even work here as pkg-config
returns cflags for libpng, which aren't being picked up.

I didn't realise this was in such a bad state, given it's new. I haven't
had chance to look at it in about a year, as my first priority is 6 & 7.

> /Magnus
> 

-- 
Andrew :)

Free Java Software Engineer
Red Hat, Inc. (http://www.redhat.com)

PGP Key: 248BDC07 (https://keys.indymedia.org/)
Fingerprint = EC5A 1F5E C0AD 1D15 8F1F  8F91 3B96 A578 248B DC07




More information about the build-dev mailing list