[rjb-users] doesn't compile in mingw

Roger Pack rogerdpack2 at gmail.com
Fri Oct 2 08:51:15 EDT 2009


> OK, the fastest workaround is setting JAVA_HOME with the win32 short
> path name instead of the long path name.
> ex)
> set JAVA_HOME=C:\Progra~1\Java\jdk1.6.0_13\
>
> This makes mingw happy.

Interesting.
Don't know much about mingw, but here it is:

with just 8.3 filenames:

bash-3.1$ gcc -E -I. -Ic:/ruby18/lib/ruby/1.8/i386-mingw32 -I.
-IC:\PROGRA~1\Java\JDK16~2.0_1\include
-IC:\PROGRA~1\Java\JDK16~2.0_1\include\win32
-g -O2  -IC:\PROGRA~1\Java\JDK16~2.0_1\include
-IC:\PROGRA~1\Java\JDK16~2.0_1\include\win32  conftest.c -o conftest.i
conftest.c:1:17: jni.h: No such file or directory

with dir names in quotes works

bash-3.1$ gcc -E -I. -Ic:/ruby18/lib/ruby/1.8/i386-mingw32 -I.
-IC:\PROGRA~1\Java\JDK16~2.0_1\include
-IC:\PROGRA~1\Java\JDK16~2.0_1\include\win32
-g -O2  -I"C:\PROGRA~1\Java\JDK16~2.0_1\include"
-IC:\PROGRA~1\Java\JDK16~2.0_1\include\win32  conftest.c -o conftest.i
In file included from conftest.c:1:
C:/PROGRA~1/Java/JDK16~2.0_1/include/jni.h:27:20: jni_md.h: No such
file or directory

with dir names using forward slash it works:

bash-3.1$ gcc -E -I. -Ic:/ruby18/lib/ruby/1.8/i386-mingw32 -I.
-IC:\PROGRA~1\Java\JDK16~2.0_1\include
-IC:\PROGRA~1\Java\JDK16~2.0_1\include\win32
-g -O2  -IC:/PROGRA~1/Java/JDK16~2.0_1/include
-IC:\PROGRA~1\Java\JDK16~2.0_1\include\win32  conftest.c -o conftest.i
In file included from conftest.c:1:
C:/PROGRA~1/Java/JDK16~2.0_1/include/jni.h:27:20: jni_md.h: No such
file or directory

If the rjb code is on github I'd be happy to fork it, patch it and
submit a change :)
Thanks!
-r


More information about the rjb-users mailing list