Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 420685 - app-office/dia - ../lib/.libs/libdia.so: error: undefined reference to 'g_module_close'
Summary: app-office/dia - ../lib/.libs/libdia.so: error: undefined reference to 'g_mod...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: AMD64 Linux
: Normal normal (vote)
Assignee: GNOME Office (OBSOLETE)
URL:
Whiteboard:
Keywords: Inclusion
Depends on:
Blocks: underlinking
  Show dependency tree
 
Reported: 2012-06-11 12:38 UTC by Mark
Modified: 2012-07-07 15:49 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Mark 2012-06-11 12:38:13 UTC
I compiled dia with clang and the gold linker (binutils-config --linker ld.gold), which failed. After setting the binutils back to the bfd linker (binutils-config --linker ld.bfd), it was able to link dia.
I did not use any special sort of compiler/linker flags like lto, just march and O2.

Here is the last output of the emerge window:
/bin/bash ../libtool --tag=CC   --mode=link clang  -I/usr/include/libxml2 -I/usr/include/freetype2 -march=athlon64-sse3 -O2  -Wall --std=c89 -Wdeclaration-after-statement -Wmissing-prototypes -Wmissing-declarations -finline-functions -fstrict-aliasing -Wpointer-arith -Winit-self -Wformat-nonliteral -export-dynamic -Wl,-O1 -Wl,--as-needed -o dia confirm.o exit_dialog.o diagram.o preferences.o load_save.o properties-dialog.o defaults.o undo.o object_ops.o layer_dialog.o commands.o app_procs.o connectionpoint_ops.o disp_callbacks.o display.o select.o color_area.o linewidth_area.o grid.o handle_ops.o interface.o modify_tool.o scroll_tool.o create_object.o magnify.o menus.o cut_n_paste.o render_gdk.o tool.o diapagelayout.o pagesetup.o filedlg.o find-and-replace.o plugin-manager.o dia-props.o gtkwrapbox.o gtkhwrapbox.o gtkvwrapbox.o cursor.o splash.o recent_files.o diagram_tree.o diagram_tree_window.o diagram_tree_menu.o diagram_tree_menu_callbacks.o sheets.o sheets_dialog.o sheets_dialog_callbacks.o autosave.o dynamic_refresh.o navigation.o diacanvas.o highlight.o textedit.o textedit_tool.o main.o ../lib/libdia.la   -lz -lfreetype -lz -lbz2 -pthread -lgtk-x11-2.0 -lgdk-x11-2.0 -latk-1.0 -lgio-2.0 -lpangocairo-1.0 -lcairo -lxml2 -lgdk_pixbuf-2.0 -lgthread-2.0 -lrt -lpangoft2-1.0 -lpango-1.0 -lfreetype -lfontconfig -lgobject-2.0 -lglib-2.0 -lart_lgpl_2   -lpng -lz -lm   -lxml2 -lz -lpthread -lm -lart_lgpl_2    -lpng -lz -lm -lz
libtool: link: clang -I/usr/include/libxml2 -I/usr/include/freetype2 -march=athlon64-sse3 -O2 -Wall --std=c89 -Wdeclaration-after-statement -Wmissing-prototypes -Wmissing-declarations -finline-functions -fstrict-aliasing -Wpointer-arith -Winit-self -Wformat-nonliteral -Wl,-O1 -Wl,--as-needed -o .libs/dia confirm.o exit_dialog.o diagram.o preferences.o load_save.o properties-dialog.o defaults.o undo.o object_ops.o layer_dialog.o commands.o app_procs.o connectionpoint_ops.o disp_callbacks.o display.o select.o color_area.o linewidth_area.o grid.o handle_ops.o interface.o modify_tool.o scroll_tool.o create_object.o magnify.o menus.o cut_n_paste.o render_gdk.o tool.o diapagelayout.o pagesetup.o filedlg.o find-and-replace.o plugin-manager.o dia-props.o gtkwrapbox.o gtkhwrapbox.o gtkvwrapbox.o cursor.o splash.o recent_files.o diagram_tree.o diagram_tree_window.o diagram_tree_menu.o diagram_tree_menu_callbacks.o sheets.o sheets_dialog.o sheets_dialog_callbacks.o autosave.o dynamic_refresh.o navigation.o diacanvas.o highlight.o textedit.o textedit_tool.o main.o -pthread -Wl,--export-dynamic  ../lib/.libs/libdia.so -lgtk-x11-2.0 -lgdk-x11-2.0 -latk-1.0 -lgio-2.0 -lpangocairo-1.0 -lcairo -lgdk_pixbuf-2.0 -lgthread-2.0 -lrt -lpangoft2-1.0 -lpango-1.0 /usr/lib64/libfreetype.so -lbz2 -lfontconfig -lgobject-2.0 -lglib-2.0 -lxml2 -lpthread /usr/lib64/libart_lgpl_2.so -lpng -lm -lz -pthread -Wl,-rpath -Wl,/usr/lib64/dia
../lib/.libs/libdia.so: error: undefined reference to 'g_module_close'
../lib/.libs/libdia.so: error: undefined reference to 'g_module_error'
../lib/.libs/libdia.so: error: undefined reference to 'g_module_open'
../lib/.libs/libdia.so: error: undefined reference to 'g_module_symbol'
clang: error: linker command failed with exit code 1 (use -v to see invocation)

Reproducible: Always




I additionally set
CC="clang"
CXX="clang++"
which is clang 3.1. Also, ld -v prints
GNU gold (GNU Binutils 2.22) 1.11

emerge --info '=app-office/dia-0.97.2-r1'
Portage 2.1.10.65 (default/linux/amd64/10.0/desktop/kde, gcc-4.6.3, glibc-2.15-r2, 3.5.0-rc2 x86_64)
=================================================================
                         System Settings
=================================================================
System uname: Linux-3.5.0-rc2-x86_64-AMD_Athlon-tm-_64_X2_Dual_Core_Processor_5200+-with-gentoo-2.1
Timestamp of tree: Mon, 11 Jun 2012 08:45:01 +0000
app-shells/bash:          4.2_p29
dev-java/java-config:     2.1.12
dev-lang/python:          2.7.3-r2, 3.2.3-r1
dev-util/cmake:           2.8.8-r2
dev-util/pkgconfig:       0.26
sys-apps/baselayout:      2.1-r1
sys-apps/openrc:          0.10.2
sys-apps/sandbox:         2.5
sys-devel/autoconf:       2.13, 2.69
sys-devel/automake:       1.9.6-r3, 1.11.5
sys-devel/binutils:       2.22-r1
sys-devel/gcc:            4.5.3-r2, 4.6.3
sys-devel/gcc-config:     1.7.3
sys-devel/libtool:        2.4.2
sys-devel/make:           3.82-r3
sys-kernel/linux-headers: 3.4 (virtual/os-headers)
sys-libs/glibc:           2.15-r2
Repositories: gentoo zugaina x11 lokal glc
ACCEPT_KEYWORDS="amd64 ~amd64"
ACCEPT_LICENSE="* -@EULA PUEL Q3AEULA"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-march=athlon64-sse3 -O2"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/config /usr/share/gnupg/qualified.txt /usr/share/maven-bin-3.0/conf /usr/share/openvpn/easy-rsa /var/lib/hsqldb"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/fonts/fonts.conf /etc/games/angband/edit/ /etc/gconf /etc/gentoo-release /etc/revdep-rebuild /etc/sandbox.d /etc/terminfo /etc/texmf/language.dat.d /etc/texmf/language.def.d /etc/texmf/updmap.d /etc/texmf/web2c"
CXXFLAGS="-march=athlon64-sse3 -O2"
DISTDIR="/usr/portage/distfiles"
EMERGE_DEFAULT_OPTS="--quiet-build=n --keep-going"
FEATURES="assume-digests binpkg-logs config-protect-if-modified distlocks ebuild-locks fixlafiles news parallel-fetch parse-eapi-ebuild-head protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch userpriv usersandbox"
FFLAGS=""
GENTOO_MIRRORS="ftp://sunsite.informatik.rwth-aachen.de/pub/Linux/gentoo"
LANG="de_DE.utf8"
LC_ALL="de_DE.utf8"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
LINGUAS="de"
MAKEOPTS="-j4"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --human-readable --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/mnt/ramdisk"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY="/var/lib/layman/zugaina /var/lib/layman/x11 /usr/local/portage /var/lib/layman/glc-overlay"
SYNC="rsync://rsync.informatik.rwth-aachen.de/gentoo-portage"
USE="3dnow X a52 aac acl acpi alsa amd64 bash-completion berkdb bluray branding bzip2 cairo cdda cddb cdr cli consolekit cracklib crypt cups cxx dbus declarative djvu dri dts dvd dvdr emboss encode exif fam ffmpeg firefox flac fortran ftp gdbm gif gmp gnutls gstreamer gtk hddtemp iconv imagemagick ipv6 jpeg jpeg2k kipi kontact kpathsea lame lcms libass libnotify lm_sensors lzma mad matroska mbrola mmx mng modules mp3 mp4 mpeg mpi mudflap multilib musicbrainz ncurses nls nptl ogg opengl pam pango pcre pdf phonon plasma png policykit ppds pppd qt3support qt4 readline sdl semantic-desktop session smp spell sse sse2 ssl startup-notification svg taglib tcpd theora threads tiff truetype udev udisks unicode upnp upower usb v4l v4l2 vdpau vorbis wxwidgets x264 xcb xcomposite xinerama xml xorg xrandr xscreensaver xulrunner xv xvid xvmc zlib" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" CALLIGRA_FEATURES="kexi words flow plan sheets stage tables krita karbon braindump" CAMERAS="ptp2" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ubx" INPUT_DEVICES="wacom evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" LIBREOFFICE_EXTENSIONS="presenter-console presenter-minimizer" LINGUAS="de" PHP_TARGETS="php5-3" PYTHON_TARGETS="python3_2 python2_7" RUBY_TARGETS="ruby19" SANE_BACKENDS="genesys" USERLAND="GNU" VIDEO_CARDS="radeon" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  CPPFLAGS, CTARGET, INSTALL_MASK, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, USE_PYTHON

=================================================================
                        Package Settings
=================================================================

app-office/dia-0.97.2-r1 was built with the following:
USE="cairo (consolekit) (multilib) (policykit) -debug -doc -gnome -python"
Comment 1 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2012-06-25 08:19:31 UTC
Reported upstream and attached a patch there.
Comment 2 Pacho Ramos gentoo-dev 2012-07-07 13:10:25 UTC
Feel free to commit please
Comment 3 Michał Górny archtester Gentoo Infrastructure gentoo-dev Security 2012-07-07 15:49:34 UTC
(In reply to comment #2)
> Feel free to commit please

Committed into -r1. I've also removed intltoolize call which is now done by eautoreconf.