diff options
author | Gary V. Vaughan <gary@gnu.org> | 2012-10-02 18:08:29 +0700 |
---|---|---|
committer | Gary V. Vaughan <gary@gnu.org> | 2012-10-02 21:06:37 +0700 |
commit | fd1151fe85235b89ed0023c2d894dd117efaa03c (patch) | |
tree | aa27c3ffd2c7adf21be569b43c94a6bbd79e9231 | |
parent | 4e05284e5143fb8d8c19b9e0e50830f90132d7fe (diff) | |
download | libtool-fd1151fe85235b89ed0023c2d894dd117efaa03c.tar.gz |
libtool: use false or : for $preload, and simplify
* build-aux/ltmain.m4sh (func_mode_link): Save a string
comparison by setting $preload to false or : and using it directly
instead of if statements.
Signed-off-by: Gary V. Vaughan <gary@gnu.org>
-rw-r--r-- | build-aux/ltmain.m4sh | 15 |
1 files changed, 7 insertions, 8 deletions
diff --git a/build-aux/ltmain.m4sh b/build-aux/ltmain.m4sh index 6dc30003..ca497348 100644 --- a/build-aux/ltmain.m4sh +++ b/build-aux/ltmain.m4sh @@ -4388,7 +4388,7 @@ func_mode_link () non_pic_objects= precious_files_regex= prefer_static_libs=no - preload=no + preload=false prev= prevarg= release= @@ -4471,12 +4471,12 @@ func_mode_link () continue ;; dlfiles|dlprefiles) - if test no = "$preload"; then + $preload || { # Add the symbol object into the linking commands. func_append compile_command " @SYMFILE@" func_append finalize_command " @SYMFILE@" - preload=yes - fi + preload=: + } case $arg in *.la | *.lo) ;; # We handle these cases below. force) @@ -7949,7 +7949,7 @@ EOF test -n "$release" && \ func_warning "\`-release' is ignored for programs" - test yes = "$preload" \ + $preload \ && test unknown = "$dlopen_support" \ && test unknown = "$dlopen_self" \ && test unknown = "$dlopen_self_static" \ @@ -8344,9 +8344,8 @@ EOF build_libtool_libs=no else oldobjs="$old_deplibs $non_pic_objects" - if test yes = "$preload" && test -f "$symfileobj"; then - func_append oldobjs " $symfileobj" - fi + $preload && test -f "$symfileobj" \ + && func_append oldobjs " $symfileobj" fi addlibs=$old_convenience fi |