public inbox for gentoo-dev@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-dev] Kernel calls gcc directly: fine?
@ 2012-08-12 14:19 Agostino Sarubbo
  2012-08-12 14:32 ` Jeroen Roovers
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Agostino Sarubbo @ 2012-08-12 14:19 UTC (permalink / raw
  To: gentoo-dev

[-- Attachment #1: Type: text/plain, Size: 1466 bytes --]

If you try to launch make V=1 from the kernel source directory you will see:

 gcc -Wp,-MD,scripts/mod/.empty.o.d  -nostdinc -isystem /usr/lib/gcc/x86_64-
pc-linux-gnu/4.5.3/include -I/usr/src/linux-3.3.8-gentoo/arch/x86/include -
Iarch/x86/include/generated -Iinclude  -include /usr/src/linux-3.3.8-
gentoo/include/linux/kconfig.h -D__KERNEL__ -Wall -Wundef -Wstrict-prototypes 
-Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-
declaration -Wno-format-security -fno-delete-null-pointer-checks -O2 -m64 -
march=core2 -mno-red-zone -mcmodel=kernel -funit-at-a-time -maccumulate-
outgoing-args -DCONFIG_AS_CFI=1 -DCONFIG_AS_CFI_SIGNAL_FRAME=1 -
DCONFIG_AS_CFI_SECTIONS=1 -DCONFIG_AS_FXSAVEQ=1 -pipe -Wno-sign-compare -fno-
asynchronous-unwind-tables -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -Wframe-
larger-than=2048 -fno-stack-protector -fomit-frame-pointer -Wdeclaration-
after-statement -Wno-pointer-sign -fno-strict-overflow -fconserve-stack -
DCC_HAVE_ASM_GOTO    -D"KBUILD_STR(s)=#s" -
D"KBUILD_BASENAME=KBUILD_STR(empty)"  -D"KBUILD_MODNAME=KBUILD_STR(empty)" -c 
-o scripts/mod/empty.o scripts/mod/empty.c


So it calls gcc directly.

I see we don't like gcc called directly from the tracker[1], but this is for 
packages/ebuild. Should this bug block that tracker or it is invalid?


[1]: https://bugs.gentoo.org/show_bug.cgi?id=cc-directly

-- 
Agostino Sarubbo / ago -at- gentoo.org
Gentoo/AMD64 Arch Security Liaison
GPG: 0x7CD2DC5D

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 490 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [gentoo-dev] Kernel calls gcc directly: fine?
  2012-08-12 14:19 [gentoo-dev] Kernel calls gcc directly: fine? Agostino Sarubbo
@ 2012-08-12 14:32 ` Jeroen Roovers
  2012-08-12 19:59 ` Doug Goldstein
  2012-08-13  2:24 ` [gentoo-dev] " Ryan Hill
  2 siblings, 0 replies; 4+ messages in thread
From: Jeroen Roovers @ 2012-08-12 14:32 UTC (permalink / raw
  To: gentoo-dev

On Sun, 12 Aug 2012 16:19:59 +0200
Agostino Sarubbo <ago@gentoo.org> wrote:

> If you try to launch make V=1 from the kernel source directory you
> will see:

> snip <

> So it calls gcc directly.

Yes. That is called a default.

Set CC on the make command line or set CONFIG_CROSS_COMPILE through
make *config if you don't like the default.

> I see we don't like gcc called directly from the tracker[1], but this
> is for packages/ebuild. Should this bug block that tracker or it is
> invalid?

What bug (report)?

The kernel build system cannot guess what compiler you want to use, so
it defaults to CC=gcc. It's a feature.


     jer


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [gentoo-dev] Kernel calls gcc directly: fine?
  2012-08-12 14:19 [gentoo-dev] Kernel calls gcc directly: fine? Agostino Sarubbo
  2012-08-12 14:32 ` Jeroen Roovers
@ 2012-08-12 19:59 ` Doug Goldstein
  2012-08-13  2:24 ` [gentoo-dev] " Ryan Hill
  2 siblings, 0 replies; 4+ messages in thread
From: Doug Goldstein @ 2012-08-12 19:59 UTC (permalink / raw
  To: gentoo-dev

On Sun, Aug 12, 2012 at 9:19 AM, Agostino Sarubbo <ago@gentoo.org> wrote:
> If you try to launch make V=1 from the kernel source directory you will see:
>
>  gcc -Wp,-MD,scripts/mod/.empty.o.d  -nostdinc -isystem /usr/lib/gcc/x86_64-
> pc-linux-gnu/4.5.3/include -I/usr/src/linux-3.3.8-gentoo/arch/x86/include -
> Iarch/x86/include/generated -Iinclude  -include /usr/src/linux-3.3.8-
> gentoo/include/linux/kconfig.h -D__KERNEL__ -Wall -Wundef -Wstrict-prototypes
> -Wno-trigraphs -fno-strict-aliasing -fno-common -Werror-implicit-function-
> declaration -Wno-format-security -fno-delete-null-pointer-checks -O2 -m64 -
> march=core2 -mno-red-zone -mcmodel=kernel -funit-at-a-time -maccumulate-
> outgoing-args -DCONFIG_AS_CFI=1 -DCONFIG_AS_CFI_SIGNAL_FRAME=1 -
> DCONFIG_AS_CFI_SECTIONS=1 -DCONFIG_AS_FXSAVEQ=1 -pipe -Wno-sign-compare -fno-
> asynchronous-unwind-tables -mno-sse -mno-mmx -mno-sse2 -mno-3dnow -Wframe-
> larger-than=2048 -fno-stack-protector -fomit-frame-pointer -Wdeclaration-
> after-statement -Wno-pointer-sign -fno-strict-overflow -fconserve-stack -
> DCC_HAVE_ASM_GOTO    -D"KBUILD_STR(s)=#s" -
> D"KBUILD_BASENAME=KBUILD_STR(empty)"  -D"KBUILD_MODNAME=KBUILD_STR(empty)" -c
> -o scripts/mod/empty.o scripts/mod/empty.c
>
>
> So it calls gcc directly.
>
> I see we don't like gcc called directly from the tracker[1], but this is for
> packages/ebuild. Should this bug block that tracker or it is invalid?
>
>
> [1]: https://bugs.gentoo.org/show_bug.cgi?id=cc-directly
>

Its invalid. Kbuild has its own documented way to do cross compiles
and replace out the compiler (granted only gcc works for building the
official Linux tree, there has been efforts to use clang and icc but
those are not mainlined).

-- 
Doug Goldstein


^ permalink raw reply	[flat|nested] 4+ messages in thread

* [gentoo-dev] Re: Kernel calls gcc directly: fine?
  2012-08-12 14:19 [gentoo-dev] Kernel calls gcc directly: fine? Agostino Sarubbo
  2012-08-12 14:32 ` Jeroen Roovers
  2012-08-12 19:59 ` Doug Goldstein
@ 2012-08-13  2:24 ` Ryan Hill
  2 siblings, 0 replies; 4+ messages in thread
From: Ryan Hill @ 2012-08-13  2:24 UTC (permalink / raw
  To: gentoo-dev

[-- Attachment #1: Type: text/plain, Size: 657 bytes --]

On Sun, 12 Aug 2012 16:19:59 +0200
Agostino Sarubbo <ago@gentoo.org> wrote:

> So it calls gcc directly.
> 
> I see we don't like gcc called directly from the tracker[1], but this is for 
> packages/ebuild. Should this bug block that tracker or it is invalid?
> 
> 
> [1]: https://bugs.gentoo.org/show_bug.cgi?id=cc-directly
 
We have no business controlling how software is built outside the package
manager.  This is a make default, it's not kernel specific.


-- 
gcc-porting                  you were never more here, expanse getting broader
toolchain, wxwidgets               though bigger boats been done by less water
@ gentoo.org

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 198 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2012-08-13  2:15 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-08-12 14:19 [gentoo-dev] Kernel calls gcc directly: fine? Agostino Sarubbo
2012-08-12 14:32 ` Jeroen Roovers
2012-08-12 19:59 ` Doug Goldstein
2012-08-13  2:24 ` [gentoo-dev] " Ryan Hill

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox