Building Issues (MSVC08)

Discuss development and code patches for DXGL.
Post Reply
ZoriaRPG
Posts: 22
Joined: October 8th, 2017, 7:25 pm
Location: Prydon Academy, Gallifrey
Contact:

Building Issues (MSVC08)

Post by ZoriaRPG » September 23rd, 2019, 12:00 pm

You have some include directives with relative filesystem access, pointing above the project, tht do not exist.

Could you please provide files for these include errors, ot tell me what I'm missing?

Code: Select all

6>e:\dxgl2\ddraw\shadergen2d.cpp(29) : fatal error C1083: Cannot open include file: '../common/version.h': No such file or directory
6>ShaderGen3D.cpp
6>e:\dxgl2\ddraw\shadergen3d.cpp(28) : fatal error C1083: Cannot open include file: '../common/version.h': No such file or directory
6>glDirectDraw.cpp
6>e:\dxgl2\ddraw\gldirectdraw.cpp(33) : fatal error C1083: Cannot open include file: '../common/version.h': No such file or directory
i have the full DirectX SDK installed, but this isn't pointing to any of that? Clearly it is for the local ddraw project....

Warnings here:

Code: Select all

6>e:\dxgl2\ddraw\glrenderer.cpp(870) : warning C4244: 'argument' : conversion from 'float' to 'DWORD_PTR', possible loss of data
6>e:\dxgl2\ddraw\glrenderer.cpp(1171) : warning C4244: 'argument' : conversion from 'GLfloat' to 'DWORD_PTR', possible loss of data
6>e:\dxgl2\ddraw\glrenderer.cpp(1306) : warning C4244: 'argument' : conversion from 'GLfloat' to 'DWORD_PTR', possible loss of data
6>e:\dxgl2\ddraw\glrenderer.cpp(1874) : warning C4800: 'BOOL' : forcing value to bool 'true' or 'false' (performance warning)
6>e:\dxgl2\ddraw\glrenderer.cpp(1874) : warning C4800: 'BOOL' : forcing value to bool 'true' or 'false' (performance warning)
6>e:\dxgl2\ddraw\glrenderer.cpp(3695) : warning C4018: '<' : signed/unsigned mismatch
6>e:\dxgl2\ddraw\glrenderer.cpp(3695) : warning C4018: '<' : signed/unsigned mismatch
6>e:\dxgl2\ddraw\glrenderer.cpp(3697) : warning C4018: '>' : signed/unsigned mismatch
6>e:\dxgl2\ddraw\glrenderer.cpp(3698) : warning C4018: '>' : signed/unsigned mismatch
6>e:\dxgl2\ddraw\glrenderer.cpp(3794) : warning C4806: '&' : unsafe operation: no value of type 'bool' promoted to type 'int' can equal the given constant
6>e:\dxgl2\ddraw\glrenderer.cpp(3794) : warning C4554: '&' : check operator precedence for possible error; use parentheses to clarify precedence
6>e:\dxgl2\ddraw\glrenderer.cpp(3829) : warning C4244: 'argument' : conversion from 'DWORD' to 'WORD', possible loss of data
6>e:\dxgl2\ddraw\glrenderer.cpp(3829) : warning C4806: '&' : unsafe operation: no value of type 'bool' promoted to type 'int' can equal the given constant
6>e:\dxgl2\ddraw\glrenderer.cpp(3829) : warning C4554: '&' : check operator precedence for possible error; use parentheses to clarify precedence
6>e:\dxgl2\ddraw\glrenderer.cpp(3833) : warning C4244: 'argument' : conversion from 'DWORD' to 'WORD', possible loss of data
6>e:\dxgl2\ddraw\glrenderer.cpp(3836) : warning C4244: 'argument' : conversion from 'DWORD' to 'WORD', possible loss of data
6>e:\dxgl2\ddraw\glrenderer.cpp(3859) : warning C4244: 'argument' : conversion from 'DWORD' to 'WORD', possible loss of data
6>e:\dxgl2\ddraw\glrenderer.cpp(3859) : warning C4806: '&' : unsafe operation: no value of type 'bool' promoted to type 'int' can equal the given constant
6>e:\dxgl2\ddraw\glrenderer.cpp(3859) : warning C4554: '&' : check operator precedence for possible error; use parentheses to clarify precedence
6>e:\dxgl2\ddraw\glrenderer.cpp(3863) : warning C4244: 'argument' : conversion from 'DWORD' to 'WORD', possible loss of data
6>e:\dxgl2\ddraw\glrenderer.cpp(3866) : warning C4244: 'argument' : conversion from 'DWORD' to 'WORD', possible loss of data
6>e:\dxgl2\ddraw\glrenderer.cpp(3890) : warning C4806: '&' : unsafe operation: no value of type 'bool' promoted to type 'int' can equal the given constant
6>e:\dxgl2\ddraw\glrenderer.cpp(3890) : warning C4554: '&' : check operator precedence for possible error; use parentheses to clarify precedence
6>e:\dxgl2\ddraw\glrenderer.cpp(3992) : warning C4101: 'shaderid' : unreferenced local variable
6>e:\dxgl2\ddraw\glrenderer.cpp(4466) : warning C4800: 'BOOL' : forcing value to bool 'true' or 'false' (performance warning)
6>e:\dxgl2\ddraw\glrenderer.cpp(4466) : warning C4800: 'int' : forcing value to bool 'true' or 'false' (performance warning)
7>e:\dxgl2\dxglcfg\dxgltest.cpp(83) : warning C4244: 'initializing' : conversion from 'LRESULT' to 'int', possible loss of data
7>e:\dxgl2\dxglcfg\dxgltest.cpp(113) : warning C4244: 'initializing' : conversion from 'LRESULT' to 'int', possible loss of data
7>e:\dxgl2\dxglcfg\dxgltest.cpp(299) : warning C4244: '=' : conversion from 'LRESULT' to 'int', possible loss of data
7>e:\dxgl2\dxglcfg\dxgltest.cpp(353) : warning C4996: '_swprintf': swprintf has been changed to conform with the ISO C standard, adding an extra character count parameter. To use traditional Microsoft swprintf, set _CRT_NON_CONFORMING_SWPRINTFS.
7>        c:\program files (x86)\microsoft visual studio 9.0\vc\include\stdio.h(539) : see declaration of '_swprintf'
7>e:\dxgl2\dxglcfg\dxgltest.cpp(373) : warning C4244: '=' : conversion from 'LRESULT' to 'int', possible loss of data
7>e:\dxgl2\dxglcfg\dxgltest.cpp(388) : warning C4267: '=' : conversion from 'size_t' to 'int', possible loss of data
7>e:\dxgl2\dxglcfg\dxgltest.cpp(393) : warning C4996: '_swprintf': swprintf has been changed to conform with the ISO C standard, adding an extra character count parameter. To use traditional Microsoft swprintf, set _CRT_NON_CONFORMING_SWPRINTFS.
7>        c:\program files (x86)\microsoft visual studio 9.0\vc\include\stdio.h(539) : see declaration of '_swprintf'
7>e:\dxgl2\dxglcfg\dxgltest.cpp(445) : warning C4244: '=' : conversion from 'LRESULT' to 'int', possible loss of data
7>e:\dxgl2\dxglcfg\dxgltest.cpp(473) : warning C4996: '_swprintf': swprintf has been changed to conform with the ISO C standard, adding an extra character count parameter. To use traditional Microsoft swprintf, set _CRT_NON_CONFORMING_SWPRINTFS.
7>        c:\program files (x86)\microsoft visual studio 9.0\vc\include\stdio.h(539) : see declaration of '_swprintf'
7>e:\dxgl2\dxglcfg\tests.cpp(957) : warning C4101: 'p' : unreferenced local variable
7>e:\dxgl2\dxglcfg\tests.cpp(956) : warning C4101: 'r1' : unreferenced local variable
7>e:\dxgl2\dxglcfg\tests.cpp(956) : warning C4101: 'r2' : unreferenced local variable
7>e:\dxgl2\dxglcfg\tests.cpp(1665) : warning C4267: 'argument' : conversion from 'size_t' to 'int', possible loss of data7>e:\dxgl2\dxglcfg\tests.cpp(3766) : warning C4244: '=' : conversion from 'LRESULT' to 'DWORD', possible loss of data
Lots of signed/unsigned mismatch, but those aren't as important as OoO warns.

There re also quite a lot of shadow var warnings, and I'm unsure if the i shadow var use is intentional.

Code: Select all

7>e:\dxgl2\dxglcfg\tests.cpp(401) : warning C4258: 'i' : definition from the for loop is ignored; the definition from the enclosing scope is used
7>        e:\dxgl2\dxglcfg\tests.cpp(231) : definition of 'i' ignored
7>        e:\dxgl2\dxglcfg\tests.cpp(210) : definition of 'i' used
7>e:\dxgl2\dxglcfg\tests.cpp(401) : warning C4258: 'i' : definition from the for loop is ignored; the definition from the enclosing scope is used
7>        e:\dxgl2\dxglcfg\tests.cpp(231) : definition of 'i' ignored
7>        e:\dxgl2\dxglcfg\tests.cpp(210) : definition of 'i' used
7>e:\dxgl2\dxglcfg\tests.cpp(401) : warning C4258: 'i' : definition from the for loop is ignored; the definition from the enclosing scope is used
7>        e:\dxgl2\dxglcfg\tests.cpp(231) : definition of 'i' ignored
7>        e:\dxgl2\dxglcfg\tests.cpp(210) : definition of 'i' used
7>e:\dxgl2\dxglcfg\tests.cpp(402) : warning C4258: 'i' : definition from the for loop is ignored; the definition from the enclosing scope is used
7>        e:\dxgl2\dxglcfg\tests.cpp(231) : definition of 'i' ignored
7>        e:\dxgl2\dxglcfg\tests.cpp(210) : definition of 'i' used
7>e:\dxgl2\dxglcfg\tests.cpp(402) : warning C4258: 'i' : definition from the for loop is ignored; the definition from the enclosing scope is used
7>        e:\dxgl2\dxglcfg\tests.cpp(231) : definition of 'i' ignored
7>        e:\dxgl2\dxglcfg\tests.cpp(210) : definition of 'i' used
7>e:\dxgl2\dxglcfg\tests.cpp(404) : warning C4258: 'i' : definition from the for loop is ignored; the definition from the enclosing scope is used
7>        e:\dxgl2\dxglcfg\tests.cpp(231) : definition of 'i' ignored
7>        e:\dxgl2\dxglcfg\tests.cpp(210) : definition of 'i' used
7>e:\dxgl2\dxglcfg\tests.cpp(404) : warning C4258: 'i' : definition from the for loop is ignored; the definition from the enclosing scope is used
7>        e:\dxgl2\dxglcfg\tests.cpp(231) : definition of 'i' ignored
7>        e:\dxgl2\dxglcfg\tests.cpp(210) : definition of 'i' used
7>e:\dxgl2\dxglcfg\tests.cpp(404) : warning C4258: 'i' : definition from the for loop is ignored; the definition from the enclosing scope is used
7>        e:\dxgl2\dxglcfg\tests.cpp(231) : definition of 'i' ignored
7>        e:\dxgl2\dxglcfg\tests.cpp(210) : definition of 'i' used
7>e:\dxgl2\dxglcfg\tests.cpp(405) : warning C4258: 'i' : definition from the for loop is ignored; the definition from the enclosing scope is used
7>        e:\dxgl2\dxglcfg\tests.cpp(231) : definition of 'i' ignored
7>        e:\dxgl2\dxglcfg\tests.cpp(210) : definition of 'i' used
7>e:\dxgl2\dxglcfg\tests.cpp(405) : warning C4258: 'i' : definition from the for loop is ignored; the definition from the enclosing scope is used
7>        e:\dxgl2\dxglcfg\tests.cpp(231) : definition of 'i' ignored
7>        e:\dxgl2\dxglcfg\tests.cpp(210) : definition of 'i' used
7>e:\dxgl2\dxglcfg\tests.cpp(407) : warning C4258: 'i' : definition from the for loop is ignored; the definition from the enclosing scope is used
7>        e:\dxgl2\dxglcfg\tests.cpp(231) : definition of 'i' ignored
7>        e:\dxgl2\dxglcfg\tests.cpp(210) : definition of 'i' used
7>e:\dxgl2\dxglcfg\tests.cpp(407) : warning C4258: 'i' : definition from the for loop is ignored; the definition from the enclosing scope is used
7>        e:\dxgl2\dxglcfg\tests.cpp(231) : definition of 'i' ignored
7>        e:\dxgl2\dxglcfg\tests.cpp(210) : definition of 'i' used
7>e:\dxgl2\dxglcfg\tests.cpp(407) : warning C4258: 'i' : definition from the for loop is ignored; the definition from the enclosing scope is used
7>        e:\dxgl2\dxglcfg\tests.cpp(231) : definition of 'i' ignored
7>        e:\dxgl2\dxglcfg\tests.cpp(210) : definition of 'i' used
7>e:\dxgl2\dxglcfg\tests.cpp(408) : warning C4258: 'i' : definition from the for loop is ignored; the definition from the enclosing scope is used
7>        e:\dxgl2\dxglcfg\tests.cpp(231) : definition of 'i' ignored
7>        e:\dxgl2\dxglcfg\tests.cpp(210) : definition of 'i' used
7>e:\dxgl2\dxglcfg\tests.cpp(408) : warning C4258: 'i' : definition from the for loop is ignored; the definition from the enclosing scope is used
7>        e:\dxgl2\dxglcfg\tests.cpp(231) : definition of 'i' ignored
7>        e:\dxgl2\dxglcfg\tests.cpp(210) : definition of 'i' used7>e:\dxgl2\dxglcfg\tests.cpp(401) : warning C4258: 'i' : definition from the for loop is ignored; the definition from the enclosing scope is used
7>        e:\dxgl2\dxglcfg\tests.cpp(231) : definition of 'i' ignored
7>        e:\dxgl2\dxglcfg\tests.cpp(210) : definition of 'i' used
7>e:\dxgl2\dxglcfg\tests.cpp(401) : warning C4258: 'i' : definition from the for loop is ignored; the definition from the enclosing scope is used
7>        e:\dxgl2\dxglcfg\tests.cpp(231) : definition of 'i' ignored
7>        e:\dxgl2\dxglcfg\tests.cpp(210) : definition of 'i' used
7>e:\dxgl2\dxglcfg\tests.cpp(401) : warning C4258: 'i' : definition from the for loop is ignored; the definition from the enclosing scope is used
7>        e:\dxgl2\dxglcfg\tests.cpp(231) : definition of 'i' ignored
7>        e:\dxgl2\dxglcfg\tests.cpp(210) : definition of 'i' used
7>e:\dxgl2\dxglcfg\tests.cpp(402) : warning C4258: 'i' : definition from the for loop is ignored; the definition from the enclosing scope is used
7>        e:\dxgl2\dxglcfg\tests.cpp(231) : definition of 'i' ignored
7>        e:\dxgl2\dxglcfg\tests.cpp(210) : definition of 'i' used
7>e:\dxgl2\dxglcfg\tests.cpp(402) : warning C4258: 'i' : definition from the for loop is ignored; the definition from the enclosing scope is used
7>        e:\dxgl2\dxglcfg\tests.cpp(231) : definition of 'i' ignored
7>        e:\dxgl2\dxglcfg\tests.cpp(210) : definition of 'i' used
7>e:\dxgl2\dxglcfg\tests.cpp(404) : warning C4258: 'i' : definition from the for loop is ignored; the definition from the enclosing scope is used
7>        e:\dxgl2\dxglcfg\tests.cpp(231) : definition of 'i' ignored
7>        e:\dxgl2\dxglcfg\tests.cpp(210) : definition of 'i' used
7>e:\dxgl2\dxglcfg\tests.cpp(404) : warning C4258: 'i' : definition from the for loop is ignored; the definition from the enclosing scope is used
7>        e:\dxgl2\dxglcfg\tests.cpp(231) : definition of 'i' ignored
7>        e:\dxgl2\dxglcfg\tests.cpp(210) : definition of 'i' used
7>e:\dxgl2\dxglcfg\tests.cpp(404) : warning C4258: 'i' : definition from the for loop is ignored; the definition from the enclosing scope is used
7>        e:\dxgl2\dxglcfg\tests.cpp(231) : definition of 'i' ignored
7>        e:\dxgl2\dxglcfg\tests.cpp(210) : definition of 'i' used
7>e:\dxgl2\dxglcfg\tests.cpp(405) : warning C4258: 'i' : definition from the for loop is ignored; the definition from the enclosing scope is used
 (...)
That is about 1/3 of them.

Let me know if you want the entire output log.

William
Site Admin
Posts: 140
Joined: November 19th, 2011, 5:08 pm
Contact:

Re: Building Issues (MSVC08)

Post by William » September 23rd, 2019, 12:10 pm

The header is auto-generated, but I guess I missed the pre-build step in the project files for Visual Studio 2008. You can make the build run through using the attached files - unzip them to the common folder.
Attachments
common.zip
Missing files - DXGL 0.5.17
(629 Bytes) Downloaded 17 times

ZoriaRPG
Posts: 22
Joined: October 8th, 2017, 7:25 pm
Location: Prydon Academy, Gallifrey
Contact:

Re: Building Issues (MSVC08)

Post by ZoriaRPG » September 24th, 2019, 2:19 am

TY, it now builds.

William
Site Admin
Posts: 140
Joined: November 19th, 2011, 5:08 pm
Contact:

Re: Building Issues (MSVC08)

Post by William » September 28th, 2019, 1:40 pm

Strange; I just unzipped the DXGL source code to a fresh VM with Visual C++ 2008 Express SP1 and it built fine. Next I'll try skipping the build dependencies and see if I can get it to not build.

Make sure you aren't trying to build the "Debug no DXGL" target, as it is very buggy and may only build after building one of the regular targets; it's intended to load DXGL Config in the debugger without loading the DXGL ddraw.dll.

EDIT: Just tested, the "Debug no DXGL" target is indeed broken, causing the error you mentioned. Not sure why MSVC selects it as default. You'll need to select "Debug" for debugging or "Release" for making production binaries.

ZoriaRPG
Posts: 22
Joined: October 8th, 2017, 7:25 pm
Location: Prydon Academy, Gallifrey
Contact:

Re: Building Issues (MSVC08)

Post by ZoriaRPG » September 30th, 2019, 10:38 am

Hmm, I somehow got Debug No dxgl to build at one point, but my target is Release.

Note that the vs9 incremental linker tends to crash--at least for me, so I always set /Incremental No.

Post Reply