rts/dist/build/libHSrtsmain.a
all_rts : $(ALL_RTS_LIBS)
-# The per-dir options
-$(eval $(call distdir-opts,rts,dist))
-
# -----------------------------------------------------------------------------
# Defining the sources
# Flags for compiling every file
# We like plenty of warnings.
-WARNING_OPTS += -Wall -Wextra
+WARNING_OPTS += -Wall
+ifeq "$(GccLT34)" "YES"
+WARNING_OPTS += -W
+else
+WARNING_OPTS += -Wextra
+endif
WARNING_OPTS += -Wstrict-prototypes
WARNING_OPTS += -Wmissing-prototypes
WARNING_OPTS += -Wmissing-declarations
rts_CC_OPTS += -DUSE_LIBFFI_FOR_ADJUSTORS
endif
-ifeq "$(Windows)" "YES"
-# SDM: when compiled with -fasm the RTS currently has bogus references to
-# __imp_base_ things, so working around for now:
-rts_HC_OPTS += -fvia-C
-endif
-
ifneq "$(DYNAMIC_RTS)" "YES"
rts_HC_OPTS += -static
else
rts_LD_OPTS += $(addprefix -optl, $(MACOSX_DEPLOYMENT_LD_OPTS))
# Otherwise the stack-smash handler gets triggered.
-ifeq "$(TargetOS_CPP)" "openbsd"
+ifneq "$(findstring $(TargetOS_CPP), darwin openbsd)" ""
rts_HC_OPTS += -optc-fno-stack-protector
endif
# inlining warnings happen in Compact
sm/Compact_CC_OPTS += -Wno-inline
+# emits warnings about call-clobbered registers on x86_64
+StgCRun_CC_OPTS += -w
+
RetainerProfile_CC_OPTS += -w
RetainerSet_CC_OPTS += -Wno-format
# On Windows:
.PHONY: install_rts
install_rts:
- $(INSTALL_DIR) $(DESTDIR)$(libdir)
- $(INSTALL_DIR) $(DESTDIR)$(libdir)/include
- "$(CP)" $(ALL_RTS_LIBS) $(DESTDIR)$(libdir)
+ $(INSTALL_DIR) $(DESTDIR)$(ghclibdir)
+ $(INSTALL_DIR) $(DESTDIR)$(ghclibdir)/include
+ "$(CP)" $(ALL_RTS_LIBS) $(DESTDIR)$(ghclibdir)
# -----------------------------------------------------------------------------
# cleaning