Skip to content

Build only the library, not the whole tree - #12

Open
henrikottesorensen wants to merge 1 commit into
Notalib:mainfrom
henrikottesorensen:build/only-build-the-library
Open

Build only the library, not the whole tree#12
henrikottesorensen wants to merge 1 commit into
Notalib:mainfrom
henrikottesorensen:build/only-build-the-library

Conversation

@henrikottesorensen

Copy link
Copy Markdown
Collaborator

Runs make -C gnulib then make -C liblouis instead of a top level make. The tree also contains tools/, tables/, man/, doc/, tests/, python/ and windows/, none of which reach a package.

Speed is the lesser reason

A failure under tools/ does not stop a top level make. The win-arm64 build once emitted eight link errors there and still exited 0, which hid a real problem in several thousand lines of log — it was only found by grepping for it. Building only what is shipped means any failure is about the thing being shipped.

It also removes libtool's could not determine the host path warnings. Those come from the wrapper scripts libtool generates around uninstalled executables, which it cannot construct when cross compiling to Windows without wine. They were pure noise, and there were 48 of them in a full container build. Now none.

gnulib has to be named explicitly

make -C liblouis alone stops with:

make[1]: *** No rule to make target '../gnulib/libgnu.la', needed by 'liblouis.la'.  Stop.

liblouis links gnulib/libgnu.la (liblouis_la_LIBADD), and make does not build a sibling directory on demand. So both, in order.

Skipping tables/ is safe

tables/ generates two tables with m4, nl-chardefs.uti and nl-NL-g0.utb. Both are also shipped pre-generated in the release tarball, so LibLouis.NET.Tables still stages a complete set. Checked against a pristine tarball rather than assumed, because silently dropping tables from that package would be hard to notice.

Results

Full tree Library only
Container wall clock 849s 636s
win-x86 630s 500s
win-arm64 334s 222s
linux-x86 139s 126s
libtool host-path warnings 48 0

The serial Windows targets gain most, which follows: they cannot use -j, so the tools were pure added latency there.

All eight RIDs build, and all pass the binary verification from #6 unchanged — same architectures, same 18 exported P/Invoke symbols, same dependency allowlists, same glibc floor. macOS is also covered: 51s, zero warnings, both slices correct.

Independent of the other open PRs. It touches only the two native build scripts and PACKAGING.md.

🤖 Generated with Claude Code

Runs make -C gnulib then make -C liblouis rather than a top level make.
The tree also contains tools/, tables/, man/, doc/, tests/, python/ and
windows/, none of which reach a package.

Speed is the lesser reason. A failure under tools/ does not stop a top
level make: the win-arm64 build once emitted eight link errors there and
still exited 0, which hid a real problem in several thousand lines of
log. Building only what is shipped means any failure is about the thing
being shipped.

It also removes the libtool "could not determine the host path" warnings,
which come from the wrapper scripts it generates around uninstalled
executables. 48 in a full container build, none now.

gnulib is named explicitly because make will not build a sibling
directory on demand: make -C liblouis alone stops with "No rule to make
target '../gnulib/libgnu.la'".

Skipping tables/ is safe. The two tables generated there with m4,
nl-chardefs.uti and nl-NL-g0.utb, also ship pre-generated in the release
tarball, so LibLouis.NET.Tables still stages a complete set.

All eight RIDs build and verify unchanged. Container wall clock 636s
against 849s, and the serial Windows targets gain most: win-x86 500s
against 630s, win-arm64 222s against 334s.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants