2017.10.10 14:28 "Re: [Tiff] Problem using libtiff in debug mode with visual studio 2010", by Emmanuel Cosnard
Thank you very much Even, it's working perfect now! But it's not working anymore in release... Is there a way to make it work for both, or should I duplicate them, i.e one for debug and one for release?
De: Even Rouault <firstname.lastname@example.org>
Envoyé: mardi 10 octobre 2017 12:22:16
Cc: Emmanuel Cosnard; Bob Friesenhahn
Objet: Re: [Tiff] Problem using libtiff in debug mode with visual studio 2010
On mardi 10 octobre 2017 12:07:49 CEST Emmanuel Cosnard wrote:
I finally managed to build and install the latesr version of libtiff on visual studio 2010, but I still have exactly the same mistake in debug when I do a TIFFopen in debug mode.
What I did to build libtiff is to use the command prompt of visual studio 2010, and executed the following command lines in the libtiff directory:
nmake /f makefile.vc clean
nmake /f makefile.vc DEBUG=1
Do you know if there is something I am doing wrong here?
I don't see anything in nmake.opt that would react on a DEBUG=1 option
But you probably need to replace
OPTFLAGS = /Ox /MD /EHsc /W3 /D_CRT_SECURE_NO_DEPRECATE
OPTFLAGS = /MDd /EHsc /W3 /D_CRT_SECURE_NO_DEPRECATE
The critical change is /MD to /MDd to use the debug C runtime.