error-message-index icon indicating copy to clipboard operation
error-message-index copied to clipboard

S-7011 [Can't build because of failure in `Setup.hs`]

Open Vlix opened this issue 2 years ago • 1 comments

At least I think it's the Setup.hs phase?

Reproduceable if you build digest-0.0.1.3 without having zlib1g-dev installed on Ubuntu.

digest                   > configure                                                                                                                                
digest                   > Configuring digest-0.0.1.3...                                                                                                                      
digest                   > Cabal-simple_SvXsv1f__3.2.1.0_ghc-8.10.7: Missing dependency on a foreign                                                                          
digest                   > library:                                                                                                                                           
digest                   > * Missing (or bad) header file: zlib.h                                                                                                             
digest                   > * Missing (or bad) C library: z                                                                                                                    
digest                   > This problem can usually be solved by installing the system package that                                                                           
digest                   > provides this library (you may need the "-dev" version). If the library is                                                                         
digest                   > already installed but in a non-standard location then you can use the flags                                                                        
digest                   > --extra-include-dirs= and --extra-lib-dirs= to specify where it is.If the                                                                          
digest                   > library file does exist, it may contain errors that are caught by the C                                                                            
digest                   > compiler at the preprocessing stage. In this case you can re-run configure                                                                         
digest                   > with the verbosity flag -v3 to see the error messages.                                                                                             
digest                   > If the header file does exist, it may contain errors that are caught by the C                                                                      
digest                   > compiler at the preprocessing stage. In this case you can re-run configure                                                                         
digest                   > with the verbosity flag -v3 to see the error messages.
[...]
Error: [S-7282]
       Stack failed to execute the build plan.
       
       While executing the build plan, Stack encountered the following errors:
       
       [S-7011]
       While building package digest-0.0.1.3 (scroll up to its section to see the error) using:
       /home/user/.stack/setup-exe-cache/x86_64-linux/Cabal-simple_SvXsv1f__3.2.1.0_ghc-8.10.7 --verbose=1 --builddir=.stack-work/dist/x86_64-linux/Cabal-3.2.1.0 configure --with-ghc=/home/user/.ghcup/ghc/8.10.7/bin/ghc --with-ghc-pkg=/home/user/.ghcup/ghc/8.10.7/bin/ghc-pkg --user --package-db=clear --package-db=global --package-db=/home/user/.stack/snapshots/x86_64-linux/65855b793e13878c072d4603a65c3ef0ff46d6f44a13759cf618166e7c77e625/8.10.7/pkgdb --libdir=/home/user/.stack/snapshots/x86_64-linux/65855b793e13878c072d4603a65c3ef0ff46d6f44a13759cf618166e7c77e625/8.10.7/lib --bindir=/home/user/.stack/snapshots/x86_64-linux/65855b793e13878c072d4603a65c3ef0ff46d6f44a13759cf618166e7c77e625/8.10.7/bin --datadir=/home/user/.stack/snapshots/x86_64-linux/65855b793e13878c072d4603a65c3ef0ff46d6f44a13759cf618166e7c77e625/8.10.7/share --libexecdir=/home/user/.stack/snapshots/x86_64-linux/65855b793e13878c072d4603a65c3ef0ff46d6f44a13759cf618166e7c77e625/8.10.7/libexec --sysconfdir=/home/user/.stack/snapshots/x86_64-linux/65855b793e13878c072d4603a65c3ef0ff46d6f44a13759cf618166e7c77e625/8.10.7/etc --docdir=/home/user/.stack/snapshots/x86_64-linux/65855b793e13878c072d4603a65c3ef0ff46d6f44a13759cf618166e7c77e625/8.10.7/doc/digest-0.0.1.3 --htmldir=/home/user/.stack/snapshots/x86_64-linux/65855b793e13878c072d4603a65c3ef0ff46d6f44a13759cf618166e7c77e625/8.10.7/doc/digest-0.0.1.3 --haddockdir=/home/user/.stack/snapshots/x86_64-linux/65855b793e13878c072d4603a65c3ef0ff46d6f44a13759cf618166e7c77e625/8.10.7/doc/digest-0.0.1.3 --dependency=base=base-4.14.3.0 --dependency=bytestring=bytestring-0.10.12.0 -f-bytestring-in-base --exact-configuration --ghc-option=-fhide-source-paths
       Process exited with code: ExitFailure 1

EDIT: Seems to maybe be a more generic error that a package didn't build (regardless of why)


[S-7282] might be sort of the same? or it kind of looks like a more general "failed to execute plan"?

Vlix avatar May 01 '23 12:05 Vlix

Hmmm, I've also seen this happen and getting an [S-7011] just because the test section of a library had type errors... :thinking:

Vlix avatar May 03 '23 12:05 Vlix