diff options
author | Herbert Valerio Riedel <hvr@gnu.org> | 2015-12-31 16:58:28 +0100 |
---|---|---|
committer | Herbert Valerio Riedel <hvr@gnu.org> | 2015-12-31 17:00:21 +0100 |
commit | 351dea4a7c07f4e845eac6c2e895f6f41524b40c (patch) | |
tree | a479a38cf037a0d3e2e8063f53f56df23a5e2b05 | |
parent | 70eefbc21649b11cd0ea1b779df316fc93d84a59 (diff) | |
download | haskell-351dea4a7c07f4e845eac6c2e895f6f41524b40c.tar.gz |
Drop redundant `-D__GLASGOW_HASKELL__=...` flag
In 3549c952b535803270872adaf87262f2df0295a4 a `include/ghcversions.h` include
file was introduced which defines `__GLASGOW_HASKELL__` as well.
So there's no need to define it twice.
-rw-r--r-- | compiler/main/DriverPipeline.hs | 9 | ||||
-rw-r--r-- | includes/ghc.mk | 4 |
2 files changed, 3 insertions, 10 deletions
diff --git a/compiler/main/DriverPipeline.hs b/compiler/main/DriverPipeline.hs index 4936ace3cb..d3038bcf7d 100644 --- a/compiler/main/DriverPipeline.hs +++ b/compiler/main/DriverPipeline.hs @@ -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) diff --git a/includes/ghc.mk b/includes/ghc.mk index e87a4874cf..aacca0805b 100644 --- a/includes/ghc.mk +++ b/includes/ghc.mk @@ -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)" >> $@; \ |