openJDK7 build fails on 64bit cblfs linux

luxInteg lux-integ at
Sat Apr 16 21:32:19 UTC 2011

On Saturday 16 April 2011 17:00:55 Kelly O'Hair wrote:
> The Linux 64bit system I have (Fedora 9) has no libiconv libraries, you
> just include iconv.h and use the iconv*() functions, no special linking
> options are needed, e.g. I have never had to use -liconv on the link line
> for the npt library we create in the jdk. (The jdk npt libtrary provises
> native platform transformations of characters for shared libraries loaded
> before JVM initialization, like debugger VM agents and things like hprof.)
> What kind of Linux is this?
> What I suspect is that someone has corralled the iconv*() functions into
> it's own library and now you not only need to include iconv.h, but you
> need to link with -liconv on this system. You should check your man page
> on iconv or iconv_open.
> If the -liconv needs to be added to the link line, we probably cannot add
> that for everyone because it does not exist everywhere.
> You might try
>    make OTHER_LDFLAGS=-liconv
> but that will add it to everyone's link, in the jdk/make/java/npt/Makefile,
> you will need a OTHER_LDFLAGS += -liconv
> after the include of Library.gmk.
> -kto

For and Update:-
I added
OTHER_LDFLAGS += -liconv
at line 61 of jdk/make/java/npt/Makefile

and ran make like so

and this is what resulted
In file included from 
                 from ../../../src/solaris/native/sun/awt/awt_p.h:82,
                 from ../../../src/solaris/native/sun/awt/awt_MToolkit.c:26:
../../../src/solaris/native/sun/awt/../java2d/opengl/J2D_GL/glx.h:69:22: fatal 
error: X11/Xlib.h: No such file or directory
compilation terminated.

the build terminated earlier earlier that when this ix was applied.
AND the system it seems is seen as 'solaris' as opposed to  linux.

advice would be appreciated

More information about the build-dev mailing list