source-dist from GHC master branch

Hello, I'd like to create a source distribution (source-dist) from GHC git master branch. I tried hadrian (hadrian/build.sh source-dist) and make (make sdist-ghc) but both failed in different ways. Should this work (at all) for any git snapshot? Hadrian successfully built a source dist (ghc-8.11.0.20200215-src.tar.xz) but it did not compile. Regards, Csaba The error output (make sdist-ghc):
make sdist-ghc make --no-print-directory -f ghc.mk sdist-ghc NO_INCLUDE_DEPS=YES NO_INCLUDE_PKGDATA=YES ghc.mk:1221: warning: overriding recipe for target 'sdist_compiler_stage2_Cmm' ghc.mk:1220: warning: ignoring old recipe for target 'sdist_compiler_stage2_Cmm' make[1]: *** No rule to make target 'compiler/stage2/build/Cmm.hs', needed by 'sdist_compiler_stage2_Cmm'. Stop. Makefile:162: recipe for target 'sdist-ghc' failed make: *** [sdist-ghc] Error 2
csaba@x1:~/haskell/grin-compiler/ghc-playground/ghc$ make sdist-ghc make --no-print-directory -f ghc.mk sdist-ghc NO_INCLUDE_DEPS=YES NO_INCLUDE_PKGDATA=YES ghc.mk:1221: warning: overriding recipe for target 'sdist_compiler_stage2_Cmm' ghc.mk:1220: warning: ignoring old recipe for target 'sdist_compiler_stage2_Cmm' make[1]: *** No rule to make target 'compiler/stage2/build/Cmm.hs', needed by 'sdist_compiler_stage2_Cmm'. Stop. Makefile:162: recipe for target 'sdist-ghc' failed make: *** [sdist-ghc] Error 2
Error output hadrian:
| Run GenPrimopCode: _build/stage0/compiler/build/primops.txt => _build/stage0/compiler/build/primop-vector-tys-exports.hs-incl | Run Ghc FindHsDependencies Stage0: compiler/main/Annotations.hs (and 475 more) => _build/stage0/compiler/.dependencies.mk
<no location info>: error: module ‘ghc-8.6.2:Lexer’ is defined in multiple files: compiler/GHC/Cmm/Lexer.hs
compiler/parser/Lexer.hs Error when running Shake build system: at action, called at src/Rules.hs:71:19 in main:Rules at need, called at src/Rules.hs:93:5 in main:Rules * Depends on: _build/stage0/lib/package.conf.d/ghc-8.11.0.20200215.conf at need, called at src/Rules/Register.hs:116:5 in main:Rules.Register * Depends on: _build/stage0/compiler/build/libHSghc-8.11.0.20200215.a at need, called at src/Rules/Library.hs:146:5 in main:Rules.Library * Depends on: _build/stage0/compiler/build/Cpr.o at &%>, called at src/Rules/Compile.hs:62:9 in main:Rules.Compile * Depends on: _build/stage0/compiler/build/Cpr.o _build/stage0/compiler/build/Cpr.hi at apply1, called at src/Development/Shake/Internal/Rules/Oracle.hs:159:32 in shake-0.18.3-a2e904f154f09728357733d7a3e8955a2a87773d2d7eb963a6f88d9d883fdde3:Development.Shake.Internal.Rules.Oracle * Depends on: OracleQ (KeyValues ("_build/stage0/compiler/.dependencies","_build/stage0/compiler/build/Cpr.o")) at need, called at src/Hadrian/Oracles/TextFile.hs:96:9 in main:Hadrian.Oracles.TextFile * Depends on: _build/stage0/compiler/.dependencies at readFile', called at src/Rules/Dependencies.hs:34:19 in main:Rules.Dependencies at need, called at src/Development/Shake/Internal/Derived.hs:118:15 in shake-0.18.3-a2e904f154f09728357733d7a3e8955a2a87773d2d7eb963a6f88d9d883fdde3:Development.Shake.Internal.Derived * Depends on: _build/stage0/compiler/.dependencies.mk * Raised the exception: user error (Development.Shake.cmd, system command failed

Csaba Hruska
Hello,
I'd like to create a source distribution (source-dist) from GHC git master branch. I tried hadrian (hadrian/build.sh source-dist) and make (make sdist-ghc) but both failed in different ways. Should this work (at all) for any git snapshot?
Hadrian successfully built a source dist (ghc-8.11.0.20200215-src.tar.xz) but it did not compile.
For the record, this is being discussed on #17848 and #17849. Cheers, - Ben
participants (2)
-
Ben Gamari
-
Csaba Hruska