../../dist/lib/libstorage_s.a(mozStorageAsyncIO.o): In function `.L106':
mozStorageAsyncIO.cpp:(.text+0x8a4): undefined reference to `sqlite3ApiExit'
...
etc
System is Linux, everything from sources, very up to date.
gcc 4.4.0, so this patch needed:
diff -uNr mozilla.orig/toolkit/xre/nsAppRunner.cpp mozilla/toolkit/xre/nsAppRunner.cpp
--- mozilla.orig/toolkit/xre/nsAppRunner.cpp 2007-11-08 12:56:25.000000000 +0100
+++ mozilla/toolkit/xre/nsAppRunner.cpp 2009-06-26 21:22:32.000000000 +0200
@@ -1370,7 +1370,7 @@
if (NS_FAILED(rv))
return rv;
-#elif
+#else
#error Oops, you need platform-specific code here
#endif
.mozconfig
mk_add_options MOZ_OBJDIR=@TOPSRCDIR@/objdir
. \$topsrcdir/mail/config/mozconfig
ac_add_options --prefix=/usr
ac_add_options --with-system-nspr
ac_add_options --with-system-nss # second build I deleted this line
ac_add_options --with-system-jpeg
ac_add_options --with-system-zlib
ac_add_options --with-system-png
ac_add_options --enable-default-toolkit=gtk2
ac_add_options --enable-static-mail
ac_add_options --disable-freetype2
ac_add_options --enable-xft
ac_add_options --enable-crypto
ac_add_options --disable-installer
ac_add_options --disable-tests
ac_add_options --disable-debug
ac_add_options --enable-optimize
ac_add_options --enable-system-cairo
mk_add_options MOZ_CO_PROJECT=mail
That one worked for 2.0.0.22. Also with gcc 4.4.0
~/rpmbuild/BUILD/mozilla/objdir/dist/lib $ strings libsqlite3.so
....
sqlite3_complete16
sqlite3ApiExit
sqlite3RegisterDateTimeFunctions
....
objdir/dist/include/sqlite3/sqlite3file.h has
extern "C" {
so that should'nt be the problem
Can someone confirm this buildproblem?
Then the problem can be located, maybe it is a gcc bug.
No, #elifs without condition are bad. This is actually bug 478843 and
was fixed in many branches, but not yet 1.8.1. Perhaps you can request
approval1.8.1.24 on that patch. (I'm surprised if this is the only gcc
4.4 on the 1.8.1 branch...)
Cheers,
Peter.
This is 2.0.0.23:
> make[3]: Entering directory
> `/home/tjoen/rpmbuild/BUILD/mozilla/objdir/storage/build'
> ...
[reedited]
c++ -fno-rtti -fno-exceptions -Wall -Wconversion -Wpointer-arith \
-Wcast-align -Woverloaded-virtual -Wsynth -Wno-ctor-dtor-privacy \
-Wno-non-virtual-dtor -Wno-long-long -pedantic -fshort-wchar \
-pthread -pipe -DNDEBUG -DTRIMMED -O -fPIC -shared \
-Wl,-z,defs -Wl,-h,libstoragecomps.so \
-o libstoragecomps.so \
mozStorageModule.o \
-Wl,--whole-archive ../../dist/lib/libstorage_s.a \
-Wl,--no-whole-archive -L../../dist/bin -L../../dist/lib -lsqlite3 \
-L../../dist/bin -lxpcom -lxpcom_core \
-L../../dist/bin -L/lib -lplds4 -lplc4 -lnspr4 -lpthread -ldl \
-L../../dist/bin -lmozjs \
-Wl,--version-script \
-Wl,../../../build/unix/gnu-ld-scripts/components-version-script \
-Wl,-Bsymbolic -ldl -lm
> ../../dist/lib/libstorage_s.a(mozStorageAsyncIO.o): In function `.L106':
> mozStorageAsyncIO.cpp:(.text+0x8a4): undefined reference to `sqlite3ApiExit'
> ...
> etc
2.0.0.22 links correctly:
c++ -fno-rtti -fno-exceptions -Wall -Wconversion -Wpointer-arith \
-Wcast-align -Woverloaded-virtual -Wsynth -Wno-ctor-dtor-privacy \
-Wno-non-virtual-dtor -Wno-long-long -pedantic -fshort-wchar \
-pthread -pipe -DNDEBUG -DTRIMMED -O -fPIC -shared \
-Wl,-z,defs -Wl,-h,libstoragecomps.so \
-o libstoragecomps.so
mozStorageModule.o \
-Wl,--whole-archive ../../dist/lib/libstorage_s.a \
../../dist/lib/libsqlite3_s.a \
-Wl,--no-whole-archive -L../../dist/bin -L../../dist/lib \
-L../../dist/bin -lxpcom -lxpcom_core \
-L../../dist/bin -L/lib -lplds4 -lplc4 -lnspr4 -lpthread -ldl \
-L../../dist/bin -lmozjs \
-Wl,--version-script \
-Wl,../../../build/unix/gnu-ld-scripts/components-version-script \
-Wl,-Bsymbolic -ldl -lm
The difference:
2.0.0.23:
-Wl,--whole-archive ../../dist/lib/libstorage_s.a \
-Wl,--no-whole-archive -L../../dist/bin -L../../dist/lib -lsqlite3 \
2.0.0.22:
-Wl,--whole-archive ../../dist/lib/libstorage_s.a \
../../dist/lib/libsqlite3_s.a \
-Wl,--no-whole-archive -L../../dist/bin -L../../dist/lib \
Why is that a problem? Someting wrong with libsqlite3.so?
c++ -fno-rtti -fno-exceptions -Wall -Wconversion -Wpointer-arith \
-Wcast-align -Woverloaded-virtual -Wsynth -Wno-ctor-dtor-privacy \
-Wno-non-virtual-dtor -Wno-long-long -pedantic -fshort-wchar \
-pthread -pipe -DNDEBUG -DTRIMMED -O -fPIC -shared \
-Wl,-z,defs -Wl,-h,libsqlite3.so \
-o libsqlite3.so \
alter.o analyze.o attach.o auth.o btree.o build.o callback.o \
complete.o date.o delete.o experimental.o expr.o func.o hash.o \
insert.o legacy.o main.o opcodes.o os.o os_unix.o os_win.o os_os2.o \
os_beos.o pager.o parse.o pragma.o prepare.o printf.o random.o \
select.o table.o tokenize.o trigger.o update.o utf.o util.o vacuum.o \
vdbe.o vdbeapi.o vdbeaux.o vdbefifo.o vdbemem.o where.o \
-ldl -lm
> Why is that a problem? Someting wrong with libsqlite3.so?
From bug souvenirs (see bug 504523) sqlite changed from a dynamic
linking to a static one.
Ludo
--
Ludovic Hirlimann MozillaMessaging QA lead
http://www.spreadthunderbird.com/aff/79/2
https://bugzilla.mozilla.org/show_bug.cgi?id=504523
You are not authorized to access bug #504523. To see this bug, you
must first log in to an account with the appropriate permissions :-(
So somehow my 2.0.0.23 ./configure creates Makefiles for
dynamic linking. Is it only with me? No other results in Google
if I search for the error in my original posting.
I am considering upgrading to gcc 4.4.1 but does that solve
the build problem? Or is the bug in the linker?
My /usr/bin/ld is from binutils-2.19.1
It is a confirmation of the problem, so I am not the only one.
Knowing which tools are working would be helpful.
What I have tried too is deleting /lib/libsqlite3.so
(maybe the linker tried to link to that one). Problem persists.
I am compiling 2.0.0.22 again now to keep the output.
Next I will try the commands in that outputfile to see
if that works.
Interesting stuff! Thanks! Let's see:
> Compiler is -- gcc (gcc (GCC) 3.3.3
Bit too old for me, isn't that the one with libstdc++.so.5 ?
> ac_add_options --disable-shared
> ac_add_options --enable-static
Looks lijke those are the most important differences to the
default. It results to:
> libstoragecomps.a
I am missing --enable-static-mail needed by enigmail
(according to their documentation)
Is enigmail working with users of the official distro?
I am trying a patch now for the shared version
> 2.0.0.23 Linux gcc-4.4.0 binutils-2.19.1
> .mozconfig
> mk_add_options MOZ_OBJDIR=@TOPSRCDIR@/objdir
> . \$topsrcdir/mail/config/mozconfig
> ac_add_options --prefix=/usr
> ac_add_options --with-system-nspr
> ac_add_options --with-system-nss # second build I deleted this line
> ac_add_options --with-system-jpeg
> ac_add_options --with-system-zlib
> ac_add_options --with-system-png
> ac_add_options --enable-default-toolkit=gtk2
> ac_add_options --enable-static-mail
> ac_add_options --disable-freetype2
> ac_add_options --enable-xft
> ac_add_options --enable-crypto
> ac_add_options --disable-installer
> ac_add_options --disable-tests
> ac_add_options --disable-debug
> ac_add_options --enable-optimize
> ac_add_options --enable-system-cairo
> mk_add_options MOZ_CO_PROJECT=mail
> ...
> make[3]: Entering directory
> `/home/tjoen/rpmbuild/BUILD/mozilla/objdir/storage/build'
> ...
> c++ -fno-rtti -fno-exceptions -Wall -Wconversion -Wpointer-arith \
> -Wcast-align -Woverloaded-virtual -Wsynth -Wno-ctor-dtor-privacy \
> -Wno-non-virtual-dtor -Wno-long-long -pedantic -fshort-wchar \
> -pthread -pipe -DNDEBUG -DTRIMMED -O -fPIC -shared \
> -Wl,-z,defs -Wl,-h,libstoragecomps.so \
> -o libstoragecomps.so \
> mozStorageModule.o \
> -Wl,--whole-archive ../../dist/lib/libstorage_s.a \
> -Wl,--no-whole-archive -L../../dist/bin -L../../dist/lib -lsqlite3 \
> -L../../dist/bin -lxpcom -lxpcom_core \
> -L../../dist/bin -L/lib -lplds4 -lplc4 -lnspr4 -lpthread -ldl \
> -L../../dist/bin -lmozjs \
> -Wl,--version-script \
> -Wl,../../../build/unix/gnu-ld-scripts/components-version-script \
> -Wl,-Bsymbolic -ldl -lm
> ../../dist/lib/libstorage_s.a(mozStorageAsyncIO.o): In function `.L106':
> mozStorageAsyncIO.cpp:(.text+0x8a4): undefined reference to `sqlite3ApiExit'
> ...
> etc
Confirmed by toshiharu : (no .mozconfig given)
> I got the same error with gcc-4.3.3 and binutils-2.19.51.0.9.
diff -uNr mozilla.orig/db/sqlite3/src/Makefile.in mozilla/db/sqlite3/src/Makefile.in
--- mozilla.orig/db/sqlite3/src/Makefile.in 2009-08-10 19:59:12.000000000 +0200
+++ mozilla/db/sqlite3/src/Makefile.in 2009-08-24 21:53:50.000000000 +0200
@@ -46,7 +46,7 @@
MODULE = sqlite3
LIBRARY_NAME = sqlite3
MODULE_NAME = sqlite3
-FORCE_SHARED_LIB = 1
+FORCE_STATIC_LIB = 1
VISIBILITY_FLAGS =
ifeq (,$(filter-out WINNT WINCE, $(OS_ARCH)))
Thanks!
Dan
I think I have no permission for that, no account there.
But sure there are developpers reading this newsgroup/list
Dan
Same with Bugzilla reports. The missing
#include <cstdio>
is still there
Not true. Almost all reports with patches attached do get appropriate attention.
Since it requires a bug report for the patch to be reviewed and checked in
anyway, it's just a waste of time doing anything about it here.
-Magnus
Build success with above gcc and binutils.
I added ac_cv_visibility_pragma=no to mozconfig.
Thanks xhorak for this patch.
http://cvs.fedoraproject.org/viewvc/F-10/thunderbird/thunderbird-2.0-visibility.patch?revision=1.1&view=markup
This one appears is Google, (not yet in Bing)
so everybody with the same problem can apply the patch.
But anybody with a bugzilla account can submit the patch,
that is the reason I made my OP so complete