4 Specify a C compiler to build C sources when we're bootstrapping.
7 Missing dependency on generated headers.
10 This is pkgsrc specific: /usr/sbin/dtrace gets confused when we have
11 ghc wrappers in the PATH so we have to hide them.
14 --- rts/ghc.mk.orig 2012-02-01 18:10:32.000000000 +0000
18 # We build the RTS with stage 1
19 rts_dist_HC = $(GHC_STAGE1)
20 +rts_dist_CC = $(CC_STAGE1)
22 # merge GhcLibWays and GhcRTSWays but strip out duplicates
23 rts_WAYS = $(GhcLibWays) $(filter-out $(GhcLibWays),$(GhcRTSWays))
24 @@ -457,6 +458,10 @@ $(eval $(call dependencies,rts,dist,1))
26 $(rts_dist_depfile_c_asm) : $(libffi_HEADERS) $(DTRACEPROBES_H)
28 +ifeq "$(BootingFromHc)" "YES"
29 +$(rts_C_SRCS) : $(libffi_HEADERS) $(DTRACEPROBES_H)
32 # -----------------------------------------------------------------------------
33 # compile dtrace probes if dtrace is supported
35 @@ -479,7 +484,7 @@ endif
37 DTRACEPROBES_SRC = rts/RtsProbes.d
38 $(DTRACEPROBES_H): $(DTRACEPROBES_SRC) includes/ghcplatform.h | $$(dir $$@)/.
39 - "$(DTRACE)" $(filter -I%,$(rts_CC_OPTS)) -C $(DTRACE_FLAGS) -h -o $@ -s $<
40 + env PATH="/usr/bin" "$(DTRACE)" $(filter -I%,$(rts_CC_OPTS)) -C $(DTRACE_FLAGS) -h -o $@ -s $<
43 # -----------------------------------------------------------------------------