-
Notifications
You must be signed in to change notification settings - Fork 23
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
Function implementations in the tkrzw module interface #61
Comments
tkrzw has quite a bit of code that is implemented in header files that are supposed to be included by consuming projects. This causes some technical issues with [weak symbols](https://en.wikipedia.org/wiki/Weak_symbol) inside the consumer's translation units (or `.obj` files), that might fail to be deduplicated if the consuming project uses compiler settings different from those used by the tkrzw build system. More importantly, however, parts of the code, especially imlementations of non-virtual functions, might end up being embedded into consumer applications when an optimization phase eliminates the procedure calls, raising many concerns considering licensing. This commit moves all implementations from header files documented for inclusion into third-party projects on https://dbmx.net/tkrzw/, as well as any header that implicitly gets included by including a tkrzw interface header into source files. Further, `inline` declarations are removed as within tkrzw, the inlining happens on the discredition of the linker independed of the `inline` keyword, while cross-module inlining is what this commit is supposed to interdict. Nothing can be done about template code in tkrzw_lib_common.h , however, template code is whitelisted on GPLv3.
tkrzw has quite a bit of code that is implemented in header files that are supposed to be included by consuming projects. This causes some technical issues with [weak symbols](https://en.wikipedia.org/wiki/Weak_symbol) inside the consumer's translation units (or `.obj` files), that might fail to be deduplicated if the consuming project uses compiler settings different from those used by the tkrzw build system. More importantly, however, parts of the code, especially imlementations of non-virtual functions, might end up being embedded into consumer applications when an optimization phase eliminates the procedure calls, raising many concerns considering licensing. This commit moves all implementations from header files documented for inclusion into third-party projects on https://dbmx.net/tkrzw/, as well as any header that implicitly gets included by including a tkrzw interface header into source files. Further, `inline` declarations are removed as within tkrzw, the inlining happens on the discredition of the linker independed of the `inline` keyword, while cross-module inlining is what this commit is supposed to interdict. Nothing can be done about template code in tkrzw_lib_common.h , however, template code is whitelisted on GPLv3.
Hi, Thanks for making the PR. However, let me ask some questions because I wrote some codes in the header files intentionally. With --enable-debug, CFLAGS has -fno-inline, which avoids embedding of inline functions. Thus, you can trace inline functions on the debugger. As for licensing, Tkrzw uses the Apache2 license, not GPL3. |
Hi, Within itself (and its' tests/demos/examples), tkrzw forms a homogenous unit of CFLAGS and everything has the same license, too. From a packaging/operations perspective, a goal would be the ability to replace tkrzw by replacing Note that in order to "inline" a function, an optimizer doesn't need the |
tkrzw has quite a bit of code that is implemented in header files that are supposed to be included by consuming projects. This causes some technical issues with [weak symbols](https://en.wikipedia.org/wiki/Weak_symbol) inside the consumer's translation units (or `.obj` files), that might fail to be deduplicated if the consuming project uses compiler settings different from those used by the tkrzw build system. More importantly, however, parts of the code, especially imlementations of non-virtual functions, might end up being embedded into consumer applications when an optimization phase eliminates the procedure calls, raising many concerns considering licensing. This commit moves all implementations from header files documented for inclusion into third-party projects on https://dbmx.net/tkrzw/, as well as any header that implicitly gets included by including a tkrzw interface header into source files. Further, `inline` declarations are removed as within tkrzw, the inlining happens on the discredition of the linker independed of the `inline` keyword, while cross-module inlining is what this commit is supposed to interdict. Nothing can be done about template code in tkrzw_lib_common.h , however, template code is whitelisted on GPLv3.
Hi
tkrzw has quite a bit of code that is implemented in header files that are supposed to be included by consuming projects. This causes some technical issues with weak symbols inside the consumer's translation units (or
.obj
files), that might fail to be deduplicated if the consuming project uses compiler settings different from those used by the tkrzw build system.More importantly, however, parts of the code, especially non-virtual implementations, might end up being embedded into consuming applications by optimizers that eliminate the procedure calls, raising concerns considering licensing.
The text was updated successfully, but these errors were encountered: