Ticket #2470 (new defect)

Opened 5 years ago

Last modified 5 years ago

Java bindings: JAVA_INCLUDE broken on windows for JAVA_HOME with spaces

Reported by: mnidel Owned by: aaime
Priority: normal Milestone:
Component: JavaBindings Version: 1.5.2
Severity: normal Keywords:
Cc:

Description

If JAVA_HOME contains spaces, e.g. the default C:\Program Files\Java..., the JAVA_INCLUDE will not properly quote the path and the included .h files will not be found during the JNI DLL build.

The fix is to modify the following line:

JAVA_INCLUDE=-I$(JAVA_HOME)\include -I$(JAVA_HOME)\include\win32

to the following:

JAVA_INCLUDE=-I"$(JAVA_HOME)\include" -I"$(JAVA_HOME)\include\win32"

This solves the problem, which occurs at minimum with GDAL 1.5 branch.

A patch is attached to perform the fix.

Attachments

nmake.opt.patch Download (429 bytes) - added by mnidel 5 years ago.
Patch for GDAL_HOME/nmake.opt

Change History

Changed 5 years ago by mnidel

Patch for GDAL_HOME/nmake.opt

Changed 5 years ago by mnidel

Forgot to mention the fix is for GDAL_HOME/nmake.opt

Note: See TracTickets for help on using tickets.