Closed Bug 464674 Opened 16 years ago Closed 16 years ago

Linux static build link failure in suite/app due to DBus

Categories

(SeaMonkey :: Build Config, defect)

x86
Linux
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: kairo, Assigned: kairo)

References

Details

Attachments

(1 file)

c++ -o seamonkey-bin  -fno-rtti -fno-exceptions -Wall -Wpointer-arith -Woverloaded-virtual -Wsynth -Wno-ctor-dtor-privacy -Wno-non-virtual-dtor -Wcast-align -Wno-invalid-offsetof -Wno-long-long -pedantic -march=pentium4 -mtune=nocona -msse2 -msse3 -mssse3 -mfpmath=sse -fno-strict-aliasing -fshort-wchar -pthread -pipe  -DNDEBUG -DTRIMMED -Os -freorder-blocks -fno-reorder-functions   nsSuiteApp.o nsStaticComponents.o    -lpthread   -Wl,-rpath-link,../../mozilla/dist/bin:/usr/lib:/usr/local/lib:/lib  -L../../mozilla/dist/bin -L../../mozilla/dist/lib ../../mozilla/toolkit/xre/libxulapp_s.a -L../../staticlib -L../../mozilla/dist/bin -lmozjs  -L../../mozilla/dist/bin -lxpcom -lxpcom_core  `../../mozilla/nsprpub/config/nspr-config --prefix=../../mozilla/dist --libdir=../../mozilla/dist/lib --libs` -lgtk-x11-2.0 -latk-1.0 -lgio-2.0 -lpangoft2-1.0 -lfreetype -lz -lfontconfig -lgdk-x11-2.0 -lgdk_pixbuf-2.0 -lpangocairo-1.0 -lpango-1.0 -lcairo -lgmodule-2.0 -lgobject-2.0 -lglib-2.0      -lX11  -Wl,--whole-archive -ljemalloc -Wl,--no-whole-archive -ldl -lm  ../../mozilla/staticlib/components/libpref.a ../../mozilla/staticlib/components/libuconv.a ../../mozilla/staticlib/components/libucvmath.a ../../mozilla/staticlib/components/libi18n.a ../../mozilla/staticlib/components/libnecko.a ../../mozilla/staticlib/components/libauth.a ../../mozilla/staticlib/components/libxpconnect.a ../../mozilla/staticlib/components/libchardet.a ../../mozilla/staticlib/components/libzipwriter.a ../../mozilla/staticlib/components/libmork.a ../../mozilla/staticlib/components/libcookie.a ../../mozilla/staticlib/components/libpermissions.a ../../mozilla/staticlib/components/libstoragecomps.a ../../mozilla/staticlib/components/librdf.a ../../mozilla/staticlib/components/libcaps.a ../../mozilla/staticlib/components/libhtmlpars.a ../../mozilla/staticlib/components/libgkgfxthebes.a ../../mozilla/staticlib/components/libimglib2.a ../../mozilla/staticlib/components/libgkplugin.a ../../mozilla/staticlib/components/libwidget_gtk2.a ../../mozilla/staticlib/components/libtxmgr.a ../../mozilla/staticlib/components/libcomposer.a ../../mozilla/staticlib/components/libgklayout.a ../../mozilla/staticlib/components/libdocshell.a ../../mozilla/staticlib/components/libembedcomponents.a ../../mozilla/staticlib/components/libwebbrwsr.a ../../mozilla/staticlib/components/libnsappshell.a ../../mozilla/staticlib/components/libuniversalchardet.a ../../mozilla/staticlib/components/liboji.a ../../mozilla/staticlib/components/libaccessibility.a ../../mozilla/staticlib/components/libchrome.a ../../mozilla/staticlib/components/libmozfind.a ../../mozilla/staticlib/components/libintlapp.a ../../mozilla/staticlib/components/libwindowds.a ../../mozilla/staticlib/components/libxpautocomplete.a ../../mozilla/staticlib/components/libappcomps.a ../../mozilla/staticlib/components/libremoteservice.a ../../mozilla/staticlib/components/libplaces.a ../../mozilla/staticlib/components/libfileview.a ../../mozilla/staticlib/components/libtkautocomplete.a ../../mozilla/staticlib/components/libsatchel.a ../../mozilla/staticlib/components/libcommandlines.a ../../mozilla/staticlib/components/libtoolkitcomps.a ../../mozilla/staticlib/components/libspellchecker.a ../../mozilla/staticlib/components/libunixproxy.a ../../mozilla/staticlib/components/libpipboot.a ../../mozilla/staticlib/components/libpipnss.a ../../mozilla/staticlib/components/libpippki.a ../../mozilla/staticlib/components/libautoconfig.a ../../mozilla/staticlib/components/libsystem-pref.a ../../mozilla/staticlib/components/libwallet.a ../../mozilla/staticlib/components/libwalletviewers.a ../../mozilla/staticlib/components/libmozldap.a ../../mozilla/staticlib/components/libimport.a ../../mozilla/staticlib/components/libmsgsmime.a ../../mozilla/staticlib/components/libmail.a ../../mozilla/staticlib/libmozreg_s.a ../../mozilla/staticlib/libunicharutil_s.a ../../mozilla/staticlib/libucvutil_s.a ../../mozilla/staticlib/libgtkxtbin.a ../../mozilla/staticlib/libmorkreader_s.a ../../mozilla/staticlib/libthebes.a ../../mozilla/staticlib/libgfxshared_s.a ../../mozilla/staticlib/libgfxpsshar.a ../../mozilla/staticlib/libgkgfx.a ../../mozilla/staticlib/libjsj.a ../../mozilla/staticlib/libmimecthglue_s.a  -L../../mozilla/modules/libimg/png -lmozpng -L../../mozilla/jpeg -lmozjpeg -L../../mozilla/modules/zlib/src -lmozz -L../../mozilla/dist/bin -lmozlcms  -L../../mozilla/dist/bin -L../../mozilla/dist/lib -lcrmf -lsmime3 -lssl3 -lnss3 -lnssutil3 -lsoftokn3  -L../../mozilla/dist/bin -L../../mozilla/dist/lib -lldap60 -lprldap60 -lldif60  ../../mozilla/gfx/cairo/cairo/src/libmozcairo.a ../../mozilla/gfx/cairo/libpixman/src/libmozlibpixman.a   -lXrender -lfreetype -lfontconfig  -lXt -lgthread-2.0 -lpangoft2-1.0 -lpango-1.0 -lfreetype -lz -lfontconfig -lgobject-2.0 -lgmodule-2.0 -lglib-2.0   -L../../mozilla/dist/lib -lsqlite3
../../mozilla/staticlib/components/libdocshell.a(nsDBusHandlerApp.o): In function `nsDBusHandlerApp::LaunchWithURI(nsIURI*, nsIInterfaceRequestor*)':
nsDBusHandlerApp.cpp:(.text+0x251): undefined reference to `dbus_error_init'
nsDBusHandlerApp.cpp:(.text+0x25b): undefined reference to `dbus_bus_get'
nsDBusHandlerApp.cpp:(.text+0x265): undefined reference to `dbus_error_is_set'
nsDBusHandlerApp.cpp:(.text+0x282): undefined reference to `dbus_connection_set_exit_on_disconnect'
nsDBusHandlerApp.cpp:(.text+0x296): undefined reference to `dbus_message_new_method_call'
nsDBusHandlerApp.cpp:(.text+0x2a9): undefined reference to `dbus_message_set_no_reply'
nsDBusHandlerApp.cpp:(.text+0x2b5): undefined reference to `dbus_message_iter_init_append'
nsDBusHandlerApp.cpp:(.text+0x2c4): undefined reference to `dbus_message_iter_append_basic'
nsDBusHandlerApp.cpp:(.text+0x2d0): undefined reference to `dbus_connection_send'
nsDBusHandlerApp.cpp:(.text+0x2e0): undefined reference to `dbus_message_unref'
nsDBusHandlerApp.cpp:(.text+0x30d): undefined reference to `dbus_error_free'
nsDBusHandlerApp.cpp:(.text+0x318): undefined reference to `dbus_connection_flush'
nsDBusHandlerApp.cpp:(.text+0x320): undefined reference to `dbus_message_unref'
collect2: ld returned 1 exit status
gmake[5]: *** [seamonkey-bin] Error 1
gmake[5]: Leaving directory `/mnt/mozilla/build/seamonkey-test/suite/app'
gmake[4]: *** [libs] Error 2
gmake[4]: Leaving directory `/mnt/mozilla/build/seamonkey-test/suite'
gmake[3]: *** [libs_tier_app] Error 2
gmake[3]: Leaving directory `/mnt/mozilla/build/seamonkey-test'
gmake[2]: *** [tier_app] Error 2
gmake[2]: Leaving directory `/mnt/mozilla/build/seamonkey-test'
gmake[1]: *** [default] Error 2
gmake[1]: Leaving directory `/mnt/mozilla/build/seamonkey-test'
gmake: *** [build] Error 2

This happens with current trunk and the following significant mozconfig options:
ac_add_options --disable-tests
ac_add_options --disable-debug
ac_add_options --enable-optimize
ac_add_options --disable-shared
ac_add_options --enable-static

--disable-tests is needed or some cairo tests fail to compile, btw.
OK, seems to actually be our instance of bug 448218.
Depends on: 448218
I'll include simple Mac static build fixes in the patch as well, which I spotted by comparing Thunderbird's and SeaMonkey's app/Makefile.in files, as well as piece where SeaMonkey was missed by bug 368206 moving "-framework QuickTime -framework IOKit" into static-rules.mk and a DEPTH->MOZDEPTH change that we needed to fix up Thunderbird on comm-central but missed for SeaMonkey due to not supporting static builds yet.
This patch fixes the Linux dbus error and hopefully also Mac static builds - Mark, could you test the latter, please? Note that you need to --diable-tests on those builds, just like Thunderbird does, or we fail with cairo tests. I think we should actually file that.
Assignee: build-config → kairo
Status: NEW → ASSIGNED
Attachment #347959 - Flags: superreview?(neil)
Attachment #347959 - Flags: review?(bugzilla)
Attachment #347959 - Flags: superreview?(neil) → superreview+
Comment on attachment 347959 [details] [diff] [review]
fix several static build issues

This fails on Mac with --enable-static.

Packaging debugQA-2.0a2pre.xpi...
./
./chrome/
./chrome/debugqa.jar
./chrome.manifest
./install.rdf
Making symlinks to the original object files in the archive libraries ../profile/libsuiteprofile_s.a ../profile/migration/src/libsuitemigration_s.a ../browser/src/libsuitebrowser_s.a
ld: absolute addressing (perhaps -mdynamic-no-pic) used in nsSuiteDirectoryProvider::QueryInterface(nsID const&, void**)from nsSuiteDirectoryProvider.o not allowed in slidable image
collect2: ld returned 1 exit status
make[5]: *** [libsuite.dylib] Error 1
make[4]: *** [libs] Error 2
make[3]: *** [libs_tier_app] Error 2
make[2]: *** [tier_app] Error 2
make[1]: *** [default] Error 2
make: *** [build] Error 2

I'm not sure if that's related to this patch or not.
Attachment #347959 - Flags: review?(bugzilla)
Comment on attachment 347959 [details] [diff] [review]
fix several static build issues

From your comment, I'm guessing you've tested Linux.

I took a quick look, but Mac still fails with the error above, I thought that removing EXTRA_DSO_LDOPTS and adding META_COMPONENT=suite to/from suite/profile/Makefile.in would fix it, but it didn't.

So I don't know what's happening there, but this part seems good enough that we can check it in and move forward.
Attachment #347959 - Flags: review+
Thanks, pushed as http://hg.mozilla.org/comm-central/rev/0ac3318abe46 and filed bug 465357 for the Mac failure mentioned in comment #4.
Status: ASSIGNED → RESOLVED
Closed: 16 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: