Replies: 2 comments
-
I've never used docker for development, so I don't really have a feeling one way or the other. If you want to give it a go, feel free. So long as the CI builds work I will merge the changes. I will point out that there is a CMake build configuration for lnav as well. That build depends on vcpkg for getting libraries. So, theoretically, it's a bit simpler. I don't ship the binary it produces since it has a couple of goofy bugs, like some library is printing out some debug crud. I also haven't mirrored all of the test infrastructure, only the autoconf/automake build runs all the tests. (I keep the CMake build around to keep CLion happy) |
Beta Was this translation helpful? Give feedback.
-
@tstack, I'd appreciate your insights on the lnav build configuration. To streamline the Docker build process, I'd like to clarify the purpose of each option in the
Then, I plan to create distinct flags for each category, with the static build configuration as the Docker default. Here's the relevant ../configure \
--with-libarchive=/fake.root \
CFLAGS='-static -g1 -gz=zlib -no-pie -O2' \
CXXFLAGS='-static -g1 -gz=zlib -U__unused -no-pie -O2' \
LDFLAGS="-L/fake.root/lib" \
CPPFLAGS="-I/fake.root/include -I/fake.root/include/ncursesw" \
LIBS="-L/fake.root/lib -lssh2 -llzma -lssl -lcrypto -lz -llz4" \
--enable-static \
PATH="/fake.root/bin:${PATH}" My current understanding is:
Could you please confirm my categorization and advise on the removal of the unclear options? If you agree, I'll prepare a commit with these adjustments. Regarding vcpkg, while it might be integrated later, I'd like to begin by refining the existing musl Docker setup. |
Beta Was this translation helpful? Give feedback.
-
I'm exploring ways to simplify the lnav build process and improve the developer experience. One area I've been looking at is leveraging Docker more effectively. While the current musl Dockerfile serves a specific purpose in the 'bins' action, I believe it could be generalized and used more widely for both CI and development builds.
Currently, the README build instructions can be challenging to follow, and setting up the required dependencies can be time-consuming. Using Docker for all build stages would address these issues and offer several benefits:
ci-build/coverage
,ci-build/build
, etc., could potentially reduce build times by leveraging Docker's caching.ci-build
stage already builds with static libraries (for portability/smaller size?), this could be leveraged in the 'bins' action, perhaps by caching the resulting binaries.My proposed approach involves:
configure.ac
to support building lnav with only static libraries (and other necessary flags for creating the bins artifact). Potentially separating these into two options: one for the portable static build and one for other optimizations.ci-build
.@tstack, would you be open to exploring this approach? I'd be happy to contribute a proof-of-concept demonstrating these changes.
Beta Was this translation helpful? Give feedback.
All reactions