cURL / Mailing Lists / curl-library / Single Mail

curl-library

Re: libcurl static/static-'/MT' in MSVC, paying for binaries/.libs

From: Georg Lippitsch <georg.lippitsch_at_gmx.at>
Date: Fri, 15 Feb 2008 12:18:41 +0100

Am Donnerstag, 14. Februar 2008 23:30 schrieb Daniel Stenberg:
> On Thu, 14 Feb 2008, Georg Lippitsch wrote:
> > BTW, it's really confusing that curl sets /MT in \lib\Makefile.VC*
> > automatically when RTLIBCFG ist set to static, but does not in
> > \src\Makefile.VC*
>
> Please submit a patch if you have a fix!

OK, only copied the stuff from /lib/Makefile.vc6 to /src/Makefile.vc6:

Index: Makefile.vc6
===================================================================
RCS file: /cvsroot/curl/curl/src/Makefile.vc6,v
retrieving revision 1.39
diff -u -r1.39 Makefile.vc6
--- Makefile.vc6 23 Jan 2008 07:27:40 -0000 1.39
+++ Makefile.vc6 15 Feb 2008 11:14:11 -0000
@@ -61,13 +61,22 @@
 SSL_IMP_LFLAGS = /LIBPATH:"$(OPENSSL_PATH)/out32dll"
 SSL_LIBS = libeay32.lib ssleay32.lib gdi32.lib user32.lib advapi32.lib

+# Runtime library configuration
+RTLIB = /MD
+RTLIBD = /MDd
+
+!IF "$(RTLIBCFG)" == "static"
+RTLIB = /MT
+RTLIBD = /MTd
+!ENDIF
+
 ## Release
-CCR = cl.exe /MD /O2 /DNDEBUG
+CCR = cl.exe $(RTLIB) /O2 /DNDEBUG
 LINKR = link.exe /incremental:no /libpath:"../lib"
 RCR = rc.exe /dCURLDEBUG=0

 ## Debug
-CCD = cl.exe /MDd /Gm /ZI /Od /D_DEBUG /GZ
+CCD = cl.exe $(RTLIBD) /Gm /ZI /Od /D_DEBUG /GZ
 LINKD = link.exe /incremental:yes /debug /libpath:"../lib"
 RCD = rc.exe /dCURLDEBUG=1
Received on 2008-02-15