defs/gmake.mk: no _FORTIFY_SOURCE unless optimization

* defs/gmake.mk (XCFLAGS): remove _FORTIFY_SOURCE if optimization is
  disabled as it requires compiling with optimization.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@45402 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
nobu 2014-03-25 01:30:07 +00:00
Родитель c54e268a1f
Коммит b8c376cb9d
1 изменённых файлов: 4 добавлений и 0 удалений

Просмотреть файл

@ -5,6 +5,10 @@ TEST_TARGETS := $(patsubst test-%,yes-test-%,$(patsubst btest-%,yes-btest-%,$(TE
TEST_DEPENDS := $(if $(TEST_TARGETS),$(filter all main exts,$(MAKECMDGOALS)))
TEST_DEPENDS += $(TEST_DEPENDS) $(if $(filter check%,$(MAKECMDGOALS)),main)
ifneq ($(filter -O0 -Od,$(optflags)),)
override XCFLAGS := $(filter-out -D_FORTIFY_SOURCE=%,$(XCFLAGS))
endif
ifneq ($(filter check% test,$(MAKECMDGOALS)),)
yes-test-knownbug: $(TEST_DEPENDS) yes-btest-ruby
yes-btest-ruby: $(TEST_DEPENDS) yes-test-sample