Commit 351dea4a authored by Herbert Valerio Riedel's avatar Herbert Valerio Riedel 🕺

Drop redundant `-D__GLASGOW_HASKELL__=...` flag

In 3549c952 a `include/ghcversions.h` include
file was introduced which defines `__GLASGOW_HASKELL__` as well.

So there's no need to define it twice.
parent 70eefbc2
......@@ -1191,9 +1191,7 @@ runPhase (RealPhase cc_phase) input_fn dflags
++ verbFlags
++ [ "-S" ]
++ cc_opt
++ [ "-D__GLASGOW_HASKELL__="++cProjectVersionInt
, "-include", ghcVersionH
]
++ [ "-include", ghcVersionH ]
++ framework_paths
++ split_opt
++ include_paths
......@@ -2032,10 +2030,7 @@ doCpp dflags raw input_fn output_fn = do
#endif
-- Default CPP defines in Haskell source
ghcVersionH <- getGhcVersionPathName dflags
let hsSourceCppOpts =
[ "-D__GLASGOW_HASKELL__="++cProjectVersionInt
, "-include", ghcVersionH
]
let hsSourceCppOpts = [ "-include", ghcVersionH ]
-- MIN_VERSION macros
let uids = explicitPackages (pkgState dflags)
......
......@@ -60,9 +60,7 @@ $(includes_H_VERSION) : mk/project.mk | $$(dir $$@)/.
@echo "#ifndef __GHCVERSION_H__" > $@
@echo "#define __GHCVERSION_H__" >> $@
@echo >> $@
@echo "#ifndef __GLASGOW_HASKELL__" >> $@
@echo "# define __GLASGOW_HASKELL__ $(ProjectVersionInt)" >> $@
@echo "#endif" >> $@
@echo "#define __GLASGOW_HASKELL__ $(ProjectVersionInt)" >> $@
@echo >> $@
@if [ -n "$(ProjectPatchLevel1)" ]; then \
echo "#define __GLASGOW_HASKELL_PATCHLEVEL1__ $(ProjectPatchLevel1)" >> $@; \
......
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