8000 GNUMakefile: install libstdbuf by Ecordonnier · Pull Request #8238 · uutils/coreutils · GitHub
[go: up one dir, main page]

Skip to content

GNUMakefile: install libstdbuf #8238

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

Ecordonnier
Copy link
Contributor
@Ecordonnier Ecordonnier commented Jun 21, 2025

Use external libstdbuf.so when building with make, as embedding the library
is only needed to work around "cargo install" limitations with shared libraries.

Also change default installation directory to /usr/local/libexec/coreutils/ for consistency
with GNU coreutils

Copy link

GNU testsuite comparison:

Skipping an intermittent issue tests/misc/stdbuf (passes in this run but fails in the 'main' branch)
Skipping an intermittent issue tests/misc/tee (passes in this run but fails in the 'main' branch)

@oech3
Copy link
Contributor
oech3 commented Jun 22, 2025

Is this trying to installing /usr/lib/libstdbuf.so? GNU Coreutils's default is /usr/lib/coreutils/libstdbuf.so if it is built with --libexecdir=/usr/lib.

mkdir and cp is replaced with install -Dm644

Use external libstdbuf.so when building with make, as embedding the library
is only needed to work around "cargo install" limitations with shared libraries.

Also change default installation directory to /usr/local/libexec/coreutils/ for consistency
with GNU coreutils

Signed-off-by: Etienne Cordonnier <ecordonnier@snap.com>
@Ecordonnier Ecordonnier force-pushed the eco/libstdbuf-makefile branch from 6949f6e to e1441ef Compare June 22, 2025 21:31
@Ecordonnier
Copy link
Contributor Author

Is this trying to installing /usr/lib/libstdbuf.so? GNU Coreutils's default is /usr/lib/coreutils/libstdbuf.so if it is built with --libexecdir=/usr/lib.

mkdir and cp is replaced with install -Dm644

  • I added install -m755
  • install -Dm755 does not work because of using a wildcard (libstdbuf*) to handle .so vs .dylib on macos, so it would need to be separated line "install -D". I kept mkdir -p for consistency with the other mkdir calls in the same code block.
  • the default of GNU coreutils is to be /usr/local/libexec/coreutils/libstdbuf.so:
ecordonnier@LC49NTQ3:~/dev/gnu-coreutils$ make install DESTDIR=./foobar
ecordonnier@LC49NTQ3:~/dev/gnu-coreutils$ find foobar/ -name libstdbuf*
foobar/usr/local/libexec/coreutils/libstdbuf.so

I changed the code to use the same directory in uutils-coreutils

Copy link

GNU testsuite comparison:

Skip an intermittent issue tests/timeout/timeout (fails in this run but passes in the 'main' branch)

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
0