Hi Calvin
On 11/09/2023 14:22, Phillip Wood wrote:
This is looking good, it would be really nice to see a demonstration of
building git using git-std-lib (with gettext support) in the next
iteration.
I've just pushed a couple of patches on top of this series to
https://github.com/phillipwood/git/tree/cw/git-std-lib/v3 that show a
possible way to do that.
Rather than re-using LIB_OBJS when building git-std-lib.a it uses a
separate variable to hold the list of sources. git is linked against
git-std-lib.a so we don't have to worry about having the same source
file in two different libraries. The stub objects are moved into their
own library. This enables git to be built using git-std-lib.a with
make git
which will link git against git-std-lib.a built with gettext and tracing
support. To use git-std-lib.a in other programs compile it and
git-stub-lib.a with
make NO_GETTEXT=YesPlease git-std-lib.a git-stub-lib.a
and link your program against both libraries.
The GIT_STD_LIB define is also removed in favor of more stubbing to
avoid the complications of conditional compilation.
Best Wishes
Phillip