aboutsummaryrefslogtreecommitdiff
path: root/client/libacron/include/net.h
AgeCommit message (Collapse)Author
2022-08-09fix(libacron): infinite loop when wic_parse returns 0Trumeet
This is a rather complicated way to fix backlogging issues. It asks the client to pass partial buffer, and the client also must retry with NULL buffer if ac_receive returns AC_E_AGAIN.
2022-07-25feat(libacron): support force disconnecting without writing anythingTrumeet
API:CHANGE Signed-off-by: Trumeet <yuuta@yuuta.moe>
2022-07-23feat(libacron/acronc): delegate socket IO to the clientTrumeet
API:CHANGE Signed-off-by: Trumeet <yuuta@yuuta.moe>
2022-07-22feat(libacron): ac_receive(): support setting a timeoutTrumeet
API:ADD Signed-off-by: Trumeet <yuuta@yuuta.moe>
2022-07-22feat(libacron): more customized ac_connection_parametersTrumeet
API:CHANGE Signed-off-by: Trumeet <yuuta@yuuta.moe>
2022-07-21fix(libacron/acronc): complete cross-platform buildTrumeet
This patch made several changes to correctly build libac on Windows: 1. Deprecated PkgConfig on Unix. On both platforms, libac requires the JSON-C CMake module to locate libraries (whether is dynamic or static) and headers. On Windows, the common practice is to statically link the library, so libac now provides setup.bat to automatically clone JSON-C and build it. In CMakeLists.txt, libac will automatically pick up the in-tree JSON-C build if it presents. Otherwise, it will use the system default's. Users can override the CMAKE_PREFIX_PATH to supply a custom JSON-C library if it is not found in-tree. 2. Switched from #include <json-c/xxx.h> to <xxx.h>, as the former (current) approach is non-standard and depends on the system header locations. The later (new) approach relies on CMake to supply header search paths, which works on Windows as well. 3. Deprecated --version-script on Unix linkers. Instead, libac now uses -fvisibility (https://gcc.gnu.org/wiki/Visibility) on GCC or LLVM, as well as __declspec(dllexport) on MSVC to export selected symbols. A new macro, LIBAC_EXPORT, is defined in incl.h (new), and all functions needed to export are marked with that macro. 4. Changed several codes (mostly socket-related) to work on Windows. 5. Massive rewrite of CMake in preparation of further installation and static library support. Signed-off-by: Trumeet <yuuta@yuuta.moe>
2022-07-20docs(libacron): add library docsTrumeet
Signed-off-by: Trumeet <yuuta@yuuta.moe>
2022-07-20libac: First CommitTrumeet