Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 434014 - gnome-extra/libgda-5.0.3-r1 fails to build
Summary: gnome-extra/libgda-5.0.3-r1 fails to build
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] GNOME (show other bugs)
Hardware: AMD64 Linux
: Normal normal with 1 vote (vote)
Assignee: Gentoo Linux Gnome Desktop Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-09-05 11:15 UTC by Vsevolod Minkov
Modified: 2013-07-12 16:23 UTC (History)
2 users (show)

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


Attachments
output of `emerge --info '=gnome-extra/libgda-5.0.3-r1'` (libgda.info,16.77 KB, text/plain)
2012-09-05 11:15 UTC, Vsevolod Minkov
Details
complete build log (build.log,40.48 KB, text/plain)
2012-09-05 11:15 UTC, Vsevolod Minkov
Details
output of `emerge -pqv '=gnome-extra/libgda-5.0.3-r1'` (pqv.out,326 bytes, text/plain)
2012-09-05 11:16 UTC, Vsevolod Minkov
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Vsevolod Minkov 2012-09-05 11:15:23 UTC
Created attachment 322982 [details]
output of `emerge --info '=gnome-extra/libgda-5.0.3-r1'`

Seems cause of a problem is

(g-ir-compiler:9984): GLib-WARNING **: GError set over the top of a previous GError or uninitialized memory.
This indicates a bug in someone's code. You must ensure an error is NULL before it's set.
The overwriting error message was: Expected namespace element in the gir file

Additional info:
GENTOO_VM=  CLASSPATH="" JAVA_HOME="/etc/java-config-2/current-system-vm"
JAVACFLAGS="" COMPILER=""
Comment 1 Vsevolod Minkov 2012-09-05 11:15:54 UTC
Created attachment 322984 [details]
complete build log
Comment 2 Vsevolod Minkov 2012-09-05 11:16:16 UTC
Created attachment 322986 [details]
output of `emerge -pqv '=gnome-extra/libgda-5.0.3-r1'`
Comment 3 Pacho Ramos gentoo-dev 2012-09-15 10:28:06 UTC
Are you able to reproduce this problem now with updated system? Have you tried to set MAKEOPTS=-j1? Do you get any message in /var/log/messages just after getting the failure?
Comment 4 Vsevolod Minkov 2012-09-18 06:37:37 UTC
(In reply to comment #3)
> Are you able to reproduce this problem now with updated system? Have you
> tried to set MAKEOPTS=-j1? Do you get any message in /var/log/messages just
> after getting the failure?

Hi and thank you! I've looked into /var/log/messages and found error like this 
Sep 18 13:23:49 izanami kernel: [2109212.448519] g-ir-compiler[16430] trap int3 ip:7fb1f9eb4595 sp:7fff9268a8a0 error:0

so I recompiled dev-libs/gobject-introspection and that solved my problem. So should I mark this ticket as resolved?
Comment 5 Pacho Ramos gentoo-dev 2012-09-18 07:04:14 UTC
Yes, probably you forgot to rebuild it after some other update (like glib one)
Comment 6 Roger 2013-06-19 02:33:26 UTC
The solution to this bug wasn't rebuilding dev-libs/gobject-introspection, or any CFLAGS OR MAKEOPTS incompatible options.

The /var/log/messages file does appear relevant though.

Jun 18 18:13:56 localhost4 kernel: traps: g-ir-compiler[24319] trap int3 ip:3f7025dc60 sp:7fffceff3ea0 error:0
Jun 18 18:15:48 localhost4 kernel: traps: g-ir-compiler[6038] trap int3 ip:3f7025dc60 sp:7fffd3ce9ef0 error:0
Jun 18 18:17:35 localhost4 kernel: traps: g-ir-compiler[21359] trap int3 ip:3f7025dc60 sp:7fff71a308c0 error:0
Jun 18 18:19:20 localhost4 kernel: traps: g-ir-compiler[3193] trap int3 ip:3f7025dc60 sp:7fff0fa7aa10 error:0

My workaround:

echo "=gnome-extra/libgda-5.1.1-r1 >> /etc/portage/package.keywords

emerge -1q gnome-extra/libgda

After upgrading libgda to version 5.1.1-r1, building with -ffast-math (or -Ofast) will spawn the following error:

sqlite3.c: In function ‘sqlite3IsNaN’:
sqlite3.c:22688:3: error: #error SQLite will not work correctly with the -ffast-math option of GCC

Remove or alter CFLAGS so -ffast-math or -Ofast isn't used for libgda (including sqlite): 

mkdir -p /etc/portage/env/gnome-extra/

echo 'CFLAGS="-O3 -funroll-loops -march=corei7 -pipe"' >  /etc/portage/env/gnome-extra/libgda


... now it's fixed, well sort of except for --fast-math support for sqlite! ;-)
Comment 7 Roger 2013-06-19 02:46:44 UTC
I should explicitly mention I tried building dev-libs/gobject-introspection and gnome-extra/libgda with default CFLAGS and MAKEOPTS, and libgda still failed as it should with invalid type for GDA.

Invalid type is just that, a coding error! ;-)
Comment 8 Pacho Ramos gentoo-dev 2013-06-19 06:37:42 UTC
We don't support neither -O3, -ffast-math and similar risky CFLAGS, please rebuild all your system with safe CFLAGS
Comment 9 Roger 2013-06-19 07:07:47 UTC
I'll again recite Comment #7.  I guess I assumed the error was previously thoroughly mentioned.

---Snip---
providers-support/gda-pstmt.h:36:
providers-support/gda-pstmt.h:75: Warning: Gda: string: Unknown type: 'string'
gda-attributes-manager.h:32: Warning: Gda: gda_attributes_manager_new: argument signal_func: Missing (scope) annotation for callback without GDestroyNotify (valid: call, async)
gda-attributes-manager.h:32: Warning: Gda: gda_attributes_manager_new: return value: Invalid non-constant return of bare structure or union; register as boxed type or (skip)
gda-util.h:101: Warning: Gda: gda_rewrite_sql_statement_for_null_parameters: return value: Invalid non-constant return of bare structure or union; register as boxed type or (skip)
gda-attributes-manager.h:44: Warning: Gda: gda_attributes_manager_foreach: argument func: Missing (scope) annotation for callback without GDestroyNotify (valid: call, async)
gda-attributes-manager.h:32: Warning: Gda: gda_attributes_manager_new: argument signal_func: Missing (scope) annotation for callback without GDestroyNotify (valid: call, async)
gda-attributes-manager.h:32: Warning: Gda: gda_attributes_manager_new: return value: Invalid non-constant return of bare structure or union; register as boxed type or (skip)
<unknown>:: Warning: Gda: (Signal)suggest-update: context=Signal('suggest-update') argument suggest: Unresolved type: 'GdaMetaContext'
<unknown>:: Warning: Gda: (Signal)meta-changed: context=Signal('meta-changed') argument changes: Unresolved type: 'GdaSList'
/usr/bin/g-ir-compiler --includedir=. --includedir=. Gda-5.0.gir -o Gda-5.0.typelib

** (g-ir-compiler:982): ERROR **: Invalid typelib for module 'Gda': In directory:Constant value type void
---Snip---

This is an invalid typelib error likely spawned by a C/C++ programmer.  Unmasking and upgrading to =gnome-extra/libgda-5.1.1-r1 solves this.

My previous mention of CFLAGS was misleading, and I was merrily testing with and without optimizations in order to verify if this was triggered by MAKEOPTS or CFLAGS.
Comment 10 Roger 2013-06-19 07:23:49 UTC
Suggest closing as Resolved -> Fixed Upstream

(This bug can be easily found on Google when searching for this error.)

Only remaining issue, the newer version is still masked within the system.