|
-
Oct 1st, 2003, 02:57 PM
#1
Thread Starter
Frenzied Member
Error while compiling DX 9 app
Hi, I am trying to compile a sample from a book that I'm reading, but I get all these mysterious errors.....I have included/added the DX .h and .lib files to the linker/project...
Code:
test1.obj : error LNK2005: _WinMain@16 already defined in GPTEMP2.obj
test1.obj : error LNK2005: "int __cdecl Game_Init(void *)" (?Game_Init@@YAHPAX@Z) already defined in GPTEMP2.obj
test1.obj : error LNK2005: "int __cdecl Game_Shutdown(void *)" (?Game_Shutdown@@YAHPAX@Z) already defined in GPTEMP2.obj
test1.obj : error LNK2005: "int __cdecl Game_Main(void *)" (?Game_Main@@YAHPAX@Z) already defined in GPTEMP2.obj
test1.obj : error LNK2005: "struct HINSTANCE__ * main_instance" (?main_instance@@3PAUHINSTANCE__@@A) already defined in GPTEMP2.obj
test1.obj : error LNK2005: "struct HWND__ * main_window_handle" (?main_window_handle@@3PAUHWND__@@A) already defined in GPTEMP2.obj
test1.obj : error LNK2005: "char * buffer" (?buffer@@3PADA) already defined in GPTEMP2.obj
GPDUMB2.obj : error LNK2019: unresolved external symbol __imp__mmioAscend@12 referenced in function "int __cdecl Load_WAV(char *,int)" (?Load_WAV@@YAHPADH@Z)
GPDUMB2.obj : error LNK2019: unresolved external symbol __imp__mmioRead@12 referenced in function "int __cdecl Load_WAV(char *,int)" (?Load_WAV@@YAHPADH@Z)
GPDUMB2.obj : error LNK2019: unresolved external symbol __imp__mmioClose@8 referenced in function "int __cdecl Load_WAV(char *,int)" (?Load_WAV@@YAHPADH@Z)
GPDUMB2.obj : error LNK2019: unresolved external symbol __imp__mmioDescend@16 referenced in function "int __cdecl Load_WAV(char *,int)" (?Load_WAV@@YAHPADH@Z)
GPDUMB2.obj : error LNK2019: unresolved external symbol __imp__mmioOpenA@12 referenced in function "int __cdecl Load_WAV(char *,int)" (?Load_WAV@@YAHPADH@Z)
GPTEMP2.obj : error LNK2019: unresolved external symbol "int __cdecl DI_Init_Joystick(int,int,int,int)" (?DI_Init_Joystick@@YAHHHHH@Z) referenced in function "int __cdecl Game_Init(void *)" (?Game_Init@@YAHPAX@Z)
GPTEMP2.obj : error LNK2019: unresolved external symbol "int __cdecl DI_Init_Mouse(void)" (?DI_Init_Mouse@@YAHXZ) referenced in function "int __cdecl Game_Init(void *)" (?Game_Init@@YAHPAX@Z)
GPTEMP2.obj : error LNK2019: unresolved external symbol "int __cdecl DI_Init_Keyboard(void)" (?DI_Init_Keyboard@@YAHXZ) referenced in function "int __cdecl Game_Init(void *)" (?Game_Init@@YAHPAX@Z)
GPTEMP2.obj : error LNK2019: unresolved external symbol "int __cdecl DInput_Init(void)" (?DInput_Init@@YAHXZ) referenced in function "int __cdecl Game_Init(void *)" (?Game_Init@@YAHPAX@Z)
GPTEMP2.obj : error LNK2019: unresolved external symbol "void __cdecl DInput_Shutdown(void)" (?DInput_Shutdown@@YAXXZ) referenced in function "int __cdecl Game_Shutdown(void *)" (?Game_Shutdown@@YAHPAX@Z)
GPTEMP2.obj : error LNK2019: unresolved external symbol "void __cdecl DI_Release_Joystick(void)" (?DI_Release_Joystick@@YAXXZ) referenced in function "int __cdecl Game_Shutdown(void *)" (?Game_Shutdown@@YAHPAX@Z)
GPTEMP2.obj : error LNK2019: unresolved external symbol "void __cdecl DI_Release_Mouse(void)" (?DI_Release_Mouse@@YAXXZ) referenced in function "int __cdecl Game_Shutdown(void *)" (?Game_Shutdown@@YAHPAX@Z)
GPTEMP2.obj : error LNK2019: unresolved external symbol "void __cdecl DI_Release_Keyboard(void)" (?DI_Release_Keyboard@@YAXXZ) referenced in function "int __cdecl Game_Shutdown(void *)" (?Game_Shutdown@@YAHPAX@Z)
GPTEMP2.obj : error LNK2019: unresolved external symbol "int __cdecl DI_Read_Joystick(void)" (?DI_Read_Joystick@@YAHXZ) referenced in function "int __cdecl Game_Main(void *)" (?Game_Main@@YAHPAX@Z)
GPTEMP2.obj : error LNK2019: unresolved external symbol "int __cdecl DI_Read_Mouse(void)" (?DI_Read_Mouse@@YAHXZ) referenced in function "int __cdecl Game_Main(void *)" (?Game_Main@@YAHPAX@Z)
GPTEMP2.obj : error LNK2019: unresolved external symbol "int __cdecl DI_Read_Keyboard(void)" (?DI_Read_Keyboard@@YAHXZ) referenced in function "int __cdecl Game_Main(void *)" (?Game_Main@@YAHPAX@Z)
Debug/BreakOut.exe : fatal error LNK1120: 16 unresolved externals
Build log was saved at "file://d:\Game Programming\BreakOut\BreakOut\Debug\BuildLog.htm"
BreakOut - 25 error(s), 0 warning(s)
---------------------- Done ----------------------
Build: 0 succeeded, 1 failed, 0 skipped
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|