OK, I have been learning DirectX for a while now and everything has been going (mostly) great. I am about throught with the graphics part and moving on to DirectInput. The first example that I did is throwing these errors at me.
Now, and correct me if I am wrong, it looks to me that it is trying to include 'uuid.lib' twice, but I cannot find where it is doing this, much less how to correct it.Code:Warning: .drectve `/DEFAULTLIB:"uuid.lib" /DEFAULTLIB:"uuid.lib" ' unrecognized Warning: .drectve `/DEFAULTLIB:"uuid.lib" /DEFAULTLIB:"uuid.lib" ' unrecognized cFramework.o(.text+0x6b9):cFramework.cpp: undefined reference to `IID_IDirectInput8A' cInput.o(.text+0x219):cInput.cpp: undefined reference to `GUID_SysKeyboard' cInput.o(.text+0x2bb):cInput.cpp: undefined reference to `GUID_SysMouse' C:/Dev-Cpp/lib/libdinput8.a(dilib2.obj)(.text+0x0):..\dilib2.c: undefined reference to `GUID_Key' C:/Dev-Cpp/lib/libdinput8.a(dilib2.obj)(.text+0x10):..\dilib2.c: undefined reference to `GUID_Key' C:/Dev-Cpp/lib/libdinput8.a(dilib2.obj)(.text+0x20):..\dilib2.c: undefined reference to `GUID_Key' C:/Dev-Cpp/lib/libdinput8.a(dilib2.obj)(.text+0x30):..\dilib2.c: undefined reference to `GUID_Key' C:/Dev-Cpp/lib/libdinput8.a(dilib2.obj)(.text+0x40):..\dilib2.c: undefined reference to `GUID_Key' C:/Dev-Cpp/lib/libdinput8.a(dilib2.obj)(.text+0x50):..\dilib2.c: more undefined references to `GUID_Key' follow C:/Dev-Cpp/lib/libdinput8.a(dilib1.obj)(.text+0x0):..\dilib1.c: undefined reference to `GUID_XAxis' C:/Dev-Cpp/lib/libdinput8.a(dilib1.obj)(.text+0x10):..\dilib1.c: undefined reference to `GUID_YAxis' C:/Dev-Cpp/lib/libdinput8.a(dilib1.obj)(.text+0x20):..\dilib1.c: undefined reference to `GUID_ZAxis'
I have read various texts that state you must
so that you can use GUID_SysKeyboard / GUID_SysMouse andCode:#define INITGUID
but these do not seem to make any differenceCode:#define DIRECTINPUT_VERSION 0x0800
I am thinking that all the other errors on the list originate from the first two lines but I am at a lost as to how to resolve it.
This is what my main header looks like
and the only linker options i have areCode:#ifndef STDHEADER_H #define STDHEADER_H #define INITGUID #define DIRECTINPUT_VERSION 0x0800 #define WIN32_LEAN_AND_MEAN // Incudes #include <windows.h> #include <ctime> #include <cstdio> // DirectX includes #include <d3d9.h> #include <d3dx9.h> #include <dinput.h> // other includes #include "cFramework.h" #include "cGraphics.h" #include "cGameApp.h" #include "CVertexBuffer.h" #include "CIndexBuffer.h" #include "CWorldTransform.h" #include "CUtility.h" #include "cTimer.h" #include "cFont.h" #include "cInput.h" // Macros #define KEYDOWN(vk_code) ( (GetAsyncKeyState(vk_code) & 0x8000) ? 1 : 0) #define KEYUP(vk_code) ( (GetAsyncKeyState(vk_code) & 0x8000) ? 0 : 1) #define SAFE_DELETE(X) { X = NULL; delete X; } #define SAFE_DELETE_ARRAY(X) if(X) { delete [] (X); (X) = NULL; } #define SAFE_RELEASE(X) if(X) { (X)->Release(); (X) = NULL; } #define SHOWERROR(s,f,l) char ErrBuf[1024]; \ sprintf(ErrBuf, "File: %s\nLine: %d\n%s",f,l,s); \ MessageBox(0, ErrBuf, "Error", 0); #endif
Thanx for any helpCode:-ldinput8 -ld3d9 -ld3dx9
I am using Dev-C++, Windows XP



LinkBack URL
About LinkBacks


