Closed
Bug 385593
Opened 17 years ago
Closed 17 years ago
32-bit build fails on 64-bit Linux systems
Categories
(Firefox Build System :: General, defect)
Tracking
(Not tracked)
RESOLVED
DUPLICATE
of bug 372428
People
(Reporter: wgianopoulos, Assigned: wgianopoulos)
Details
Attachments
(1 file, 1 obsolete file)
1006 bytes,
patch
|
Details | Diff | Splinter Review |
I am trying to build both 32-bit and 64-bit Firefox executables using a Linux laptop with an AMD g4-bit processor under Fedora Core 6. Gor the 32-bit build I have the following additional lines specified in my .mozconfig file: export CFLAGS=-m32 export CXXFLAGS=-m32 export PKG_CONFIG_PATH=/usr/lib/pkgconfig ac_add_options --x-libraries=/usr/lib The CFLAGS and CXXLFAGS changes are failry self explanatory. Defining the PKG_CONFIG_PATH makes pkg-config look first aht e 32-bit package directory before the 64-bit one. This makes configure find the correct flags and libraries for the 32 bit versions instead of the 64-bit versions. Specifying X-libraries in necessary because if you omit this line configure ends up deciding to use /usr/lib64 for this, which is obviously not what you would want for a 32-bit build. One would think this should be sufficient to create a 32-bit build, however, there are places in the build system where the value of OS_TEST is checked and if it is set to x86_64 it is assumed a 64-bit build is being done. I tried setting the --disable-64bit configure option, but this did not help either. The value of OS_TEST ends up being the output of a uname -m command and is not affected by either the value configure calculates for HAVE_64BIT_OS or the value you configure for --disable-64bit. The build error I receive is as follows: xptcinvoke_x86_64_linux.cpp c++ -o xptcinvoke_x86_64_linux.o -c -I../../../../../../dist/include/system_wrappers -include /home/wag/mozilla/trunk/config/gcc_hidden.h -DMOZILLA_INTERNAL_API -DOSTYPE=\"Linux2.6.18-1.2869\" -DOSARCH=Linux -DBUILD_ID=2007062305 -DEXPORT_XPTC_API -D_IMPL_NS_COM -I/home/wag/mozilla/trunk/xpcom/reflect/xptcall/src/md/unix/../.. -I/home/wag/mozilla/trunk/xpcom/reflect/xptcall/src/md/unix/../../../../xptinfo/src -I../../../../../../dist/include/string -I../../../../../../dist/include -I../../../../../../dist/include/xpcom -I../../../../../../dist/include/nspr -DMOZ_PNG_READ -DMOZ_PNG_WRITE -fPIC -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 -m32 -fshort-wchar -pthread -pipe -DNDEBUG -DTRIMMED -Os -freorder-blocks -fno-reorder-functions -gstabs+ -DMOZILLA_CLIENT -include ../../../../../../mozilla-config.h -Wp,-MD,.deps/xptcinvoke_x86_64_linux.pp /home/wag/mozilla/trunk/xpcom/reflect/xptcall/src/md/unix/xptcinvoke_x86_64_linux.cpp ../../../../../../dist/include/xpcom/xptinfo.h: In member function ‘const nsXPTCMiniVariant* nsXPTConstant::GetValue() const’: ../../../../../../dist/include/xpcom/xptinfo.h:220: warning: type-punning to incomplete type might break strict-aliasing rules /home/wag/mozilla/trunk/xpcom/reflect/xptcall/src/md/unix/xptcinvoke_x86_64_linux.cpp: In function ‘nsresult NS_InvokeByIndex_P(nsISupports*, PRUint32, PRUint32, nsXPTCVariant*)’: /home/wag/mozilla/trunk/xpcom/reflect/xptcall/src/md/unix/xptcinvoke_x86_64_linux.cpp:82: warning: ‘value’ may be used uninitialized in this function /home/wag/mozilla/trunk/xpcom/reflect/xptcall/src/md/unix/xptcinvoke_x86_64_linux.cpp:152: error: invalid register name for ‘d0’ /home/wag/mozilla/trunk/xpcom/reflect/xptcall/src/md/unix/xptcinvoke_x86_64_linux.cpp:153: error: invalid register name for ‘d1’ /home/wag/mozilla/trunk/xpcom/reflect/xptcall/src/md/unix/xptcinvoke_x86_64_linux.cpp:154: error: invalid register name for ‘d2’ /home/wag/mozilla/trunk/xpcom/reflect/xptcall/src/md/unix/xptcinvoke_x86_64_linux.cpp:155: error: invalid register name for ‘d3’ /home/wag/mozilla/trunk/xpcom/reflect/xptcall/src/md/unix/xptcinvoke_x86_64_linux.cpp:156: error: invalid register name for ‘d4’ /home/wag/mozilla/trunk/xpcom/reflect/xptcall/src/md/unix/xptcinvoke_x86_64_linux.cpp:157: error: invalid register name for ‘d5’ /home/wag/mozilla/trunk/xpcom/reflect/xptcall/src/md/unix/xptcinvoke_x86_64_linux.cpp:158: error: invalid register name for ‘d6’ /home/wag/mozilla/trunk/xpcom/reflect/xptcall/src/md/unix/xptcinvoke_x86_64_linux.cpp:159: error: invalid register name for ‘d7’ /home/wag/mozilla/trunk/xpcom/reflect/xptcall/src/md/unix/xptcinvoke_x86_64_linux.cpp:181: error: invalid register name for ‘a4’ /home/wag/mozilla/trunk/xpcom/reflect/xptcall/src/md/unix/xptcinvoke_x86_64_linux.cpp:182: error: invalid register name for ‘a5’ gmake[9]: *** [xptcinvoke_x86_64_linux.o] Error 1 gmake[9]: Leaving directory `/home/wag/mozilla/trunk/fx32-obj/xpcom/reflect/xptcall/src/md/unix' gmake[8]: *** [libs] Error 2 gmake[8]: Leaving directory `/home/wag/mozilla/trunk/fx32-obj/xpcom/reflect/xptcall/src/md' gmake[7]: *** [libs] Error 2 gmake[7]: Leaving directory `/home/wag/mozilla/trunk/fx32-obj/xpcom/reflect/xptcall/src' gmake[6]: *** [libs] Error 2 gmake[6]: Leaving directory `/home/wag/mozilla/trunk/fx32-obj/xpcom/reflect/xptcall' gmake[5]: *** [libs] Error 2 gmake[5]: Leaving directory `/home/wag/mozilla/trunk/fx32-obj/xpcom/reflect' gmake[4]: *** [libs] Error 2 gmake[4]: Leaving directory `/home/wag/mozilla/trunk/fx32-obj/xpcom' gmake[3]: *** [libs_tier_xpcom] Error 2 gmake[3]: Leaving directory `/home/wag/mozilla/trunk/fx32-obj' gmake[2]: *** [tier_xpcom] Error 2 gmake[2]: Leaving directory `/home/wag/mozilla/trunk/fx32-obj' make[1]: *** [default] Error 2 make[1]: Leaving directory `/home/wag/mozilla/trunk/fx32-obj' make: *** [build] Error 2
Assignee | ||
Comment 1•17 years ago
|
||
I have been successfully using this workaround for a couple of weeks in order to produce the 32-bit build. I am not at all sure it is the correct fix. What it does is that when configure determines it is not doing a 64-bit build, it checks and if OS_TEST is set to x86_64 it changes it to i686. The build continues to completion with this patch applied.
Assignee | ||
Updated•17 years ago
|
Attachment #269528 -
Attachment description: woraraound → workaround
Assignee | ||
Comment 2•17 years ago
|
||
I take it I am really supposed to change this in configure.in and let configure get remade by egg. I also added a comment.
Attachment #269528 -
Attachment is obsolete: true
Attachment #269534 -
Flags: review?
Assignee | ||
Updated•17 years ago
|
Attachment #269534 -
Flags: review? → review?(benjamin)
Assignee | ||
Updated•17 years ago
|
Status: NEW → ASSIGNED
Assignee | ||
Updated•17 years ago
|
Assignee: nobody → wgianopoulos
Status: ASSIGNED → NEW
Comment 3•17 years ago
|
||
Comment on attachment 269534 [details] [diff] [review] configure.in this time I'm pretty sure this isn't right, but I don't know what is. Asking cls.
Attachment #269534 -
Flags: review?(benjamin) → review?(cls)
Assignee | ||
Comment 4•17 years ago
|
||
I'm pretty sure this is not right either. I originally tried doing this with the more complicated cross compile definitions rather than by trying to get it to happen more automatically. That resulted in the following error which I could net figure out. ../../../config/./nsinstall -R -m 444 /home/wag/mozilla/trunk/nsprpub/pr/include/md/_aix32.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_aix64.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_beos.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_bsdi.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_darwin.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_dgux.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_freebsd.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_hpux32.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_hpux64.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_irix32.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_irix64.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_linux.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_ncr.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_nec.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_netbsd.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_nextstep.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_nto.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_openbsd.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_openvms.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_os2.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_osf1.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_qnx.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_reliantunix.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_rhapsody.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_riscos.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_scoos.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_solaris.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_sony.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_sunos4.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_unixware7.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_unixware.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_win16.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_win95.cfg /home/wag/mozilla/trunk/nsprpub/pr/include/md/_winnt.cfg /home/wag/mozilla/trunk/fxcc-obj/dist/include/nspr/md gmake[6]: *** [export] Segmentation fault
Status: NEW → ASSIGNED
Comment on attachment 269534 [details] [diff] [review] configure.in this time Yeah, it seems...incomplete. I think I prefer the fix in bug 372428.
Attachment #269534 -
Flags: review?(cls)
Status: ASSIGNED → RESOLVED
Closed: 17 years ago
Resolution: --- → DUPLICATE
Updated•6 years ago
|
Product: Core → Firefox Build System
You need to log in
before you can comment on or make changes to this bug.
Description
•