[llvm-commits] CVS: llvm/utils/GenLibDeps.pl
Reid Spencer
reid at x10sys.com
Thu Jul 27 16:00:51 PDT 2006
Changes in directory llvm/utils:
GenLibDeps.pl updated: 1.9 -> 1.10
---
Log message:
Changes to support cross-compiling LLVM. The GenLibDeps.pl script needs to
have a compile-host version of "nm", not build-host. In order to effect this
we must use autoconf to determine the correct "nm" to use and propagate that
through the makefiles, through llvm-config and finally to GenLibDeps.pl as
an optional argument.
Patch contributed by Anton Korobeynikov. Thanks!
---
Diffs of the changes: (+6 -3)
GenLibDeps.pl | 9 ++++++---
1 files changed, 6 insertions(+), 3 deletions(-)
Index: llvm/utils/GenLibDeps.pl
diff -u llvm/utils/GenLibDeps.pl:1.9 llvm/utils/GenLibDeps.pl:1.10
--- llvm/utils/GenLibDeps.pl:1.9 Tue Jul 25 14:12:06 2006
+++ llvm/utils/GenLibDeps.pl Thu Jul 27 18:00:30 2006
@@ -6,7 +6,7 @@
# libraries. The output of this script should periodically replace
# the similar content in the UsingLibraries.html document.
#
-# Syntax: GenLibDeps.pl [-flat] <directory_with_libraries_in_it>
+# Syntax: GenLibDeps.pl [-flat] <directory_with_libraries_in_it> [path_to_nm_binary]
#
# Parse arguments...
@@ -24,6 +24,7 @@
# Give first option a name.
my $Directory = $ARGV[0];
+my $nmPath = $ARGV[1];
# Find the "dot" program
my $DotPath="";
@@ -32,8 +33,10 @@
die "Can't find 'dot'" if (! -x "$DotPath");
}
-chomp(my $nmPath=`which nm`);
-die "Can't find 'nm'" if (! -x "$nmPath");
+if ($nmPath eq "") {
+ chomp($nmPath=`which nm`);
+ die "Can't find 'nm'" if (! -x "$nmPath");
+}
# Open the directory and read its contents, sorting by name and differentiating
# by whether its a library (.a) or an object file (.o)
More information about the llvm-commits
mailing list