GNU bug report logs -
#17840
[PATCH] libtool: Use 'file' instead of '/usr/bin/file' on GNU systems.
Previous Next
Reported by: ludo <at> gnu.org (Ludovic Courtès)
Date: Mon, 23 Jun 2014 19:44:02 UTC
Severity: normal
Tags: patch
Done: Mike Frysinger <vapier <at> gentoo.org>
Bug is archived. No further changes may be made.
Full log
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Hello,
The patch below changes occurrences of ‘/usr/bin/file’ to just ‘file’.
The impetus is that on systems using GNU Guix, NixOS, GoboLinux, and
others, the ‘file’ command is not available as /usr/bin/file, so it must
instead be taken from $PATH.
(I conservatively left ‘/usr/bin/file’ for more centralized systems such
as BSD, IRIX, etc. where it’s more likely to be a valid command.)
WDYT?
Ludo’.
[0001-libtool-Use-file-instead-of-usr-bin-file-on-GNU-syst.patch (text/x-patch, inline)]
From 8b4c022281a7c86c2fa604fc76297ffc1ceb2644 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Ludovic=20Court=C3=A8s?= <ludo <at> gnu.org>
Date: Mon, 23 Jun 2014 21:36:39 +0200
Subject: [PATCH] libtool: Use 'file' instead of '/usr/bin/file' on GNU
systems.
* m4/libtool.m4 (_LT_ENABLE_LOCK): Use 'file' instead of '/usr/bin/file'
on GNU- and Linux-based systems.
---
m4/libtool.m4 | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/m4/libtool.m4 b/m4/libtool.m4
index 320d8b3..6fb67b0 100644
--- a/m4/libtool.m4
+++ b/m4/libtool.m4
@@ -1312,7 +1312,7 @@ mips64*-*linux*)
echo '[#]line '$LINENO' "configure"' > conftest.$ac_ext
if AC_TRY_EVAL(ac_compile); then
emul=elf
- case `/usr/bin/file conftest.$ac_objext` in
+ case `file conftest.$ac_objext` in
*32-bit*)
emul="${emul}32"
;;
@@ -1320,7 +1320,7 @@ mips64*-*linux*)
emul="${emul}64"
;;
esac
- case `/usr/bin/file conftest.$ac_objext` in
+ case `file conftest.$ac_objext` in
*MSB*)
emul="${emul}btsmip"
;;
@@ -1328,7 +1328,7 @@ mips64*-*linux*)
emul="${emul}ltsmip"
;;
esac
- case `/usr/bin/file conftest.$ac_objext` in
+ case `file conftest.$ac_objext` in
*N32*)
emul="${emul}n32"
;;
@@ -1348,14 +1348,14 @@ s390*-*linux*|s390*-*tpf*|sparc*-*linux*)
# not appear in the list.
echo 'int i;' > conftest.$ac_ext
if AC_TRY_EVAL(ac_compile); then
- case `/usr/bin/file conftest.o` in
+ case `file conftest.o` in
*32-bit*)
case $host in
x86_64-*kfreebsd*-gnu)
LD="${LD-ld} -m elf_i386_fbsd"
;;
x86_64-*linux*)
- case `/usr/bin/file conftest.o` in
+ case `file conftest.o` in
*x86-64*)
LD="${LD-ld} -m elf32_x86_64"
;;
--
1.8.4
This bug report was last modified 1 year and 134 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.