When one wishes to compile and link a program with an
external library in one shot, additional
option "-link" is expected after all the other options. For example,
$ cl -I/c/OpenSSL-Win32/include 3.c -link -LIBPATH:"C:/OpenSSL-Win32/lib"
This is needed in an upcoming commit to compile conftest.c in autoconf.
Signed-off-by: Gurucharan Shetty <gshetty@nicira.com>
-L*)
path=`echo "$1" | sed 's/-L//'`
- linkopt="$linkopt /LIBPATH:$path"
+ linkopt="$linkopt ${slash}LIBPATH:\"$path\""
+ cl_linkopt="${slash}link ${slash}LIBPATH:\"$path\""
;;
-l*)
# choose which opts we built up based on which program will actually run
if test x$prog = xcl ; then
- opts=$clopt
+ opts="$clopt $cl_linkopt"
else
opts=$linkopt
fi