Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 148677

Summary: media-gfx/graphviz-2.8-r1 fails to compile with dev-lang/ocaml-3.09.3
Product: Gentoo Linux Reporter: spiralvoice <spiralvoice>
Component: New packagesAssignee: Gentoo Graphics Project <graphics+disabled>
Status: RESOLVED DUPLICATE    
Severity: normal CC: anakin.skyw, balrogg, cshobe, gseba, jakub, janjitse, pacho, portage, sascha-gentoo-bugzilla, willard.dawson, zerthurd, znmeb
Priority: High    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Bug Depends on: 148733    
Bug Blocks:    
Attachments: graphviz-disable-ocaml.patch
Replacement tclkpkg/gv/gv_ocaml.cpp, bzipped

Description spiralvoice 2006-09-22 10:44:40 UTC
i686-pc-linux-gnu-g++ -DHAVE_CONFIG_H -I. -I. -I../.. -I../.. -I../../lib/gvc -I../../lib/common -I../../lib/graph -I../../lib/cdt -I../../lib/pathplan -I/usr/lib/perl5/5.8.8/i686-linux/CORE -I/usr/lib/ocaml -I/usr/include/php -I/usr/include/php/main -I/usr/include/php/Zend -I/usr/include/php/TSRM -I/usr/include/python2.4 -I/usr/lib/ruby/1.8/i686-linux -march=athlon-xp -Os -fforce-addr -fomit-frame-pointer -ftracer -pipe -fvisibility-inlines-hidden -fno-enforce-eh-specs -c gv_ocaml.cpp  -fPIC -DPIC -o .libs/gv_ocaml.o

gv_ocaml.cpp: In function 'double caml_double_val(caml_value_t)':
gv_ocaml.cpp:1107: warning: converting to 'caml_value_t' from 'double'
gv_ocaml.cpp: In function 'void* caml_ptr_val(caml_value_t, swig_type_info*)':
gv_ocaml.cpp:1163: error: invalid conversion from 'void*' to 'caml_value_t'
gv_ocaml.cpp:1163: error: invalid conversion from 'caml_value_t' to 'void*'
gv_ocaml.cpp: In function 'caml_value_t _wrap_graph__SWIG_0gv(caml_value_t)':
gv_ocaml.cpp:1521: error: 'value' was not declared in this scope
gv_ocaml.cpp:1521: error: expected `;' before 'caml__temp_result'
gv_ocaml.cpp:1521: error: 'caml__temp_result' was not declared in this scope
gv_ocaml.cpp: In function 'caml_value_t _wrap_digraphgv(caml_value_t)':
gv_ocaml.cpp:1550: error: 'value' was not declared in this scope
gv_ocaml.cpp:1550: error: expected `;' before 'caml__temp_result'
gv_ocaml.cpp:1550: error: 'caml__temp_result' was not declared in this scope
gv_ocaml.cpp: In function 'caml_value_t _wrap_strictgraphgv(caml_value_t)':
gv_ocaml.cpp:1579: error: 'value' was not declared in this scope
gv_ocaml.cpp:1579: error: expected `;' before 'caml__temp_result'
gv_ocaml.cpp:1579: error: 'caml__temp_result' was not declared in this scope
[...]
make[3]: *** [gv_ocaml.lo] Error 1
make[3]: *** Waiting for unfinished jobs....
make[3]: Leaving directory `/var/tmp/portage/graphviz-2.8-r1/work/graphviz-2.8/tclpkg/gv'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/var/tmp/portage/graphviz-2.8-r1/work/graphviz-2.8/tclpkg'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/var/tmp/portage/graphviz-2.8-r1/work/graphviz-2.8'

# ocamlc -v
The Objective Caml compiler, version 3.09.3
Standard library directory: /usr/lib/ocaml

# emerge --info
Portage 2.1.2_pre1 (default-linux/x86/2006.0, gcc-4.1.1/vanilla, glibc-2.4-r3, 2.6.18-gentoo i686)
=================================================================
System uname: 2.6.18-gentoo i686 AMD Athlon(tm) XP 2600+
Gentoo Base System version 1.12.5
Last Sync: Fri, 22 Sep 2006 16:50:01 +0000
ccache version 2.4 [disabled]
app-admin/eselect-compiler: 2.0.0_rc2-r1
dev-java/java-config: 1.3.7, 2.0.29
dev-lang/python:     2.4.3-r3
dev-python/pycrypto: 2.0.1-r5
dev-util/ccache:     2.4-r6
dev-util/confcache:  [Not Present]
sys-apps/sandbox:    1.2.18.1
sys-devel/autoconf:  2.13, 2.60
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2
sys-devel/binutils:  2.17
sys-devel/gcc-config: 1.3.13-r3
sys-devel/libtool:   1.5.22
virtual/os-headers:  2.6.17-r1
ACCEPT_KEYWORDS="x86 ~x86"
AUTOCLEAN="yes"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-march=athlon-xp -Os -fforce-addr -fomit-frame-pointer -ftracer -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/X11/xkb /usr/share/config"
CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/eselect/compiler /etc/gconf /etc/java-config/vms/ /etc/revdep-rebuild /etc/terminfo"
CXXFLAGS="-march=athlon-xp -Os -fforce-addr -fomit-frame-pointer -ftracer -pipe -fvisibility-inlines-hidden -fno-enforce-eh-specs"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoconfig distlocks metadata-transfer parallel-fetch sandbox sfperms strict"
GENTOO_MIRRORS="http://pandemonium.tiscali.de/pub/gentoo http://gentoo.inode.at http://linux.rz.ruhr-uni-bochum.de/download/gentoo-mirror http://gentoo.osuosl.org http://www.mirrorservice.org/sites/www.ibiblio.org/gentoo http://www.ibiblio.org/pub/Linux/distributions/gentoo"
LANG="de_DE.utf8"
LC_ALL="de_DE.utf8"
LDFLAGS="-Wl,-O1 -Wl,--sort-common"
LINGUAS="de"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --delete-after --stats --timeout=180 --exclude='/distfiles' --exclude='/local' --exclude='/packages'"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage"
SYNC="rsync://rsync.europe.gentoo.org/gentoo-portage"
USE="x86 3dnow 3dnowext X aac acpi alsa arts asf automount berkdb bitmap-fonts bzip2 cairo cddb cdparanoia cdr cli cups dbus dlloader dri dvd dvdr dvdread eds elibc_glibc emboss encode ffmpeg firefox flac fontconfig foomaticdb fortran ftp gdbm gif glitz gmp gnokii gpm graphviz gs gtk gtk2 hal howl idn ieee1394 imagemagick imap imlib input_devices_joystick input_devices_keyboard input_devices_mouse isdnlog jbig joystick jpeg jpeg2k kde kdeenablefinal kdehiddenvisibility kernel_linux lame lcms libg++ libwww linguas_de lzo mad matroska mbox mhash mikmod mmx mng mozilla mozsvg mp3 mpeg mplayer musepack ncurses nls normalize nptl nptlonly nsplugin nvidia ogg openexr opengl oss pam pcre perl pic png ppds pppd qt qt3 quicktime readline real reflection samba session slp sndfile spell spl sse ssl svg tcpd theora threads tiff truetype truetype-fonts type1-fonts udev unicode usb userland_GNU v4l vcd video_cards_nv video_cards_nvidia video_cards_v4l vorbis win32codecs wmf wxwindows xine xinerama xml xorg xv xvid zlib zvbi"
Unset:  CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, PORTAGE_RSYNC_EXTRA_OPTS
Comment 1 UncleOwen 2006-09-22 13:16:08 UTC
Just wanted to add a 'me 2' here. Same error.

media-gfx/graphviz-2.8-r1, dev-lang/ocaml-3.09.3

$ emerge --info
Portage 2.1.2_pre1 (default-linux/amd64/2006.1/desktop, gcc-4.1.1, glibc-2.4-r3, 2.6.17-gentoo-r8-20060912 x86_64)
=================================================================
System uname: 2.6.17-gentoo-r8-20060912 x86_64 AMD Athlon(tm) 64 Processor 3700+
Gentoo Base System version 1.12.5
Last Sync: Fri, 22 Sep 2006 10:20:01 +0000
app-admin/eselect-compiler: [Not Present]
dev-java/java-config: 1.3.7, 2.0.29
dev-lang/python:     2.4.3-r3
dev-python/pycrypto: 2.0.1-r5
dev-util/ccache:     [Not Present]
dev-util/confcache:  [Not Present]
sys-apps/sandbox:    1.2.18.1
sys-devel/autoconf:  2.13, 2.60
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2
sys-devel/binutils:  2.17
sys-devel/gcc-config: 1.3.13-r3
sys-devel/libtool:   1.5.22
virtual/os-headers:  2.6.17-r1
ACCEPT_KEYWORDS="amd64 ~amd64"
AUTOCLEAN="yes"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -march=k8 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/kde/3.5/env /usr/kde/3.5/share/config /usr/kde/3.5/shutdown /usr/share/X11/xkb /usr/share/config"
CONFIG_PROTECT_MASK="/etc/env.d /etc/env.d/java/ /etc/gconf /etc/java-config/vms/ /etc/revdep-rebuild /etc/terminfo /etc/texmf/web2c"
CXXFLAGS="-O2 -march=k8 -pipe"
DISTDIR="/usr/portage/distfiles"
EMERGE_DEFAULT_OPTS="--alphabetical"
FEATURES="autoconfig candy distlocks metadata-transfer parallel-fetch sandbox sfperms strict userpriv userpriv_fakeroot usersandbox"
GENTOO_MIRRORS="http://linux.rz.ruhr-uni-bochum.de/download/gentoo-mirror/"
LANG="en_US.utf8"
LC_ALL="en_US.utf8"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --delete-after --stats --timeout=180 --exclude='/distfiles' --exclude='/local' --exclude='/packages'"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/usr/local/portage/local"
SYNC="rsync://rsync.de.gentoo.org/gentoo-portage"
USE="amd64 X alsa avi bitmap-fonts bzip2 cairo cdinstall cdr cjk cli crypt cups dbus dlloader dri dvb dvd dvdr elibc_glibc emboss encode fam firefox fortran gif gpm gstreamer gtk gtk2 hal input_devices_keyboard input_devices_mouse ipv6 isdnlog jpeg kde kdeenablefinal kernel_linux ldap libg++ mad mikmod mp3 mpeg mplayer ncurses nls nptl nptlonly nvidia ogg opengl pam pcre pdflib perl png ppds pppd python qt3 quicktime readline reflection sdl session spell spl ssl tcpd truetype truetype-fonts type1-fonts udev unicode userland_GNU userlocales video_cards_nv video_cards_vga vorbis xine xml xorg xv zlib"
Unset:  CTARGET, INSTALL_MASK, LDFLAGS, LINGUAS, PORTAGE_RSYNC_EXTRA_OPTS
Comment 2 Jakub Moc (RETIRED) gentoo-dev 2006-09-22 15:41:15 UTC
*** Bug 148709 has been marked as a duplicate of this bug. ***
Comment 3 Jakub Moc (RETIRED) gentoo-dev 2006-09-22 15:42:11 UTC
Someone should kill the automagic dependency.
Comment 4 UncleOwen 2006-09-22 16:05:03 UTC
Created attachment 97802 [details, diff]
graphviz-disable-ocaml.patch

Like this? Someone should probably do the same for all the other language bindings (or, better: add USE flags for them), but this fixes the immediate problem.
Comment 5 M. Edward Borasky 2006-10-29 15:40:01 UTC
Still broken on graphviz-2.8-r2. However, setting -ocaml USE flag lets it emerge successfully. 

Is this an ebuild problem or an upstream problem??
Comment 6 Jakub Moc (RETIRED) gentoo-dev 2006-12-07 14:00:14 UTC
*** Bug 157468 has been marked as a duplicate of this bug. ***
Comment 7 Andrzej Zaborowski 2006-12-09 17:25:44 UTC
Confirming that media-gfx/graphviz-2.8-r2 is still broken when "ocaml" is in USE with same error message. After looking at it I'm convinced that the graphviz code is correct and it's dev-lang/swig that's broken, putting a CAMLreturn() where there should be a return and doing other nasty things. In this case the only valid fix is ignore "ocaml" from USE and hardcode --disable-ocaml like the patch in the attachment does. It's a dev-lang/swig upstream problem.
Comment 8 M. Edward Borasky 2006-12-09 19:12:18 UTC
(In reply to comment #7)
> Confirming that media-gfx/graphviz-2.8-r2 is still broken when "ocaml" is in
> USE with same error message. After looking at it I'm convinced that the
> graphviz code is correct and it's dev-lang/swig that's broken, putting a
> CAMLreturn() where there should be a return and doing other nasty things. In
> this case the only valid fix is ignore "ocaml" from USE and hardcode
> --disable-ocaml like the patch in the attachment does. It's a dev-lang/swig
> upstream problem.
> 
Have you tried this with the latest upstream SWIG source (1.3.31 IIRC)?
Comment 9 Andrzej Zaborowski 2006-12-10 05:04:24 UTC
Created attachment 103739 [details]
Replacement tclkpkg/gv/gv_ocaml.cpp, bzipped

Good call. I cloned today's subversion trunk SWIG and this one produced a gv_ocaml.cpp that builds with no warnings and works.
The file is 180 KB big and the diff against the original gv_cvaml.cpp is 230 KB so the attachment contains only the file and is bzipped.
Comment 10 Jakub Moc (RETIRED) gentoo-dev 2006-12-13 10:41:25 UTC
*** Bug 158049 has been marked as a duplicate of this bug. ***
Comment 11 Daniel Joseph Beauregard 2007-01-18 19:13:51 UTC
I don't know if this is the same issue, but take a look at Bug 161600.
Comment 12 Pacho Ramos gentoo-dev 2007-02-15 00:52:25 UTC
Have you tried with media-gfx/graphviz-2.12 ?

Good luck!
Comment 13 Maxim Treskin 2007-02-26 09:19:45 UTC
I found soulution! Just upgrade swig up to 1.3.31 and then compile graphviz with ocaml in USE - all is fine!
Comment 14 Jakub Moc (RETIRED) gentoo-dev 2007-02-26 09:22:13 UTC

*** This bug has been marked as a duplicate of bug 161600 ***