-
Notifications
You must be signed in to change notification settings - Fork 25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to build spago #124
Comments
Interesting, can you share your |
You can take a look here:
https://github.com/spacchetti/spago/blob/master/package.yaml. The ghc
options bit for both executables specifies that flag.
…On Mon, May 27, 2019, 4:52 AM Nicolas Mattia ***@***.***> wrote:
Interesting, can you share your package.yaml/package.nix? Any idea where
the -main-is is coming from? Looks like ghc is receiving it as -main-is
Curator (one arg) as opposed to -main-is Curator (two args).
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#124?email_source=notifications&email_token=AA4A7SHXMDUU6QJWAL7KPILPXOOLTA5CNFSM4HPTS3YKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODWJGYHA#issuecomment-496135196>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AA4A7SFKKO743ND7JFLH4JLPXOOLTANCNFSM4HPTS3YA>
.
|
I changed: executables:
spago:
# ...
ghc-options:
- -main-is Spago
# ...
spago-curator:
# ...
ghc-options:
- -main-is Curator
# ... to: executables:
spago:
# ...
ghc-options:
- -main-is
- Spago
# ...
spago-curator:
# ...
ghc-options:
- -main-is
- Curator
# ... and it managed to get past that step. I think this is a bug, if the intent is to remain hpack (and therefore stack) compatible. |
Now it fails with something related to template haskell:
Depending on how you'd prefer to track this stuff I can make this issue about the flags being passed in a particular way and open another issue for the template haskell related thing (I still don't know what's causing that). |
I am facing similar issue after I successfully compiled a module with template haskell ($embedFile) in it. Now another module can't find it. I don't know what's causing that, either.
|
Maybe it is related to this issue. Maybe adding an extension TemplateHaskell can fix this. |
After I try to add TemplateHaskell in lib and main in package.nix, the problem still exists. |
Mh, it looks like the |
I have simplified my yesod code to this. |
I have added a successful cabal build in my code repository for comparison. |
It seems that when |
No. Not like that. I After I add |
If |
ghc needs those intermediate files from last module both in -i and -outputdir. |
After I change |
@YuMingLiao wow, nice sleuthing! just got back from NixCon, catching up with notifications. Can GHC still find the object files/shared objects (i.e. not the interface files) even if they're unpacked in |
Thanks for encouragement! I am so glad that I can help on this issue. I am not sure what you mean by
And compiling a single module that use other TH module needs the other TH module's dyn_o. So if I want to However, if I add Even if I add I have to open So I use $out both in -i and -outputdir. |
Hi there. I was trying out building https://github.com/spacchetti/spago using the following
snack.nix
file:However I get the following error:
Full output is here: https://gist.github.com/masaeedu/759b0d19591b555ebbe8e5cbf2364cfd
The text was updated successfully, but these errors were encountered: