VOGONS

Common searches


First post, by Somik

User metadata
Rank Newbie
Rank
Newbie

Hi! I was following the guide to build DOSBOX via visual studio (https://www.dosbox.com/wiki/Building_DOSBox_w … h_Visual_Studio) with Visual Studio 2019 and after building SDL.lib, SDLMain.lib, SDL_Net.lib, zlib.lib, libpng16.lib and pdcurses.lib separately from their own solution files/ with nmake, when I try to open the DOSBOX solution file in Visual studio 2019, set up the library and include directories and hit build, mostly the build goes perfect until I'm hitting a weird

warning is treater as error

in pngmem.c line 95 that is inside the libpng source directory. I have the compiler warning level set to

/W0

which basically turns off all the warnings, also the

/Wx-

is set which stops the compiler from treating warnings as errors. I dont even understand why while building DOSBOX pngmem.c has to be built since it's inside the libpng directory, and I had already built libpng.lib from its own solution file earlier in a previous step. Would really appreciate if someone could point me to the right direction to solve this issue. Here's a snippet from the build output right before the error is hit, I can provide more info if required.

1>Generating Code...
1>F:\Visual Studio\2019\Community\MSBuild\Microsoft\VC\v160\Microsoft.CppBuild.targets(1274,5): warning MSB8012: TargetPath(G:\DOSBox\dosbox\visualc_net\x64\Release\dosbox.exe) does not match the Linker's OutputFile property value (G:\DOSBox\dosbox\visualc_net\Release\dosbox.exe). This may cause your project to build incorrectly. To correct this, please make sure that $(OutDir), $(TargetName) and $(TargetExt) property values match the value specified in %(Link.OutputFile).
1>zlib.lib(deflate.obj) : MSIL .netmodule or module compiled with /GL found; restarting link with /LTCG; add /LTCG to the link command line to improve linker performance
1>LINK : warning LNK4098: defaultlib 'LIBCMT' conflicts with use of other libs; use /NODEFAULTLIB:library
1>Generating code
1>G:\DOSBox\lpng1634\pngmem.c(95): error C2220: the following warning is treated as an error