Open faithanalog opened 6 months ago
Now that said, I think that some of these port usages may be unintentional, since it seems like the intent is to use epoll instead of ports when available.
At least when we wrote it, there was no epoll on illumos and ports was the only option. I don't think we ever considered a target/day when there would be both.
Currently, this project fails to build on illumos:
These errors appear to be because while
ENABLE_EPOLL
is defined, so isENABLE_PORTS
. But, becauseENABLE_EPOLL
is defined,ports.h
is never included.Now that said, I think that some of these port usages may be unintentional, since it seems like the intent is to use epoll instead of ports when available.
I was able to get the code to compile and work with epoll, with this patch, applied to b0c2bc5979f008a39300b01a0dc3e967c6257be9 (master as of writing):
I do not actually know if I am doing things correctly, because I have never written code that uses epoll or ports directly. But this does make make lua-http from https://github.com/daurnimator/lua-http run correctly on my illumos machine (OmniOS-based distribution).
Alternatively, simply disabling EPOLL and using ports instead also worked: