• R/O
  • HTTP
  • SSH
  • HTTPS

提交

標籤
無標籤

Frequently used words (click to add to your profile)

javac++androidlinuxc#objective-cqt誰得cocoawindowspythonrubyphpgameguibathyscaphec翻訳omegat計画中(planning stage)frameworktwittertestdombtronvb.netdirectxarduinopreviewerゲームエンジン

DLL dependency listing utility for MinGW applications


Commit MetaInfo

修訂a9475f3822ac2106c801029580e73c315effe970 (tree)
時間2020-09-08 03:13:38
作者Keith Marshall <keith@user...>
CommiterKeith Marshall

Log Message

Adopt a consistent style for shell function definitions.

* mingw32-ldd.sh (usage, set_dllpath, depends, list_depends)
(plot_depends, ref_count, ref_shift, plot_linkage, show_depends):
Insert white-space between '()' and '{'; some shells may object,
when it is omitted.

Change Summary

差異

--- a/mingw32-ldd.sh
+++ b/mingw32-ldd.sh
@@ -6,7 +6,7 @@
66 # executable files and/or dynamic link libraries.
77 #
88 #
9-# $Id: mingw32-ldd.sh,v bf042a552a35 2020/09/06 17:38:10 keith $
9+# $Id$
1010 #
1111 # Written by Keith Marshall <keith@users.osdn.me>
1212 # Copyright (C) 2016, 2017, 2019, 2020, MinGW.org Project
@@ -33,7 +33,7 @@
3333 #
3434 #
3535 CMD=`basename $0`
36- usage(){ echo >&2 "Usage: $CMD {EXENAME | DLLNAME} ..."; STATUS=2; echo; }
36+ usage() { echo "Usage: $CMD { EXENAME | DLLNAME } ..."; STATUS=2; echo; }
3737 #
3838 # Run-time initialization allows preferences for shell variables,
3939 # such as SYSTEM_DRIVE, SYSTEM_DLLPATH, and PROGRAM_FILES, to be
@@ -46,7 +46,7 @@
4646 rcinit "${HOME-`cd;pwd`}/.mingw32rc"
4747 EXEPATH=`dirname "$1"` STATUS=0
4848 #
49- set_dllpath(){
49+ set_dllpath() {
5050 # Usage: set_dllpath "colon:separated:path:list"
5151 #
5252 # Convert the specified colon separated path list to an equivalent
@@ -57,8 +57,8 @@
5757 }'`
5858 }
5959 #
60- depends(){
61- # Usage: depends {EXENAME | DLLNAME}
60+ depends() {
61+ # Usage: depends { EXENAME | DLLNAME }
6262 #
6363 # Extract a list of DLL dependencies from the specified executable or
6464 # dynamic link library file; if EXENAME or DLLNAME explicitly names a
@@ -78,8 +78,8 @@
7878 #
7979 objdump=`type -p mingw32-objdump || type -p objdump || echo objdump`
8080 #
81- list_depends(){
82- # Usage: list_depends {EXENAME | DLLNAME}
81+ list_depends() {
82+ # Usage: list_depends { EXENAME | DLLNAME }
8383 #
8484 # Helper function, called by depends(), to perform dependency list
8585 # extraction from the file explicitly named by EXENAME or DLLNAME.
@@ -87,8 +87,8 @@
8787 $objdump -x "$1" | awk 'BEGIN{IGNORECASE=1}/dll name/{print $NF}'
8888 }
8989 #
90- plot_depends(){
91- # Usage: plot_depends {EXENAME | DLLNAME} [count] [prefix]
90+ plot_depends() {
91+ # Usage: plot_depends { EXENAME | DLLNAME } [count] [prefix]
9292 #
9393 # Recursively plot the DLL dependency graph for the executable or
9494 # dynamic link library file named by EXENAME or DLLNAME; the count
@@ -112,10 +112,10 @@
112112 # while ref_shift() removes the first such reference from the same list,
113113 # (after it has been scheduled for processing).
114114 #
115- ref_count(){ echo $#; }
116- ref_shift(){ test $# -gt 0 && shift; echo "$@"; }
115+ ref_count() { echo $#; }
116+ ref_shift() { test $# -gt 0 && shift; echo "$@"; }
117117 #
118- plot_linkage(){
118+ plot_linkage() {
119119 # Usage: plot_linkage count
120120 #
121121 # Select the linkage glyph, for connection of the current node in
@@ -128,8 +128,8 @@
128128 test $1 -gt 0 && echo "|" || echo " "
129129 }
130130 #
131- show_depends(){
132- # Usage: show_depends {EXENAME | DLLNAME}
131+ show_depends() {
132+ # Usage: show_depends { EXENAME | DLLNAME }
133133 #
134134 # Wrapper to invoke plot_depends() for EXENAME or DLLNAME, provided
135135 # it exists, otherwise display a diagnostic message
@@ -144,9 +144,9 @@
144144 # quoted path list format), then plot the DLL dependency graph for each
145145 # EXENAME or DLLNAME specified on the command line.
146146 #
147- test $# -gt 0 || { usage; exit 2; }
147+ test $# -gt 0 || { usage >&2; exit $STATUS; }
148148 set_dllpath "${DLLPATH-$PROGRAM_FILES:/mingw/bin:$SYSTEM_DLLPATH}"
149149 while test $# -gt 0; do show_depends "$1"; shift; test $# -gt 0 && echo; done
150150 exit $STATUS
151151 #
152-# $RCSfile: mingw32-ldd.sh,v $: end of file
152+# $RCSfile$: end of file