[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Problems with libtool 2.2.2 and /bin/sh pointing to dash
From: |
Richard Purdie |
Subject: |
Problems with libtool 2.2.2 and /bin/sh pointing to dash |
Date: |
Tue, 22 Apr 2008 00:07:48 +0100 |
Hi,
I've had reports of Poky breaking with libtool 2.2.2 and have isolated
this to people using dash as their /bin/sh provider (Poky runs the
configure script with /bin/sh). When used in this combination, the
global_symbol_pipe expression becomes corrupted in the generated libtool
file amongst other things and I've included a diff of the corruption
below. I noticed this with gtk+ 2.12.7.
gtk+ also has the issues that it tries to run libtool before its been
generated and I've had to patch this to run a previously generated
version of libtool poky has around to solve cases like this. I'm not
sure if there is a neater way to address that problem?
Regards,
Richard
--- libtool-bash 2008-04-21 17:57:40.000000000 +0100
+++ libtool-dash 2008-04-21 23:36:38.000000000 +0100
@@ -1,4 +1,4 @@
-#! /bin/sh
+#! /bin/bash
# arm-poky-linux-gnueabi-libtool - Provide generalized library-building
support services.
# Generated automatically by config.status (gtk+) 2.12.7
@@ -107,10 +107,10 @@
lt_unset=unset
# turn spaces into newlines.
-SP2NL="tr \\040 \\012"
+SP2NL="tr \040 \012"
# turn newlines into spaces.
-NL2SP="tr \\015\\012 \\040\\040"
+NL2SP="tr \015\012 \040\040"
# How to create reloadable object files.
reload_flag=" -r"
@@ -141,22 +141,22 @@
LTCFLAGS="-fexpensive-optimizations -fomit-frame-pointer -frename-registers
-O2 -Wall"
# Take the output of nm and produce a listing of raw symbols and C names.
-global_symbol_pipe="sed -n -e 's/^.*[ ]\\([ABCDGIRSTW][ABCDGIRSTW]*\\)[
][ ]*\\([_A-Za-z][_A-Za-z0-9]*\\)\$/\\1 \\2 \\2/p'"
+global_symbol_pipe="sed -n -e 's/^.*[ ]\\([ABCDGIRSTW][ABCDGIRSTW]*\\)[
][ ]*\\([_A-Za-z][_A-Za-z0-9]*\\)\$/ /p'"
# Transform the output of nm in a proper C declaration.
-global_symbol_to_cdecl="sed -n -e 's/^T .* \\(.*\\)\$/extern int \\1();/p' -e
's/^[ABCDGIRSTW]* .* \\(.*\\)\$/extern char \\1;/p'"
+global_symbol_to_cdecl="sed -n -e 's/^T .* \\(.*\\)\$/extern int ();/p' -e
's/^[ABCDGIRSTW]* .* \\(.*\\)\$/extern char ;/p'"
# Transform the output of nm in a C name address pair.
-global_symbol_to_c_name_address="sed -n -e 's/^: \\([^ ]*\\) \$/
{\\\"\\1\\\", (void *) 0},/p' -e 's/^[ABCDGIRSTW]* \\([^ ]*\\) \\([^ ]*\\)\$/
{\"\\2\", (void *) \\&\\2},/p'"
+global_symbol_to_c_name_address="sed -n -e 's/^: \\([^ ]*\\) \$/ {\\\"\\\",
(void *) 0},/p' -e 's/^[ABCDGIRSTW]* \\([^ ]*\\) \\([^ ]*\\)\$/ {\"\", (void
*) \\&},/p'"
# Transform the output of nm in a C name address pair when lib prefix is
needed.
-global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \\([^ ]*\\) \$/
{\\\"\\1\\\", (void *) 0},/p' -e 's/^[ABCDGIRSTW]* \\([^ ]*\\) \\(lib[^
]*\\)\$/ {\"\\2\", (void *) \\&\\2},/p' -e 's/^[ABCDGIRSTW]* \\([^ ]*\\) \\([^
]*\\)\$/ {\"lib\\2\", (void *) \\&\\2},/p'"
+global_symbol_to_c_name_address_lib_prefix="sed -n -e 's/^: \\([^ ]*\\) \$/
{\\\"\\\", (void *) 0},/p' -e 's/^[ABCDGIRSTW]* \\([^ ]*\\) \\(lib[^ ]*\\)\$/
{\"\", (void *) \\&},/p' -e 's/^[ABCDGIRSTW]* \\([^ ]*\\) \\([^ ]*\\)\$/
{\"lib\", (void *) \\&},/p'"
# The name of the directory that contains temporary libtool files.
objdir=.libs
# Shell to use when invoking shell scripts.
-SHELL="/bin/sh"
+SHELL="/bin/bash"
# An echo program that does not interpret backslashes.
ECHO="echo"
@@ -301,7 +301,7 @@
# Commands used to build a shared archive.
archive_cmds="\$CC -shared \$libobjs \$deplibs \$compiler_flags \${wl}-soname
\$wl\$soname -o \$lib"
archive_expsym_cmds="echo \\\"{ global:\\\" > \$output_objdir/\$libname.ver~
- cat \$export_symbols | sed -e \\\"s/\\\\(.*\\\\)/\\\\1;/\\\" >>
\$output_objdir/\$libname.ver~
+ cat \$export_symbols | sed -e \\\"s/\\\\(.*\\\\)/;/\\\" >>
\$output_objdir/\$libname.ver~
echo \\\"local: *; };\\\" >> \$output_objdir/\$libname.ver~
\$CC -shared \$libobjs \$deplibs \$compiler_flags \${wl}-soname
\$wl\$soname \${wl}-version-script \${wl}\$output_objdir/\$libname.ver -o \$lib"