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

Provide self-contained packages for Dex #371

Open
5 tasks
apaszke opened this issue Dec 23, 2020 · 0 comments
Open
5 tasks

Provide self-contained packages for Dex #371

apaszke opened this issue Dec 23, 2020 · 0 comments
Labels
maintenance Maintenance tasks (build systems, CI, code cleanup, etc)

Comments

@apaszke
Copy link
Collaborator

apaszke commented Dec 23, 2020

Right now the only way for someone to play with Dex is to build it from scratch. While stack makes that relatively painless, it would be even better if it was possible to download a self-contained binary, so that the users don't even ever have to realize that our implementation is in Haskell.

This might be especially important given that our Python bindings are getting more mature at this point, and folks might be willing to try out Dex, provided they can use it as part of their bigger Python project. In principle it should be possible to create wheels such that

pip install dex

is all one needs to do.

Here's a (potentially incomplete) laundry list of things that would have to happen for us to get there:

  • Do a license audit of all our (transitive) dependencies. There is quite a few of those (stack ls dependencies lists ~150 packages). IIUC pretty much everything is BSD-licensed, but Haskell itself is built against libgmp.so that has a GNU license.
  • Write a script to gather license text from all our (transitive) dependencies. BSD requires us to distribute the text along with any binary artifacts derived from their implementations. If our packages are to be self-contained, we need all of those licenses to appear in our binary. Potentially relevant blog post.
  • Figure out how to get the closure of libDex.so. There are multiple options here. We could figure out how to get it to link statically (this would require to recompile all deps with -fPIC which stack doesn't do by default). Alternatively, we could write a script that gathers all the (non-system) shared libraries and patches their rpaths so that they can find each other without any extra hacks.
  • Figure out how to get this self-contained bundle of shared libraries and Python code into a Python wheel. This involves figuring out all the bits and pieces around setup.py and setuptools commands in general. Once we have this, I'll take care of managing PyPI.
  • Automate this whole process. The more automation, the easier it will be for us to cut regular releases. We're moving fast and so it would be good to do that periodically.
@apaszke apaszke added maintenance Maintenance tasks (build systems, CI, code cleanup, etc) and removed contributions welcome labels Jan 4, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
maintenance Maintenance tasks (build systems, CI, code cleanup, etc)
Projects
None yet
Development

No branches or pull requests

1 participant