Skip to content
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

build statically-linked executable for Termonad #119

Closed
cdepillabout opened this issue Aug 19, 2019 · 1 comment
Closed

build statically-linked executable for Termonad #119

cdepillabout opened this issue Aug 19, 2019 · 1 comment
Labels
enhancement New feature or request help wanted Extra attention is needed

Comments

@cdepillabout
Copy link
Owner

cdepillabout commented Aug 19, 2019

It would be nice to be able to build Termonad into a statically-linked executable.

I did a little work on getting this building using static-haskell-nix:

nh2/static-haskell-nix#50

The final derivation I came up with is in this comment:

nh2/static-haskell-nix#50 (comment)

My guess is that Termonad should be able to be built statically as soon as static-haskell-nix updates its nixpkgs submodule to a version where gi-gtk and gi-vte are not broken. As of this writing, in the current nixpkgs master, both gi-gtk and gi-vte are working.

Thanks to @nh2 for all his work on static-haskell-nix!


However, note that statically-linked executables for Termonad aren't super important, since Termonad normally needs GHC plus a bunch of Haskell libraries available to recompile itself. The recompiled Termonad binary will probably be linked dynamically by default. It would probably require extra work to get it to recompile itself statically as well.

If #82 (which adds a dialog for configuring Termonad at runtime) is implemented, then this would potentially be more useful, since many users would be able to use Termonad without actually recompiling.

@cdepillabout cdepillabout added enhancement New feature or request help wanted Extra attention is needed labels Aug 19, 2019
@cdepillabout
Copy link
Owner Author

cdepillabout commented Dec 24, 2021

While it might be neat to have a statically-linked Termonad executable, I imagine that most people use Termonad's functionality of automatically rebuilding the executable based on a .config/termonad/termonad.hs file. Since it would be difficult to have this rebuilding process also create a statically-linked executable, I'm not sure how useful having a statically-linked executable would really be.

Also, my understanding is that it is difficult keeping the GTK libraries successfully cross-compiling.

Given these two things, I will go ahead and close this issue for now. But if someone is interested in working on this, I wouldn't necessary refuse to merge a PR if someone is able to get it working.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

1 participant