Page 1 of 1

Howto compile a new kernel

Posted: Mon Jul 06, 2015 12:35 pm
by delph23099
Hello there,

I have downloaded the newest src tree via svn and configured the kernel;

when I type ./configure everything goes right, but when I cd to ../compile/mykernel

and type make cleandepend it stops with the following messages:
make: "../../../conf/../../../conf/kern.mk" line 35: Malformed conditional (${COMPILER_VERSION} < 30500)
make: "../../../conf/../../../conf/kern.mk" line 61: Malformed conditional (${COMPILER_TYPE} == "clang" && ${COMPILER_VERSION} >= 30600)
make: Fatal errors encountered -- cannot continue


I would like to know how to get around this issue or are people not supposed to make a new kernel in GhostBSD?

Thank you in advance

Greetings Antonio

Re: Howto compile a new kernel

Posted: Tue Jul 07, 2015 10:27 am
by delph23099
Hi people,

I have done a little bit of research myself and have read that BSD v10 is switching from gcc compiler to clang;

it has to do with the more permissive licence of clang, BSD cannot tolerate the conditions of the GPLv3 no more.

The practical steps I am trying now for building my own kernel are the following:

- I am compiling the latest clang 3.61 on my box;

- I have added the following lines to /etc/src.conf to make sure that the kernel is compiled with clang:
CC=clang
CXX=clang++
CPP=clang-cpp

I have this information from the porters handbook, so I hope things will work...

Still I would appreciate it to discuss possible solutions to my problem with compiling a new kernel with someone who has some experience on these
matters;

OK, bye, so long;

I will keep you informed about the progress I am making...

THANK YOU IN ADVANCE FOR YOUR TIME

Greetings, Antonio

Re: Howto compile a new kernel

Posted: Wed Jul 08, 2015 8:09 am
by delph23099
Hi there,

I have had no success.

Is there anybody who has successfully built a new kernel for GhostBSD 10.1 Beta?

Thank you in advance!

Greetings Antonio

Re: Howto compile a new kernel

Posted: Sat Jul 11, 2015 5:08 pm
by ericbsd
To compile a kernel you only have to go in /usr/src.

Code: Select all

cd /usr/src
make buildkernel
make installkernel
Also this might be useful for you https://www.freebsd.org/doc/handbook/kernelconfig.html.