Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 22 Nov 2012 13:02:13 +0100
From:      Stefan Esser <se@freebsd.org>
To:        flo@freebsd.org
Cc:        freebsd-ports@freebsd.org
Subject:   Firefox build failure on -CURRENT (with CLANG and with GCC)
Message-ID:  <50AE1445.2090900@freebsd.org>

next in thread | raw e-mail | index | archive | help
Hi Florian,

seems that Firefox cannot be built with CLANG. The build fails due to a
visibility default set in mozilla-release/config/gcc_hidden.h, which is
in conflict with Qt declarations:

In file included from
work/mozilla-release/intl/locale/src/nsLocaleService.cpp:7:
In file included from /usr/local/include/qt4/QtCore/QString:1:
In file included from /usr/local/include/qt4/QtCore/qstring.h:46:
/usr/local/include/qt4/QtCore/qbytearray.h:143:7: error: visibility does
not match previous declaration
class Q_CORE_EXPORT QByteArray
      ^
/usr/local/include/qt4/QtCore/qglobal.h:1412:27: note: expanded from
macro 'Q_CORE_EXPORT'
#    define Q_CORE_EXPORT Q_DECL_EXPORT
                          ^
/usr/local/include/qt4/QtCore/qglobal.h:1269:42: note: expanded from
macro 'Q_DECL_EXPORT'
#    define Q_DECL_EXPORT __attribute__((visibility("default")))
                                         ^
../../../config/gcc_hidden.h:6:13: note: previous attribute is here
#pragma GCC visibility push(hidden)

Seems that this GCC pragma has different semantics in GLANG ...

If the contents of gcc_hidden.h is commented out, CLANG completes the
build, but the installation fails in the phase where hyphenation tables
are built:

 adding: hyphenation/hyph_af.dic (deflated 55%)
  adding: hyphenation/hyph_sv.dic (deflated 51%)
  adding: hyphenation/hyph_it.dic (deflated 55%)
  adding: hyphenation/hyph_cy.dic (deflated 53%)
  adding: hyphenation/hyph_gl.dic (deflated 69%)
  adding: hyphenation/hyph_is.dic (deflated 50%)
  adding: hyphenation/hyph_ia.dic (deflated 51%)
  adding: hyphenation/hyph_en_US.dic (deflated 59%)
  adding: hyphenation/hyph_pt.dic (deflated 55%)
Segmentation fault (core dumped)
gmake[1]: *** [install] Error 139
gmake[1]: Leaving directory
`/usr/work/usr/svn/ports/head/www/firefox/work/mozilla-release/browser/installer'
gmake: *** [install] Error 2
*** [gecko-pre-install] Error code 2

Adding USE_GCC=any to the port lets the build complete, but installation
fails at a later point:

  adding: hyphenation/hyph_tr.dic (deflated 64%)
QEventLoop: Cannot be used without QApplication
resource:///components/txEXSLTRegExFunctions.js
resource:///components/nsLoginManagerPrompter.js
[...]
resource:///modules/services-sync/addonutils.js
Failed to import
resource:///modules/services-sync/addonutils.js:[Exception... "Component
returned failure code: 0x80570016 (NS_ERROR_XPC_GS_RETURNED_FAILURE)
[nsIJSCID.getService]"  nsresult: "0x80570016
(NS_ERROR_XPC_GS_RETURNED_FAILURE)"  location: "JS frame ::
resource://gre/modules/Services.jsm :: <TOP_LEVEL> :: line 22"  data: no]
resource:///modules/services-sync/engines/clients.js
Failed to import
resource:///modules/services-sync/engines/clients.js:TypeError:
Services.appinfo is undefined
resource:///modules/services-common/utils.js
resource:///modules/services-notifications/service.js
resource:///modules/services-sync/engines/addons.js
Failed to import
resource:///modules/services-sync/engines/addons.js:TypeError:
Services.appinfo is undefined
resource:///modules/services-common/storageservice.js
resource:///modules/services-sync/engines/apps.js
Failed to import
resource:///modules/services-sync/engines/apps.js:TypeError:
Services.appinfo is undefined
resource:///modules/ClusterLib.js
resource:///modules/services-sync/rest.js
Failed to import resource:///modules/services-sync/rest.js:TypeError:
Services.appinfo is undefined
resource:///modules/SpellCheckDictionaryBootstrap.js
resource:///modules/services-sync/engines/forms.js
Failed to import
resource:///modules/services-sync/engines/forms.js:TypeError:
Services.appinfo is undefined
resource:///modules/services-common/log4moz.js
resource:///modules/services-common/stringbundle.js
resource:///modules/MessagePortWorker.js
Failed to import
resource:///modules/MessagePortWorker.js:ReferenceError: AbstractPort is
not defined
resource:///modules/services-sync/main.js
resource:///modules/services-common/rest.js
resource:///modules/distribution.js
resource:///modules/services-sync/engines/history.js
Failed to import
resource:///modules/services-sync/engines/history.js:TypeError:
Services.appinfo is undefined
resource:///modules/services-sync/addonsreconciler.js
Failed to import
resource:///modules/services-sync/addonsreconciler.js:TypeError:
Services.appinfo is undefined
resource:///modules/services-sync/engines/tabs.js
Failed to import
resource:///modules/services-sync/engines/tabs.js:TypeError:
Services.appinfo is undefined
resource:///modules/services-sync/engines/bookmarks.js
Failed to import
resource:///modules/services-sync/engines/bookmarks.js:TypeError:
Services.appinfo is undefined
resource:///modules/services-common/preferences.js
resource:///modules/services-sync/keys.js
Failed to import resource:///modules/services-sync/keys.js:TypeError:
Services.appinfo is undefined
resource:///modules/services-sync/policies.js
Failed to import
resource:///modules/services-sync/policies.js:TypeError:
Services.appinfo is undefined
resource:///modules/services-sync/notifications.js
Failed to import
resource:///modules/services-sync/notifications.js:TypeError:
Services.appinfo is undefined
resource:///modules/services-aitc/storage.js

Any ideas how to get Firefox compiled and installed on -CURRENT?

Regards, STefan



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?50AE1445.2090900>