mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
gmake.mk: universal cpp rules
* defs/gmake.mk: define preprocessing rules per architectures for universal binaries. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@46306 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
20e6b3a3b8
commit
b1b88695be
1 changed files with 13 additions and 0 deletions
|
@ -9,6 +9,19 @@ ifneq ($(filter -O0 -Od,$(optflags)),)
|
|||
override XCFLAGS := $(filter-out -D_FORTIFY_SOURCE=%,$(XCFLAGS))
|
||||
endif
|
||||
|
||||
ifneq ($(filter universal-%,$(arch)),)
|
||||
define archcmd
|
||||
%.$(1).i: %.c
|
||||
@$$(ECHO) preprocessing $$< with $(2)
|
||||
$$(Q) $$(CPP) $$(warnflags) $(2) $$(XCFLAGS) $$(CPPFLAGS) $$(COUTFLAG)$$@ -E $$< > $$@
|
||||
|
||||
%.i: %.$(1).i
|
||||
endef
|
||||
|
||||
$(foreach $(filter -arch=%,$(subst -arch ,-arch=,$(ARCH_FLAG))),\
|
||||
$(eval $(call archcmd,$(patsubst -arch=%,%,$(value arch)),$(patsubst -arch=%,-arch %,$(value arch)))))
|
||||
endif
|
||||
|
||||
ifneq ($(filter check% test,$(MAKECMDGOALS)),)
|
||||
yes-test-knownbug: $(TEST_DEPENDS) yes-btest-ruby
|
||||
yes-btest-ruby: $(TEST_DEPENDS) yes-test-sample
|
||||
|
|
Loading…
Reference in a new issue