From: Pádraig Brady Date: Tue, 9 Sep 2014 14:50:07 +0000 (+0100) Subject: build: avoid name transformations on libstdbuf X-Git-Tag: v8.24~230 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=v8.23-22-g6f9b018;p=thirdparty%2Fcoreutils.git build: avoid name transformations on libstdbuf * src/local.mk (transform): Skip the transformation for libstdbuf since that should not be subject to name clashes, and we need to reference the name directly in LD_PRELOAD etc. * configure.ac: Add a comment on the coupling of pkglibexec_PROGRAMS to $(transform). Issue reported at https://trac.macports.org/ticket/44922 Improved by Nick Bowler --- diff --git a/configure.ac b/configure.ac index e061a0ad5a..f45b06e3a6 100644 --- a/configure.ac +++ b/configure.ac @@ -488,6 +488,8 @@ m4_include([m4/cu-progs.m4]) # Now that we know which programs will actually be built, determine # which optional helper progs should be compiled. +# Note it adding to pkglibexec_PROGRAMS, $(transform) in src/local.mk +# may need to be updated accordingly. case " $optional_bin_progs " in *' stdbuf '*) pkglibexec_PROGRAMS='src/libstdbuf.so';; *) pkglibexec_PROGRAMS='';; diff --git a/src/local.mk b/src/local.mk index c0d04d680c..0a6f217e0e 100644 --- a/src/local.mk +++ b/src/local.mk @@ -336,11 +336,18 @@ copy_sources = \ src/extent-scan.c \ src/extent-scan.h +# Don't apply prefix transformations to libstdbuf shared lib +# as that's not generally needed, and we need to reference the +# name directly in LD_PRELOAD etc. In general it's surprising +# that $(transform) is applied to libexec at all given that is +# for internal package naming, not privy to $(transform). + # Use 'ginstall' in the definition of PROGRAMS and in dependencies to avoid # confusion with the 'install' target. The install rule transforms 'ginstall' # to install before applying any user-specified name transformations. -transform = s/ginstall/install/; $(program_transform_name) +transform = /libstdbuf/q;s/ginstall/install/;$(program_transform_name) + src_ginstall_SOURCES = src/install.c src/prog-fprintf.c $(copy_sources) \ $(selinux_sources)