Date: Sun, 16 Aug 2009 13:54:47 +0200 From: Andreas Tobler <andreast-list@fgznet.ch> To: Joe Marcus Clarke <marcus@marcuscom.com> Cc: gecko@freebsd.org Subject: Re: firefox3 under powerpc not building Message-ID: <4A87F387.507@fgznet.ch> In-Reply-To: <1250359762.23396.28.camel@shumai.marcuscom.com> References: <4A7F1AB0.9040605@fgznet.ch> <4A807B1B.20605@fgznet.ch> <1250359762.23396.28.camel@shumai.marcuscom.com>
next in thread | previous in thread | raw e-mail | index | archive | help
This is a multi-part message in MIME format. --------------080205010802050808030005 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Joe Marcus Clarke wrote: > On Mon, 2009-08-10 at 21:55 +0200, Andreas Tobler wrote: >> Hi again, >> >> replying to myself. >> >> >> Andreas Tobler wrote: >> >>> I can not build firefox3 (3.0.13 and up) under FreeBSD -CURRENT. As far >>> as I tracked down it is an issue in the firefox sources itself. >>> >>> The last working build I had was 3.0.10. >>> >>> Here in this area it breaks: >>> >>> http://mxr.mozilla.org/mozilla1.9.1/diff?file=/security/nss/lib/freebl/Makefile&diffvar=mozilla1.8.0 >>> >>> The below snippet does somehow not work. >>> ----- >>> # some code wants _X86_ defined for intel CPUs. >>> # coreconf does this for windows, but not for Linux, FreeBSD, etc. >>> ifeq (,$(filter-out x86 x86_64,$(CPU_ARCH))) >>> ifneq (,$(filter-out WIN%,$(OS_TARGET))) >>> DEFINES += -D_X86_ >>> endif >>> endif >>> ----- >> It does not work on powerpc since the CPU_ARCH is set to x86 in >> security/coreconf/FreeBSD.mk, gah! >> >>> On powerpc I get the -D_X86_ passed to the compile options, very bad. >>> But I do not understand why. Might be that the first filter-out does not >>> work as expected? >>> >>> I compared with an x86 build and with an x86_64 build. On the x86 it >>> works as expected. But also under der x86_64 it does not do what I >>> expect. Under x86_64 I'd expect the -D_X86_ in the compile options, right? >> The x86_64 case is also clear now, the CPU_ARCH is set to amd64, so the >> -D_X86_ is not set. We might need a patch to >> security/nss/lib/freebl/Makefile which also includes the amd64 to the >> first filter-out above? Like this one: > > Thanks for these patches. Can you resend them as attachments (or post > them) so they can be easily extracted? Here it is, the powerpc one. It is against 3.0.13 source base. The amd64 I did not follow up since it does build, with or without -D_X86_ on amd64. Andreas --------------080205010802050808030005 Content-Type: text/plain; x-mac-type="54455854"; x-mac-creator="74657874"; name="patch-security-coreconf-FreeBSD.mk" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="patch-security-coreconf-FreeBSD.mk" --- security/coreconf/FreeBSD.mk.orig 2008-07-12 16:28:59.000000000 +0200 +++ security/coreconf/FreeBSD.mk 2009-08-10 22:30:54.000000000 +0200 @@ -45,8 +45,15 @@ ifeq ($(OS_TEST),alpha) CPU_ARCH = alpha else +ifeq ($(OS_TEST),amd64) +CPU_ARCH = amd64 +else +ifeq ($(OS_TEST),powerpc) +CPU_ARCH = powerpc +else CPU_ARCH = x86 endif +endif OS_CFLAGS = $(DSO_CFLAGS) -ansi -Wall -Wno-switch -DFREEBSD -DHAVE_STRERROR -DHAVE_BSD_FLOCK @@ -73,7 +80,7 @@ DLL_SUFFIX = so.1.0 endif -MKSHLIB = $(CC) $(DSO_LDOPTS) +MKSHLIB = $(CC) -Wl,-Bsymbolic -lc $(DSO_LDOPTS) -o $@ ifdef MAPFILE MKSHLIB += -Wl,--version-script,$(MAPFILE) endif @@ -82,4 +89,4 @@ G++INCLUDES = -I/usr/include/g++ -INCLUDES += -I/usr/X11R6/include +#INCLUDES += -I/usr/local/include --------------080205010802050808030005--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4A87F387.507>