Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 5 May 2018 12:38:37 +0200
From:      bryn1u85 <m.bryn1u@gmail.com>
To:        Rozhuk Ivan <rozhuk.im@gmail.com>
Cc:        freebsd-current@freebsd.org, FreeBSD Hackers <freebsd-hackers@freebsd.org>, bdrewery@freebsd.org
Subject:   Re: SSP_CFLAGS for kernel
Message-ID:  <CAHsHv-ZvycRJyta1cOS9xS4QP0Pj2FYqcf%2BdOO6Ns5Pw0RSFgg@mail.gmail.com>
In-Reply-To: <20180505035931.33120d74@gmail.com>
References:  <20180505035931.33120d74@gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Hey,
Don't touch src.conf

Entry for make.conf should looks like below:

WITH_SSP_PORTS=YES

SSP_CFLAGS=-fstack-protector-all

SSP_CXXFLAGS=-fstack-protector-all

It's working for me.

2018-05-05 2:59 GMT+02:00 Rozhuk Ivan <rozhuk.im@gmail.com>:

> Hi!
>
> I set:
>
> /etc/src.conf:
> WITH_SSP=
>
> /etc/make.conf:
> SSP_CFLAGS=-fstack-protector-all
> WITH_SSP_PORTS=yes
>
>
> But in /usr/src/sys/conf/kern.mk:
>
> ...
> #
> # GCC SSP support
> #
> .if ${MK_SSP} != "no" && \
>     ${MACHINE_CPUARCH} != "arm" && ${MACHINE_CPUARCH} != "mips"
> CFLAGS+=        -fstack-protector
> .endif
> ...
>
>
> Is there should be some thing like in /usr/src/share/mk/bsd.sys.mk:
>
> SSP_CFLAGS?=    -fstack-protector
> CFLAGS+=        ${SSP_CFLAGS}
>
> ???
>
>
> PS: /usr/ports/UPDATING
> "The default SSP_CLFAGS is -fstack-protector, but -fstack-protector-all"
> should be:
> "The default SSP_CFLAGS is -fstack-protector, but -fstack-protector-all"
> _______________________________________________
> freebsd-hackers@freebsd.org mailing list
> https://lists.freebsd.org/mailman/listinfo/freebsd-hackers
> To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@freebsd.org"
>



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAHsHv-ZvycRJyta1cOS9xS4QP0Pj2FYqcf%2BdOO6Ns5Pw0RSFgg>