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
Add dual-licensed support for building against gnulib/libposix #70
Comments
Maybe no need to carry that lumbering gnulib beast around on our back after all... check this out: |
Looks dubiously small and unmaintained to me. And let's not think about (irrelevant) size but ease of use. gnulib requires autotools, that's its burden. But for that you get an awful lot of POSIX goodness. If libposix is (or becomes?) usable, there's nothing to carry at all. |
Unfortunately, I was the main driver for libposix, so I'm not sure it will happen at all now I've removed it from my TODO list :( That would certainly have been the ideal solution. But, this is what actually bothers me: $ cd ~/Projects/libposix--github--0
$ git clean -dfx
$ du -sh . gnulib slingshot ext/posix
64M .
58M gnulib
1.5M slingshot
316K ext/posix ...not the autoconfigury at all. Although I have a stdlib branch building (somewhat temperamentally) with just LuaRocks and a bit of glue, so I'm getting closer to ejecting all the autofoo from our Lua projects. More experimentation required. |
But WHY does it bother you?! |
<snark> I'd much prefer 158K of actual functionality, with a few 10's of K in build goo, and linking against your own crummy non-posix libc is not luaposix's problem :-)
|
Luaposix currently relies on the POSIX support of the build host. gnulib provides much wider support for POSIX APIs, especially on older OSes which lack up-to-date support, and on Mingw where it is often lacking altogether; but also fixes many bugs on widely-used systems (in particular Mac OS X, but there are even some useful fixes for glibc):
http://www.gnu.org/software/gnulib/
The main problem is that gnulib is mostly GPLed (some of it is LGPLed, and a small part public domain); otherwise we could simply use it by default.
Hence this issue: I propose that:
a) luaposix be dual-licensed MIT/GPL (it might be possible to offer LGPL as well, as a useful subset of gnulib is available under LGPL, and gnulib's build tool allows LGPL'ed versions of modules to be selected; but it would be more work)
b) when a GPL build is made, gnulib is used. (This is pretty easy, just a question of adding gnulib to the build system along with a list of modules. The list could be updated whenever luaposix is extended, but that doesn't strictly have to be done, you simply don't benefit from extra portability/fixes if you don't update the list for newly added APIs.)
Finally, if a gnulib expert takes an interest in this issue, there's a potentially less invasive way to implement it: use libposix. (Explanation: gnulib is a source library; libposix is an builds the POSIX APIs into a standard binary library. However, libposix is still, I believe, experimental.)
Implementing this issue would enable luaposix users to get much greater portability and more robust functionality on a wider range of platforms if they can use the GPL, while retaining the flexibility to stick with the MIT license.
The text was updated successfully, but these errors were encountered: