Jump to content
  • Advertisement
Sign in to follow this  
regonaros

Compile errors

This topic is 2147 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I just switched over to DirectX11 from DirectX9 and I've got the following compile errors when I ran my first DirectX program. any help appreciated.

 

1>------ Build started: Project: DirectX11, Configuration: Debug Win32 ------
1>Build started 26-Dec-12 18:37:20.
1>InitializeBuildStatus:
1>  Touching "Debug\DirectX11.unsuccessfulbuild".
1>ClCompile:
1>  All outputs are up-to-date.
1>ManifestResourceCompile:
1>  All outputs are up-to-date.
1>main.obj : error LNK2019: unresolved external symbol "bool __cdecl InitializeDirect3d11App(struct HINSTANCE__ *)" (?InitializeDirect3d11App@@YA_NPAUHINSTANCE__@@@Z) referenced in function _WinMain@16
1>c:\users\mike\documents\visual studio 2010\Projects\DirectX11\Debug\DirectX11.exe : fatal error LNK1120: 1 unresolved externals
1>
1>Build FAILED.
1>
1>Time Elapsed 00:00:00.19
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========

 

 

thanks.

Share this post


Link to post
Share on other sites
Advertisement

This just means that the function

bool InitializeDirect3d11App(HINSTANCE__ *)

that is used in your

_WinMain function is never defined anywhere

 

It is called, but the compiler cannot find the actual function definition.

Share this post


Link to post
Share on other sites

It is not a compile error it is a linker error.
Add the .CPP file containing that function to your project or, if you believe it already is then perform a full rebuild.

If the .CPP file is added and a full rebuild still fails, check the declaration of that function in its header file and ensure it is an exact match for its definition in the .CPP file (also assuming it exists in the .CPP at all).

 

 

L. Spiro

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!