From 9edc54394f87ac28862dff4bd7a9a0328698f730 Mon Sep 17 00:00:00 2001 From: Anthony Green Date: Sun, 25 Mar 2018 08:56:51 -0400 Subject: Add -L and -l options --- msvcc.sh | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/msvcc.sh b/msvcc.sh index eef61c8..616e67c 100755 --- a/msvcc.sh +++ b/msvcc.sh @@ -156,6 +156,25 @@ do includes="$includes $1" shift 1 ;; + -L*) + path=`echo "$1" | sed 's/-L//'` + args+=("/LIBPATH:$path") + ;; + -l*) + IFS_save="$IFS" + IFS=\; + found= + for d in $LIB; do + d="$(echo $d | sed -e 's,\\,/,g')" + if [ -f "$d/lib${1#-l}.lib" ]; then + found="lib${1#-l}.lib" + break; + fi + done + IFS="$IFS_save" + args="$args ${found:-${1#-l}.lib}" + shift 1 + ;; -W|-Wextra) # TODO map extra warnings shift 1 -- cgit v1.2.1