iustin / corydalis

Corydalis - photo library management helper and image viewer
GNU Affero General Public License v3.0
19 stars 0 forks source link

build problems on debian 9.4 stretch #4

Closed karlkashofer closed 1 year ago

karlkashofer commented 5 years ago

I try to build on debian, it fails with:

karl@mediaserver:~/corydalis$ stack build
Specified file "git-version" for extra-source-files does not exist
Building all executables for corydalis once. After a successful build of all of them, only specified executables will be rebuilt.
Warning: Dependent file listed in:
         /home/karl/corydalis/corydalis/.stack-work/dist/x86_64-linux/Cabal-2.4.0.1/build/Settings/Development.hi
         does not exist: git-version

Warning: File listed in corydalis/corydalis.cabal file does not exist: git-version

If i provide a dummy file (git --version > git-version) it still fails somewhere else:

karl@mediaserver:~/corydalis$ stack build
Building all executables for `corydalis' once. After a successful build of all of them, only specified executables will be rebuilt.
corydalis> build (lib + exe)
Preprocessing library for corydalis-0.4.0..
Building library for corydalis-0.4.0..
[32 of 32] Compiling Application
/home/karl/corydalis/corydalis/src/Application.hs:1:1: fatal:
    cannot find object file ‘.stack-work/dist/x86_64-linux/Cabal-2.4.0.1/build/Indexer.dyn_o’
    while linking an interpreted expression

--  While building package corydalis-0.4.0 using:
      /home/karl/.stack/setup-exe-cache/x86_64-linux/Cabal-simple_mPHDZzAJ_2.4.0.1_ghc-8.6.5 --builddir=.stack-work/dist/x86_64-linux/Cabal-2.4.0.1 build lib:corydalis exe:corydalis exe:db-util exe:scanner --ghc-options " -fdiagnostics-color=always"
    Process exited with code: ExitFailure 1
karl@mediaserver:~/corydalis$ 

Any idea what could be wrong ? Cheers, KK

iustin commented 5 years ago
  1. For the git-version, you can/should generate it via "make git-version".

  2. For the stack build error, that is weird. Which version of stack do you have?

karlkashofer commented 5 years ago

Hi !

Thanks for your help !

1.) making git-version works, maybe add that to the build instructions ? Error #2 still the same though. 2.) $ stack --version Version 2.1.3, Git revision 636e3a759d51127df2b62f90772def126cdf6d1f (7735 commits) x86_64 hpack-0.31.2

karlkashofer commented 5 years ago

Hi !

After a "stack clean --full" the project has now built without incident ! Maybe my fake git-version file messed something up. Thanks, KK

iustin commented 5 years ago

OK, I must admit I don't know stack enough to understand why a clean was needed. I'll update the docs to mention the make git-version, but that text file is not interpreted by anything, so I doubt it was the cause. Thanks!

iustin commented 1 year ago

Closing this since it's very old. I still don't know if this works for other people, or if anyone cares, but… :)