Print this page
11787 Kernel needs to be built with retpolines
11788 Kernel needs to generally use RSB stuffing
Reviewed by: Jerry Jelinek <jerry.jelinek@joyent.com>
Reviewed by: John Levon <john.levon@joyent.com>
*** 247,256 ****
--- 247,266 ----
#
CFLAGS_uts_i386 += -_gcc7=-fno-shrink-wrap
CFLAGS_uts_i386 += -_gcc8=-fno-shrink-wrap
CFLAGS_uts_i386 += -_gcc9=-fno-shrink-wrap
+ #
+ # retpoline support
+ #
+ CFLAGS_uts_i386 += -_gcc7=-mindirect-branch=thunk-extern
+ CFLAGS_uts_i386 += -_gcc7=-mindirect-branch-register
+ CFLAGS_uts_i386 += -_gcc8=-mindirect-branch=thunk-extern
+ CFLAGS_uts_i386 += -_gcc8=-mindirect-branch-register
+ CFLAGS_uts_i386 += -_gcc9=-mindirect-branch=thunk-extern
+ CFLAGS_uts_i386 += -_gcc9=-mindirect-branch-register
+
CSTD = $(CSTD_GNU99)
CFLAGS_uts =
CFLAGS_uts += $(STAND_FLAGS_$(CLASS))
CFLAGS_uts += $(CCVERBOSE)