What would help me to start, is a small 64-bit UNICODE "HELLO WORLD" Template, VS 2015 or VS 2013 or VS 2010 project.
I'll try to provide that.
Attached is the latest TCLib file and associated includes and samples. I don’t believe there is anything substantial in it that James doesn’t have.
I just tested it with VC15 (Vstudio 2008, x64) and VC19 (Vstudio 2015, x64).
The way I use it is as follows. I open the command prompt window from my Start Menu that either VStudio 2008 or VStudio 2015 put there. Be careful that you open the one for x64 builds, as there are several of them there. Actually, I’m not a big Start Menu user, and prefer to put shortcuts to stuff I use all the time on my desktop. So I transfer them to there.
When you execute that it will set the paths to the correct build chain. Then I use the CD command to change the directory to where I have my project.
So I’d recommend copying all the files in TCLib.zip to some directory where you are working. Most of the files are the Demo series of samples which I’ve extensively tested. I’d recommend your starting with those to get your ‘feet wet’, so to speak.
So take Demo1.cpp. If my command prompt is this…
C:\Code\Vstudio\VC++9\Silvah\TCLib>
…I’d paste the command line string after that and hit [ENTER]…
C:\Code\Vstudio\VC++9\Silvah\TCLib>cl Demo1.cpp /O1 /Os /GS- TCLib.lib kernel32.lib [ENTER]
If your paths are right and all the files are there it should build to about 3k x64 with VC19 (Vstudio 2015).
I’d recommend trying all the Demo series of files to familiarize yourself with the working of TCLib. Many or most of them use my String Class as represented by Strings.h and Strings.cpp. Try not to confuse those with string.h which is the header for the C Standard Library string primitives, e.g., strcpy, strcat, strlen, etc.
James has a real sophisticated batch file setup for doing all this, but my setup is rather simple and not as sophisticated. But it might be easier to understand. When working on a major project I make myself a batch file like so…
Build.bat
erase DCSilvah.exe frmCreateNew.obj frmCvta.obj frmExportData.obj frmOutputStatistics.obj frmLandscape.obj frmOutput.obj frmRegen.obj frmViewPlots.obj frmViewRegen.obj Main.obj C:\Silvah\Output.txt C:\Silvah\18001001.sil7
cls
cl @DCSil.txt
All that does is erase previous files I want to get rid of, clear the screen, and execute my build/compilation/linkage string which is contained in another file, which, for the major project I’m working on now, is named DCSil.txt, which looks like this…
Main.cpp
frmLandscape.cpp
frmExportData.cpp
frmOutputStatistics.cpp
frmGotoPlot.cpp
frmCreateNew.cpp
frmCvta.cpp
frmOutput.cpp
frmRegen.cpp
frmViewPlots.cpp
frmViewRegen.cpp
/FeDCSilvah.exe /O1 /Os /GS- /Gs9999999 /GR-
/link /STACK:0x100000,0x100000
TCLib.lib
Kernel32.lib
User32.lib
Gdi32.lib
ComDlg32.lib
ComCtl32.lib
DCSilvahRes.obj
dllSilvah.lib
As you can see above, this is a major project with tens of thousands of lines of code. To do a build from the command prompt all I need to do is type in ‘Build.bat’ from the command prompt. Not too hard!
Patrice, note that in your command line string for your graphics projects you’ll almost surely need the…
/Gs9999999 /GR- /link /STACK:0x100000,0x100000
…stack sizing code. When the Microsoft compiler is running in a /nodefaultlib configuration, which it is for usage with TCLib (internal code within TCLib.lib sets that up), the stack is set to a really small size like only a few thousand bytes or so. That works fine for my little demo series of programs, where you’ll note those command line settings weren’t used, but for virtually any major production sized program such as yours or mine, we’re going to need a megabyte sized stack allocation for sure.