Now when I include smile.h in "release":
1>c:\documents and settings\nuk\moje dokumenty\visual studio 2005\projects\ttt\ttt\smile.h(11) : fatal error C1189: #error : In release build _SECURE_SCL must be defined and set to zero for VS.NET 2005 or late.
Smile in Visual C++ Windows Forms Application
-
- Site Admin
- Posts: 1457
- Joined: Mon Nov 26, 2007 5:51 pm
You can't, but smile.h takes care of selecting the proper library (this can be disabled, but I think you can just leave the auto-linking on). All you need to do is ensure that the path to directory containing smile*.lib files is set globally in Tools/Options or as configuration property in Linker/General/Additional Library Directories.Kasiak wrote:But now can I use smile without libraries?
-
- Site Admin
- Posts: 1457
- Joined: Mon Nov 26, 2007 5:51 pm
That should be self-explainingKasiak wrote:1>c:\documents and settings\nuk\moje dokumenty\visual studio 2005\projects\ttt\ttt\smile.h(11) : fatal error C1189: #error : In release build _SECURE_SCL must be defined and set to zero for VS.NET 2005 or late.

-
- Site Admin
- Posts: 1457
- Joined: Mon Nov 26, 2007 5:51 pm
-
- Site Admin
- Posts: 1457
- Joined: Mon Nov 26, 2007 5:51 pm
Project properties -> C++ -> Code generation -> Runtime library -> Multithreaded (/MT). Make sure you're doing that in release configuration. Rebuild the project and you should be able to distribute the exe file to other machines without installing any dependencies.
You'll be linking statically with CRT just to avoid that.Maybe I should copy some libraries with the exe file?
1>------ Rebuild All started: Project: TTT, Configuration: Release Win32 ------
1>Deleting intermediate and output files for project 'TTT', configuration 'Release|Win32'
1>Compiling...
1>cl : Command line error D8016 : '/MT' and '/clr' command-line options are incompatible
1>Build log was saved at "file://c:\Documents and Settings\nuk\Moje dokumenty\Visual Studio 2005\Projects\TTT\TTT\Release\BuildLog.htm"
1>TTT - 1 error(s), 0 warning(s)
1>Deleting intermediate and output files for project 'TTT', configuration 'Release|Win32'
1>Compiling...
1>cl : Command line error D8016 : '/MT' and '/clr' command-line options are incompatible
1>Build log was saved at "file://c:\Documents and Settings\nuk\Moje dokumenty\Visual Studio 2005\Projects\TTT\TTT\Release\BuildLog.htm"
1>TTT - 1 error(s), 0 warning(s)
-
- Site Admin
- Posts: 1457
- Joined: Mon Nov 26, 2007 5:51 pm
In this case, stick with CRT in DLL and use the redistributable package containing the VC++ 8.0 runtime:Kasiak wrote:I've changed this option before, because smile didn't work with Windows Forms Application.
http://www.microsoft.com/downloads/deta ... laylang=en
Finally, you'll need to install the proper version of .NET on the target machine.