-
Notifications
You must be signed in to change notification settings - Fork 697
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
better support for static linking #391
Comments
(Imported comment by @dcoutts on 2008-11-08) Should not be too hard at least on common platforms. Just needs a bit of testing. Standalone task for some volunteer. |
+1 I'm currently reviewing Haskell for static linked binaries and I would love to be able to do it, just as in Go. Cross Compilation would be great too :). |
+1 |
I think this is a good idea as well. Anyone care to take a stab at it? I can provide some guidance. Generally you just have to add the |
+1 |
1 similar comment
+1 |
I'm giving a shot at this now. |
Also update the docs for `--enable-executable-dynamic` as they were slightly misleading.
Also update the docs for `--enable-executable-dynamic` as they were slightly misleading.
OK done. |
Also update the docs for `--enable-executable-dynamic` as they were slightly misleading.
Also update the docs for `--enable-executable-dynamic` as they were slightly misleading.
Also update the docs for `--enable-executable-dynamic` as they were slightly misleading.
Also update the docs for `--enable-executable-dynamic` as they were slightly misleading.
Also update the docs for `--enable-executable-dynamic` as they were slightly misleading.
Also update the docs for `--enable-executable-dynamic` as they were slightly misleading.
Also update the docs for `--enable-executable-dynamic` as they were slightly misleading.
Also update the docs for `--enable-executable-dynamic` as they were slightly misleading.
This reverts commit c9f02b2.
This reverts commit c9f02b2.
This reverts commit c9f02b2.
This reverts commit c9f02b2.
* WIP: Adding -L paths to .a libs in .conf files will likely increase nix closure size for dynamically linked Haskell packages because if pkg-config finds an `-a` file, the path to it will be remembered. (That only has an impact if the .a file is in a split-output from the .so file.) Perhaps we make the feature that `pkg-config --static` is called opt-outable. On the other hand Haskell libs always carry their .a files, so pulling a few system `.a` files more shouldn't make much of a difference. So this opt-out should probably be an extra feature for later, if at all. Cherry-Picked-From: cc4ae8a Its commit got squashed in: Pass --static to pkg-config on --enable-executable-static. This improves static building of packages with pkg-config depends, by using the pkg-config feature designed for just that. It results in more `-l` flags being emitted by `pkg-config --libs`, namely those of all recursive `.a` file dependencies. Also this commit got squashed in: Add `--enable-executable-static` flag. Fixes haskell#391. Also update the docs for `--enable-executable-dynamic` as they were slightly misleading. Cherry-Picked-From: c9f02b2
(Imported from Trac #398, reported by @dcoutts on 2008-11-08)
Generating statically linked binaries on different platforms requires a bit of knowledge about what flags to pass to ghc. It would be nice to just be able to cabal configure --enable-static-executable or something and have that pass the extra -optl-static and whatever ghc options are required.
If it's not possible to generate static binaries it should make some attempt at explaining why.
The text was updated successfully, but these errors were encountered: