Commit 3a0a3151 authored by ian@well-typed.com's avatar ian@well-typed.com

Fix build on platforms on which we don't have register info

parent fb1b2c7d
......@@ -34,7 +34,7 @@ includes_H_FILES := $(subst /./,/,$(includes_H_FILES))
# Options
#
ifeq "$(GhcUnregisterised)" "YES"
includes_CC_OPTS += -DNO_REGS -DUSE_MINIINTERPRETER
includes_CC_OPTS += -DUSE_MINIINTERPRETER
endif
includes_CC_OPTS += $(addprefix -I,$(GHC_INCLUDE_DIRS))
......@@ -125,6 +125,9 @@ endif
@echo "#define $(TargetOS_CPP)_TARGET_OS 1" >> $@
@echo "#define TARGET_OS \"$(TargetOS_CPP)\"" >> $@
@echo "#define $(TargetVendor_CPP)_TARGET_VENDOR 1" >> $@
ifeq "$(GhcUnregisterised)" "YES"
@echo "#define UnregisterisedCompiler 1" >> $@
endif
@echo >> $@
@echo "#endif /* __GHCPLATFORM_H__ */" >> $@
@echo "Done."
......
......@@ -15,6 +15,12 @@
#ifndef RTSMACHREGS_H
#define RTSMACHREGS_H
#ifdef UnregisterisedCompiler
#ifndef NO_REGS
#define NO_REGS
#endif
#endif
/*
* Defining NO_REGS causes no global registers to be used. NO_REGS is
* typically defined by GHC, via a command-line option passed to gcc,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment