LWN.net Logo

Mozilla announces HTML5-based phone

Mozilla announces HTML5-based phone

Posted Mar 20, 2012 15:17 UTC (Tue) by stock (guest, #5849)
Parent article: Mozilla announces HTML5-based phone

If the devil were to bring the system down, where would it manifest itself ?
The gcc or the firefox department ?

As many of you adorate Linux desktop users have noticed, be it ubuntu,
kubuntu, Mandriva, OpenSuSE, or even Mac OSX, is that a run-away
version fire, of firefox versions, has started at the mozilla
development campus. Some analysts have already rumored that this is not
just any version pyre, but it has all the aspects and phenomena of a
incendiary fire, i.e. an act of arson. I came across this when trying
to compile firefox version 3.6.24 myself on a freshly installed
Mandriva 2011 desktop, which has the latest and greatest KDE Desktop
Version 4.6.5.

What one then does is download firefox-3.6.24.source.tar.bz2 and
firefox-3.6.24.source.tar.bz2.asc from :

ftp://ftp.mozilla.org/pub/firefox/releases/3.6.24/source/...
ftp://ftp.mozilla.org/pub/firefox/releases/3.6.24/source/...

When unpacking the tar.bz2 ball it creates a directory xulrunner-1.9.2,
which actually should have been named xulrunner-1.9.2.24, as a close
inspection of xulrunner-1.9.2/config/milestone.tx will show you :

# Holds the current milestone.
# Should be in the format of
#
# x.x.x
# x.x.x.x
# x.x.x+
#
# Referenced by milestone.pl.
# Hopefully I'll be able to automate replacement of *all*
# hardcoded milestones in the tree from these two files.
#--------------------------------------------------------

1.9.2.24

firefox-3.6.24 is built from this source tree in a two step compile
process. The first thing one does is to create the xulrunner
development layer by activating --enable-application=xulrunner in the
configure run :

xulrunner-1.9.2-0.3-mdv2011.0.x86_64.rpm
lib64xulrunner-1.9.2-0.3-mdv2011.0.x86_64.rpm
lib64xulrunner-devel-1.9.2-0.3-mdv2011.0.x86_64.rpm
xulrunner-debug-1.9.2-0.3-mdv2011.0.x

after which, firefox-3.6.24-0.3-mdv2011.0.x86_64.rpm is created from
a second compile run by activating --enable-application=browser, which
needs the freshly created xulrunner-devel packages to successfully compile.

No surprise, my problems already started with the first step, the creation
of the xulrunner development gear :

" c++ -o nsID.o -c -I../../dist/system_wrappers -include ../../config/gcc_hidden.h -DOSTYPE=\"Linux2.6.39.4-4\" -DOSARCH=Linux -DTARGET_XPCOM_ABI=\"x86_64-gcc3\" -I./../build -I. -I. -I../../dist/include -I../../dist/include/nsprpub -I/usr/include/nspr4 -I/usr/include/nss -fPIC -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 -O2 -g -frecord-gcc-switches -Wstrict-aliasing=2 -pipe -Wformat -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector --param=ssp-buffer-size=4 -fstack-protector-all -fPIC -fno-strict-aliasing -fshort-wchar -pthread -pipe -DNDEBUG -DTRIMMED -Os -freorder-blocks -fno-reorder-functions -DMOZILLA_CLIENT -include ../../mozilla-config.h -Wp,-MD,.deps/nsID.pp nsID.cpp
nsEnumeratorUtils.cpp:115:27: error: uninitialized const 'EmptyEnumeratorImpl::kInstance' [-fpermissive]
nsEnumeratorUtils.cpp:50:7: note: 'const class EmptyEnumeratorImpl' has no user-provided default constructor
make[4]: *** [nsEnumeratorUtils.o] Error 1
make[4]: *** Waiting for unfinished jobs....
make[4]: Leaving directory `/root/rpmbuild/BUILD/mozilla-1.9.2/xpcom/glue'
make[3]: *** [libs] Error 2
make[3]: Leaving directory `/root/rpmbuild/BUILD/mozilla-1.9.2/xpcom'
make[2]: *** [libs_tier_xpcom] Error 2
make[2]: Leaving directory `/root/rpmbuild/BUILD/mozilla-1.9.2'
make[1]: *** [tier_xpcom] Error 2
make[1]: Leaving directory `/root/rpmbuild/BUILD/mozilla-1.9.2'
make: *** [default] Error 2
error: Bad exit status from /var/tmp/rpm-tmp.80949 (%build)

RPM build errors:
Bad exit status from /var/tmp/rpm-tmp.80949 (%build)
[acer30:root]:(~/rpmbuild/SPECS)# "

Inserting this error

nsEnumeratorUtils.cpp:115:27: error: uninitialized const 'EmptyEnumeratorImpl::kInstance' [-fpermissive]

into google.com brings me to the following bug report ref. {1} :

"FS#23463 - [gcc 4.6] xulrunner cannot be built using gcc 4.6

Attached to Project: Arch Linux
Opened by Frederic Bezies (fredbezies) -
Sunday, 27 March 2011, 06:26 GMT-4
Last edited by Andrea Scarpino (BaSh) -
Saturday, 16 April 2011, 06:57 GMT-4

Details
I wanted this morning to build an homemade version of mozilla
minefield, using trunk source code as I do everyday or so.

But since I installed gcc 4.6 using testing repository, I cannot
get it to be built. So I reported the bug on mozilla bugzilla,
cf https://bugzilla.mozilla.org/show_bug.cgi?id=645469 [ref. {2}]

I wanted to verify if it was related to gcc 4.6 at all.

So, after cleaning ccache cache, I grabbed xulrunner tarball,
and launch build process using makepkg.

And it won't work. Here is the error log :

c++ -o nsWeakReference.o -c -I../../dist/stl_wrappers -I../../dist/system_wrappers -include /home/fred/xulrunner/src/mozilla-2.0/config/gcc_hidden.h -DOSTYPE=\"Linux2.6\" -DOSARCH=Linux -DTARGET_XPCOM_ABI=\"x86_64-gcc3\" -I/home/fred/xulrunner/src/mozilla-2.0/xpcom/glue/../build -I/home/fred/xulrunner/src/mozilla-2.0/xpcom/glue -I. -I../../dist/include -I../../dist/include/nsprpub -I/usr/include/nspr -I/usr/include/nss -fPIC -fno-rtti -fno-exceptions -Wall -Wpointer-arith -Woverloaded-virtual -Wsynth -Wno-ctor-dtor-privacy -Wno-non-virtual-dtor -Wcast-align -Wno-invalid-offsetof -Wno-variadic-macros -Werror=return-type -fno-strict-aliasing -fshort-wchar -pthread -pipe -DNDEBUG -DTRIMMED -Os -freorder-blocks -fomit-frame-pointer -DMOZILLA_CLIENT -include ../../mozilla-config.h -MD -MF .deps/nsWeakReference.pp /home/fred/xulrunner/src/mozilla-2.0/xpcom/glue/nsWeakReference.cpp
/home/fred/xulrunner/src/mozilla-2.0/xpcom/glue/nsEnumeratorUtils.cpp:115:27: erreur: uninitialized const ‘EmptyEnumeratorImpl::kInstance’ [-fpermissive]
/home/fred/xulrunner/src/mozilla-2.0/xpcom/glue/nsEnumeratorUtils.cpp:50:7: note: ‘const class EmptyEnumeratorImpl’ has no user-provided default constructor
make[5]: *** [nsEnumeratorUtils.o] Erreur 1
make[5]: *** Attente des tâches non terminées....
/home/fred/xulrunner/src/mozilla-2.0/xpcom/glue/nsINIParser.cpp: In member function ‘nsresult nsINIParser::Init(nsILocalFile*)’:
/home/fred/xulrunner/src/mozilla-2.0/xpcom/glue/nsINIParser.cpp:91:14: attention : variable ‘rv’ set but not used [-Wunused-but-set-variable]
make[5] : on quitte le répertoire « /home/fred/xulrunner/src/mozilla-2.0/obj-x86_64-unknown-linux-gnu/xpcom/glue »
make[4]: *** [libs] Erreur 2
make[4] : on quitte le répertoire « /home/fred/xulrunner/src/mozilla-2.0/obj-x86_64-unknown-linux-gnu/xpcom »
make[3]: *** [libs_tier_platform] Erreur 2
make[3] : on quitte le répertoire « /home/fred/xulrunner/src/mozilla-2.0/obj-x86_64-unknown-linux-gnu »
make[2]: *** [tier_platform] Erreur 2
make[2] : on quitte le répertoire « /home/fred/xulrunner/src/mozilla-2.0/obj-x86_64-unknown-linux-gnu »
make[1]: *** [default] Erreur 2
make[1] : on quitte le répertoire « /home/fred/xulrunner/src/mozilla-2.0/obj-x86_64-unknown-linux-gnu »
make: *** [build] Erreur 2
==> ERREUR: Une erreur s'est produite dans build().
Abandon...

Additional info:
[fred@fredo-arch ~]$ pacman -Qi gcc | grep Version
Version : 4.6.0-1

Steps to reproduce:

Upgrade gcc version and try to build xulrunner.

---------------------------------------------------------------------
Comments (5)
Related Tasks (0/0)

Comment by Rémy Oudompheng (remyoudompheng) -
Sunday, 27 March 2011, 06:38 GMT-4
Probably related to "G++ no longer allows objects of
const-qualified type to be default initialized unless the type
has a user-declared default constructor." in latest GCC changes.
g++ has become more strict in its checking, add -fpermissive to
your CXXFLAGS to work around this.

Comment by Frederic Bezies (fredbezies) -
Sunday, 27 March 2011, 06:44 GMT-4
Ok. Will add it to my .mozconfig and I will tell you.

Comment by Frederic Bezies (fredbezies) -
Sunday, 27 March 2011, 07:55 GMT-4
It worked. Thanks for the tip !

I think they'll be more software which will be broken.

Comment by Allan McRae (Allan) - Thursday, 31 March 2011, 08:08 GMT-4

Assignment removed

Unassigning me. This is not a gcc bug.

Comment by Frederic Bezies (fredbezies) -
Monday, 04 April 2011, 05:11 GMT-4
Well, it is a mozilla bug. Closing ?"

Frederic Bezies claims its a mozilla bug, and he is right when pointing
at ref. {2}. Strange thing is that any c++ newcomer could have seen that
there was a severe coding error inside xpcom/glue/nsEnumeratorUtils.cpp:115
which that same average c++ newcomer could have easily fixed :
change the faulty line

const EmptyEnumeratorImpl EmptyEnumeratorImpl::kInstance

into

const EmptyEnumeratorImpl EmptyEnumeratorImpl::kInstance = EmptyEnumeratorImpl();

What next happens is very interesting and intriguing at the same time.
Bugreport ref. {2} is closed and any and all further discussion is
redirected to Bugreport ref. {3}, a very common thing todo, obviously :

"Mike Hommey [:glandium] 2011-04-30 02:35:11 PDT

*** This bug has been marked as a duplicate of bug 623126 ***"

However when reading ref. {3} some very strange new speak is uttered by
a guy by the name of Benjamin Smedberg :

"Benjamin Smedberg [:bsmedberg] 2011-01-05 05:54:24 PST

Just as with the other bug, the missing constructor is
intentional so that GCC does not emit a initialization function.
Absent a detailed explanation from a language lawyer, I don't
think I want to accept this change."

So instead of simply fixing the xulrunner c++ code, Smedberg tells his
audience, on International Workers' Day, May 1st, that he intentionally
inserted this missing constructor. Wow, how about that! All are gently
redirected 'upstream', and start playing with xulrunner-2.0 .... Now
thats a very cunning way to simply hard-ax cut-off any further
development on the xulrunner-1.9.2 branch, which is by the way exactly
the firefox-3.6.xx branch of webbrowsers .... So who is this Benjamin
Smedberg anyway, and how can he get away which such impyrialistic
behavior ??

"XUL:Benjamin Smedberg
https://wiki.mozilla.org/XUL:Benjamin_Smedberg

Home » XUL:Benjamin_Smedberg

Benjamin Smedberg is a full-time hacker who used to be a full-time
choir director and organist.

website: http://benjamin.smedbergs.us/ email: benjamin@smedbergs.us

He is currently employed by the mozdev group, a consulting company
specializing in mozilla-based technologies. As a Mozilla developer,
he focuses on architectural issues and XUL web applications.

In his former life, he was director of music at St. Patrick Church,
Washington, DC. "

"User:Benjamin Smedberg
https://developer.mozilla.org/User:Benjamin_Smedberg

Recent Activity

C++ Portability Guide
Feb 9, 2012
Remove mention of PRBool, clean up NSPR type language;
51 words added, 134 words removed

Interface documentation status
Jan 11, 2012
6 words removed

The Thread Manager
Jan 11, 2012
33 words added, 967 words removed

Making cross-thread calls using runnables
Jan 11, 2012
12 words added

Making cross-thread calls using runnables
Jan 11, 2012
This should be finished now except for a "See Also" section;
389 words added, 97 words removed

Making cross-thread calls using runnables
Jan 11, 2012
page created, 260 words added

Interfaces
Jan 11, 2012
6 words removed

nsISupports proxies
Jan 11, 2012
XPCOM proxies, removed for sanity.; 71 words added, 1231 words removed

Embedding Mozilla in a Java Application using JavaXPCOM
Jan 11, 2012
30 words added

Language Bindings
Jan 9, 2012
JavaXPCOM is mostly-dead; 11 words added, 17 words removed"

http://benjamin.smedbergs.us/blog/

Robert
PS.
{1} FS#23463 - [gcc 4.6] xulrunner cannot be built using gcc 4.6
by Frederic Bezies, Sunday, 27 March 2011, 06:26 GMT-4
https://bugs.archlinux.org/task/23463

{2} Bug 645469 - [gcc 4.6] Build process is broken while working on
embedding/browser/gtk/src/EmbedPrivate.cpp
by Frederic Bezies, 2011-03-27 02:33:26 PDT
https://bugzilla.mozilla.org/show_bug.cgi?id=645469

{3} Bug 623126 - Add constructor for nsDebugImpl, nsTraceRefcntImpl,
EmptyEnumeratorImpl, and nsSimpleUnicharStreamFactory to placate CLang
by Rafael Ávila de Espíndola, 2011-01-04 20:11:54 PST
https://bugzilla.mozilla.org/show_bug.cgi?id=623126

{4} Debian Bug report logs - #624969
icedove: FTBFS: nsEnumeratorUtils.cpp:115:27: error: uninitialized
const 'EmptyEnumeratorImpl::kInstance' [-fpermissive]
by Lucas Nussbaum, Mon, 2 May 2011 12:50:16 UTC
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=624969
--
Robert M. Stockmann - RHCE
Network Engineer - UNIX/Linux Specialist
crashrecovery.org stock@stokkie.net


(Log in to post comments)

Mozilla announces HTML5-based phone

Posted Mar 23, 2012 13:55 UTC (Fri) by stock (guest, #5849) [Link]

I finally managed to get the browser to compile, the
end result can be found here :

http://crashrecovery.org/firefox/mdv2011/

Robert
--
Robert M. Stockmann - RHCE
Network Engineer - UNIX/Linux Specialist
crashrecovery.org stock@stokkie.net

Copyright © 2013, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds