From owner-freebsd-emulation@FreeBSD.ORG Tue Jul 6 08:00:37 2010 Return-Path: Delivered-To: freebsd-emulation@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8338F1065670; Tue, 6 Jul 2010 08:00:37 +0000 (UTC) (envelope-from decke@FreeBSD.org) Received: from mail.itac.at (mail.itac.at [91.205.172.9]) by mx1.freebsd.org (Postfix) with ESMTP id DE6EB8FC1D; Tue, 6 Jul 2010 08:00:36 +0000 (UTC) Received: from [91.205.172.21] (helo=webmail.bluelife.at) by mail.itac.at with esmtpa (Exim 4.63) (envelope-from ) id 1OW351-00047c-5b; Tue, 06 Jul 2010 10:00:35 +0200 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Date: Tue, 06 Jul 2010 10:00:35 +0200 From: Bernhard Froehlich To: Andriy Gapon In-Reply-To: <4C32DEF6.1020409@freebsd.org> References: <4C0DF92C.9020204@icyb.net.ua> <4C32DEF6.1020409@freebsd.org> Message-ID: <84bf85053cb54d393398f37c0861d1fb@bluelife.at> X-Sender: decke@FreeBSD.org User-Agent: RoundCube Webmail/0.4-beta X-Spam-Score: -0.6 (/) X-Spam-Report: Spam detection software, running on the system "mail.itac.at", has identified this incoming email as possible spam. The original message has been attached to this so you can view it (if it isn't spam) or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: On Tue, 06 Jul 2010 10:44:54 +0300, Andriy Gapon wrote: > on 08/06/2010 11:02 Andriy Gapon said the following: >> I am trying to compile my ports with gcc44 instead of a base gcc. >> It seems that currently VirtualBox build system assumes that FreeBSD >> means base >> GCC only. For example, it unconditionally uses -fno-format-extensions >> and >> -fformat-extensions options. Those are extensions available in base >> GCC, but >> not in ports GCCs (at least for time being). >> I am not proficient in KBuild, so I don't have a patch, but I can make a >> suggestion that for these options CC and CXX should be tested in >> addition to >> KBUILD_TARGET. >> >> Additionally, two files seem to miss some include directives because of >> GCC >> changes outlined here: >> http://gcc.gnu.org/gcc-4.3/porting_to.html > > I would like to remind that the reported issues are still there with > VirtualBox > 3.2.6 and something like the following patch is still required. > > --- src/VBox/Main/freebsd/NetIf-freebsd.cpp.orig 2010-07-06 > 10:31:07.328680775 +0300 > +++ src/VBox/Main/freebsd/NetIf-freebsd.cpp 2010-07-06 10:31:28.000532682 > +0300 > @@ -44, 6 +44, 7 @@ > #include > > #include > +#include > #include > #include > > --- src/VBox/Main/freebsd/HostHardwareFreeBSD.cpp.orig 2010-07-06 > 10:29:23.130414466 +0300 > +++ src/VBox/Main/freebsd/HostHardwareFreeBSD.cpp 2010-07-06 > 10:32:59.702484321 > +0300 > @@ -40, 6 +40, 7 @@ > # include > # include > # include > +# include > # include > # include > # include > > > And probably the following should just work too. > > --- Config.kmk.orig 2010-06-25 17:23:52.000000000 +0300 > +++ Config.kmk 2010-07-05 20:59:21.772469818 +0300 > @@ -2612, 7 +2613, 7 @@ > $(VBOX_GCC_WARN) -Wpointer-arith -Winline $(VBOX_GCC_Wno-pointer-sign) \ > -Wstrict-prototypes -Wmissing-prototypes -Wstrict-prototypes > -Wnested-externs \ > [...] Content analysis details: (-0.6 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.4 ALL_TRUSTED Passed through trusted hosts only via SMTP 0.9 AWL AWL: From: address is in the auto white-list Cc: freebsd-emulation@freebsd.org, vbox@freebsd.org Subject: Re: emulators/virtualbox-ose vs non-base gcc X-BeenThere: freebsd-emulation@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Development of Emulators of other operating systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 06 Jul 2010 08:00:37 -0000 On Tue, 06 Jul 2010 10:44:54 +0300, Andriy Gapon wrote: > on 08/06/2010 11:02 Andriy Gapon said the following: >> I am trying to compile my ports with gcc44 instead of a base gcc. >> It seems that currently VirtualBox build system assumes that FreeBSD >> means base >> GCC only. For example, it unconditionally uses -fno-format-extensions >> and >> -fformat-extensions options. Those are extensions available in base >> GCC, but >> not in ports GCCs (at least for time being). >> I am not proficient in KBuild, so I don't have a patch, but I can make a >> suggestion that for these options CC and CXX should be tested in >> addition to >> KBUILD_TARGET. >> >> Additionally, two files seem to miss some include directives because of >> GCC >> changes outlined here: >> http://gcc.gnu.org/gcc-4.3/porting_to.html > > I would like to remind that the reported issues are still there with > VirtualBox > 3.2.6 and something like the following patch is still required. > > --- src/VBox/Main/freebsd/NetIf-freebsd.cpp.orig 2010-07-06 > 10:31:07.328680775 +0300 > +++ src/VBox/Main/freebsd/NetIf-freebsd.cpp 2010-07-06 10:31:28.000532682 > +0300 > @@ -44,6 +44,7 @@ > #include > > #include > +#include > #include > #include > > --- src/VBox/Main/freebsd/HostHardwareFreeBSD.cpp.orig 2010-07-06 > 10:29:23.130414466 +0300 > +++ src/VBox/Main/freebsd/HostHardwareFreeBSD.cpp 2010-07-06 > 10:32:59.702484321 > +0300 > @@ -40,6 +40,7 @@ > # include > # include > # include > +# include > # include > # include > # include > > > And probably the following should just work too. > > --- Config.kmk.orig 2010-06-25 17:23:52.000000000 +0300 > +++ Config.kmk 2010-07-05 20:59:21.772469818 +0300 > @@ -2612,7 +2613,7 @@ > $(VBOX_GCC_WARN) -Wpointer-arith -Winline $(VBOX_GCC_Wno-pointer-sign) \ > -Wstrict-prototypes -Wmissing-prototypes -Wstrict-prototypes > -Wnested-externs \ > -Wimplicit-function-declaration -Werror-implicit-function-declaration \ > - -O2 -fformat-extensions -ffreestanding -fno-strict-aliasing -fno-common > -finline-limit=8000 \ > + -O2 -ffreestanding -fno-strict-aliasing -fno-common -finline-limit=8000 \ > $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_R0_OPT) $(VBOX_GCC_R0_FP) \ > -nostdinc -std=c99 > TEMPLATE_VBOXR0DRV_CFLAGS.x86 = -m32 -mno-align-long-strings > -mpreferred-stack-boundary=2 -mno-mmx -mno-3dnow -mno-sse -mno-sse2 > @@ -2621,7 +2622,7 @@ > -mno-3dnow -msoft-float -fno-asynchronous-unwind-tables -Wundef > TEMPLATE_VBOXR0DRV_CXXFLAGS = -fno-exceptions -fno-rtti \ > $(VBOX_GCC_WARN) -Wpointer-arith -Winline \ > - -O2 -fno-format-extensions -fno-strict-aliasing -fno-common > -finline-limit=8000 \ > + -O2 -fno-strict-aliasing -fno-common -finline-limit=8000 \ > $(VBOX_GCC_fno-stack-protector) $(VBOX_GCC_R0_OPT) $(VBOX_GCC_R0_FP) \ > -nostdinc > TEMPLATE_VBOXR0DRV_CXXFLAGS.x86 = $(TEMPLATE_VBOXR0DRV_CFLAGS.x86) Thanks for the patch. We are aware of it and I already have it on my todo so it will just take some time. -- Bernhard Froehlich http://www.bluelife.at/