Opened 14 years ago

Closed 12 years ago

#27048 closed defect (worksforme)

swi-prolog build failure: "cannot find java include files"

Reported by: anthony.hw.kong@… Owned by: J.Wielemaker@…
Priority: Normal Milestone:
Component: ports Version: 1.9.1
Keywords: lack-of-interest Cc: pmoura (Paulo Moura), gh.xiao@…
Port: swi-prolog

Description (last modified by mf2k (Frank Schima))

From the log file

:info:build checking if java works... yes
:info:build checking for jar... jar
:info:build checking for javadoc... javadoc
:info:build checking for javac... /usr/bin/javac
:info:build checking for javac... (cached) /usr/bin/javac
:info:build checking symlink for /usr/bin/javac... /System/Library/Frameworks/JavaVM.framework/Versions/Current/Commands/javac
:info:build configure: error: cannot find java include files
:info:build make[1]: *** [configure] Error 1
:info:build make: *** [.pkg-config] Error 2
:info:build shell command " cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_lang_swi-prolog/work/pl-5.8.3" && /usr/bin/make all " returned error 2
:error:build Target org.macports.build returned: shell command failed
:debug:build Backtrace: shell command failed
    while executing
"command_exec build"
    (procedure "portbuild::build_main" line 8)
    invoked from within
"$procedure $targetname"

Change History (12)

comment:1 Changed 14 years ago by mf2k (Frank Schima)

Cc: pmoura@… added
Description: modified (diff)
Owner: changed from macports-tickets@… to J.Wielemaker@…
Port: swi-prolog added

comment:2 Changed 14 years ago by pmoura (Paulo Moura)

The error seems to result from an incomplete Java installation, not from a SWI-Prolog issue. Be sure to install both the latest MacOS X Java update and the Java developer package that you can download from Apple's developer web site. Moreover, when reporting problems include details about which MacOS X version are you using.

comment:3 Changed 14 years ago by pmoura (Paulo Moura)

Btw, I have just submitted updated portfiles for both "swi-prolog" and "swi-prolog-devel" ports.

comment:4 Changed 14 years ago by anthony.hw.kong@…

Hi, pmoura,

Thanks for looking into the issue.

I downloaded the Java Developer download form apple. Now I am getting a different set of error messages

=================

:info:build /usr/bin/gcc-4.2 -c -Wall -O2 -g -I. -I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_lang_swi-prolog/work/pl-5.8.3/packages/xpce/src -I/opt/local/include -I/opt/local/include -I/opt/local/include -I/opt/local/include/freetype2 -fno-common -no-cpp-precomp -DHAVE_CONFIG_H x11/xcommon.c -o x11/xcommon.o :info:build In file included from /opt/local/include/X11/extensions/render.h:29, :info:build from /opt/local/include/X11/extensions/Xrender.h:33, :info:build from /opt/local/include/X11/Xft/Xft.h:42, :info:build from x11/include.h:78, :info:build from x11/xcommon.c:28: :info:build /opt/local/include/X11/Xdefs.h:47: error: conflicting types for 'Bool' :info:build ./h/types.h:66: error: previous declaration of 'Bool' was here :info:build x11/xcommon.c:168: error: conflicting types for 'X11ThreadsDisplay' :info:build ./h/wst.h:34: error: previous declaration of 'X11ThreadsDisplay' was here :info:build x11/xcommon.c: In function 'X11ThreadsDisplay': :info:build x11/xcommon.c:171: warning: comparison between pointer and integer :info:build x11/xcommon.c: In function 'CtoEvent': :info:build x11/xcommon.c:910: warning: assignment makes integer from pointer without a cast :info:build make[4]: * [x11/xcommon.o] Error 1 :info:build make[3]: * [dowsobjs] Error 2 :info:build make[2]: * [all] Error 2 :info:build make[1]: * [objects] Error 1 :info:build make: * [packages] Error 2 :info:build shell command " cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_lang_swi-prolog/work/pl-5.8.3" && /usr/bin/make all " returned error 2 :error:build Target org.macports.build returned: shell command failed :debug:build Backtrace: shell command failed

================

Mac OSX version:

from "uname -a"

Darwin mbp002.local 10.4.0 Darwin Kernel Version 10.4.0: Fri Apr 23 18:28:53 PDT 2010; root:xnu-1504.7.4~1/RELEASE_I386 i386

from "About this Mac"

10.6.4

comment:5 Changed 14 years ago by anthony.hw.kong@…

Repost the error messages in proper wiki format


:info:build /usr/bin/gcc-4.2 -c -Wall -O2 -g  -I. -I/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_lang_swi-prolog/work/pl-5.8.3/packages/xpce/src -I/opt/local/include  -I/opt/local/include -I/opt/local/include -I/opt/local/include/freetype2   -fno-common -no-cpp-precomp -DHAVE_CONFIG_H x11/xcommon.c -o x11/xcommon.o
:info:build In file included from /opt/local/include/X11/extensions/render.h:29,
:info:build                  from /opt/local/include/X11/extensions/Xrender.h:33,
:info:build                  from /opt/local/include/X11/Xft/Xft.h:42,
:info:build                  from x11/include.h:78,
:info:build                  from x11/xcommon.c:28:
:info:build /opt/local/include/X11/Xdefs.h:47: error: conflicting types for 'Bool'
:info:build ./h/types.h:66: error: previous declaration of 'Bool' was here
:info:build x11/xcommon.c:168: error: conflicting types for 'X11ThreadsDisplay'
:info:build ./h/wst.h:34: error: previous declaration of 'X11ThreadsDisplay' was here
:info:build x11/xcommon.c: In function 'X11ThreadsDisplay':
:info:build x11/xcommon.c:171: warning: comparison between pointer and integer
:info:build x11/xcommon.c: In function 'CtoEvent':
:info:build x11/xcommon.c:910: warning: assignment makes integer from pointer without a cast
:info:build make[4]: *** [x11/xcommon.o] Error 1
:info:build make[3]: *** [dowsobjs] Error 2
:info:build make[2]: *** [all] Error 2
:info:build make[1]: *** [objects] Error 1
:info:build make: *** [packages] Error 2
:info:build shell command " cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_release_ports_lang_swi-prolog/work/pl-5.8.3" && /usr/bin/make all " returned error 2
:error:build Target org.macports.build returned: shell command failed
:debug:build Backtrace: shell command failed
    while executing
"command_exec build"
    (procedure "portbuild::build_main" line 8)
    invoked from within
"$procedure $targetname"
:info:build Warning: the following items did not execute (for swi-prolog): org.macports.activate org.macports.build org.macports.destroot org.macports.install
:notice:build Log for swi-prolog is at: /opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_ports_lang_swi-prolog/main.log

comment:6 Changed 14 years ago by pmoura (Paulo Moura)

If I recall correctly, this X11 errors are fixed in later versions of SWI-Prolog. Either wait for the already submitted updated portfiles to be committed or simply use the binary installers available from the SWI-Prolog website.

comment:7 Changed 14 years ago by J.Liem@…

I just tried to install swi-prolog (5.10.2) and swi-prolog-devel (5.11.X) via MacPorts. I get the same missing java headers error in my log files. However, compiling the latests version from git gives no problems.

I'm on Snow Leopard 10.6.4 with all the latest updates installed.

comment:8 Changed 14 years ago by J.Liem@…

Sorry, I was wrong. After a make distclean and a new build attempt I get the same error from the latest git version.

comment:9 Changed 14 years ago by J.Liem@…

Don't know what this 'Java Developer' download is, but the problem on Snow Leopard goes away if you install the latest XCode (3.2.4). Now all versions compile without problem.

You have to be registered as an Apple Developer to be able to download it. http://developer.apple.com/technologies/tools/xcode.html

Both 5.10.2, 5.11.8 and the latest Git version compile without problem.

Perhaps the problems with X11 can be resolved by reinstalling XQuartz? http://xquartz.macosforge.org/trac/wiki

comment:10 Changed 14 years ago by gh.xiao@…

Cc: gh.xiao@… added

Cc Me!

comment:11 Changed 13 years ago by jmroot (Joshua Root)

Is this still an issue with 5.10.5?

comment:12 Changed 12 years ago by neverpanic (Clemens Lang)

Keywords: lack-of-interest added
Resolution: worksforme
Status: newclosed

Closing due to lack of interest.

Note: See TracTickets for help on using tickets.