How could I add gcc compiler at build world or build kernel stage ??

How could I add gcc compiler at buildworld or buildkernel stage ??
which Makefile I can set this up.

thanks.
 
I believe in /etc/make.conf you can add this line:

Code:
CC=gcc

Or something to that effect. I personally haven't tried it though.
 
Last edited by a moderator:
I think in /etc/make.conf ,CC=gcc is for something like port compiler.
those were after the system was installed.
I also not mean to build system with gcc tool.
I need at system building stage to include gcc tool.


I believe in /etc/make.conf you can add this line:

Code:
CC=gcc

Or something to that effect. I personally haven't tried it though.
 
Last edited by a moderator:
Yeah, Ok. I read about something in the manual pages that might be of interest to you. Take a look at make.conf(5). A quote from the man page as follows:

Code:
PORTS_MODULES
          Set this to the list    of ports you wish to rebuild every
          time    the kernel is built.

Hopefully that helps you.
 
How could I add gcc compiler at buildworld or buildkernel stage ??
which Makefile I can set this up.
I have a hard time understand what you mean here.

If you want to build GCC and make it part of your base system you'd normally set the option WITH_GCC in /etc/src.conf, see also src.conf(5).
 
Code:
20130906:
        The GNU Compiler Collection and C++ standard library (libstdc++)
        are no longer built by default on platforms where clang is the system
        compiler.  You can enable them with the WITH_GCC and WITH_GNUCXX
        options in src.conf.
See /usr/src/UPDATING.
 
I added src.conf with WITH_GCC=yes and WITH_GNUCXX=yes
after build and install kernel,finally I got gcc build in.
Thanks help.

Code:
20130906:
        The GNU Compiler Collection and C++ standard library (libstdc++)
        are no longer built by default on platforms where clang is the system
        compiler.  You can enable them with the WITH_GCC and WITH_GNUCXX
        options in src.conf.
See /usr/src/UPDATING.
 
Back
Top