flatpak: Bring manifest file up to date.

- Worked around haskell packages sometimes missing their
  Setup.hs file.
This commit is contained in:
Andrew Hamilton 2019-08-10 10:31:17 +10:00
parent bf3fd5c63b
commit c339742203
2 changed files with 388 additions and 660 deletions

File diff suppressed because it is too large Load diff

View file

@ -83,7 +83,11 @@ def make_haskell_module(package, deps):
commands.append(f"cd {dep}; ./Setup unregister") commands.append(f"cd {dep}; ./Setup unregister")
sources.append({ sources.append({
"type": "script", "type": "script",
"commands": ["set -x", "cd $1", "ghc -threaded --make Setup", "commands": ["set -x", "cd $1",
"if [ ! -e Setup.hs ] && [ ! -e Setup.lhs ]; then",
" echo 'import Distribution.Simple' > Setup.hs",
" echo 'main = defaultMain' >> Setup.hs", "fi",
"ghc -threaded --make Setup",
"./Setup configure --disable-optimization --prefix=/app", "./Setup configure --disable-optimization --prefix=/app",
"./Setup build", "./Setup install"], "./Setup build", "./Setup install"],
"dest-filename": "install-package"}) "dest-filename": "install-package"})