wiiyourself in Visual studio 2008

A place for Ogre users to discuss non-Ogre subjects with friends from the community.
bryanevil
Gnoblar
Posts: 16
Joined: Wed Aug 06, 2008 2:49 pm

wiiyourself in Visual studio 2008

Post by bryanevil »

Hi all

I just couldnt make the wiimote work with wiiyourself in VS2008. I believe the problem is the way i setup my project. My OS is vista, i have the DDK download and linked the lib and incl in the project. no error when i bulid the project but some warning:

Code: Select all

1>Linking...
1>WiiYourself!.lib(wiimote.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 LNK4075: ignoring '/INCREMENTAL' due to '/LTCG' specification
1>LINK : warning LNK4098: defaultlib 'MSVCRT' conflicts with use of other libs; use /NODEFAULTLIB:library
1>Generating code
1>Finished generating code
1>WiiYourself!.lib(wiimote.obj) : warning LNK4099: PDB 'vc80.pdb' was not found with 'WiiYourself!.lib' or at 'C:\Users\Bryan\Documents\Visual Studio 2008\Projects\wiiyourself_test\Debug\vc80.pdb'; linking object as if no debug info
1>Embedding manifest...
1>Microsoft (R) Windows (R) Resource Compiler Version 6.0.5724.0
1>Copyright (C) Microsoft Corporation.  All rights reserved.
1>WiiYourself!.lib(wiimote.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 LNK4075: ignoring '/INCREMENTAL' due to '/LTCG' specification
1>LINK : warning LNK4098: defaultlib 'MSVCRT' conflicts with use of other libs; use /NODEFAULTLIB:library
1>Generating code
1>Finished generating code
1>WiiYourself!.lib(wiimote.obj) : warning LNK4099: PDB 'vc80.pdb' was not found with 'WiiYourself!.lib' or at 'c:\Users\Bryan\Documents\Visual Studio 2008\Projects\wiiyourself_test\Debug\vc80.pdb'; linking object as if no debug info
1>Build log was saved at "file://c:\Users\Bryan\Documents\Visual Studio 2008\Projects\wiiyourself_test\wiiyourself_test\Debug\BuildLog.htm"
1>wiiyourself_test - 0 error(s), 6 warning(s)
========== Build: 1 succeeded, 0 failed, 0 up-to-date, 0 skipped ==========
but when i run it, i get a error dialog box:

This application has failed to start because MSVCR90.dll was not found......

can anyone help me please.Thank you.

Bryan
bryanevil
Gnoblar
Posts: 16
Joined: Wed Aug 06, 2008 2:49 pm

Post by bryanevil »

problem solve.

change the runtime library from Multi-thread debug DLL to Multi-thread DLL.

can anyone give a quick explain why so we all know.

Thanks

Bryan
Murphy
Greenskin
Posts: 102
Joined: Tue May 10, 2005 11:42 pm
Location: SF, California

Post by Murphy »

All code must be compiled with the same runtime library. That is just the way it is :)
kelts
Gnoblar
Posts: 2
Joined: Thu Jan 08, 2009 10:34 am

Re: wiiyourself in Visual studio 2008

Post by kelts »

Hi, I am using wiiyourself (1.01a) in VS2008 too. However, I received show compile errors:
Error 1 error C2146: syntax error : missing ';' before identifier 'fpos_t' c:\program files\microsoft visual studio 9.0\vc\include\iosfwd 41 WiiYourself! lib
Error 2 error C4430: missing type specifier - int assumed. Note: C++ does not support default-int c:\program files\microsoft visual studio 9.0\vc\include\iosfwd 41 WiiYourself! lib
Error 3 error C2143: syntax error : missing ';' before 'const' c:\program files\microsoft visual studio 9.0\vc\include\iosfwd 42 WiiYourself! lib
Error 4 error C4430: missing type specifier - int assumed. Note: C++ does not support default-int c:\program files\microsoft visual studio 9.0\vc\include\iosfwd 42 WiiYourself! lib
Error 5 error C2734: 'std::_BADOFF' : const object must be initialized if not extern c:\program files\microsoft visual studio 9.0\vc\include\iosfwd 42 WiiYourself! lib
Error 6 error C2144: syntax error : 'int' should be preceded by ';' c:\program files\microsoft visual studio 9.0\vc\include\iosfwd 207 WiiYourself! lib
Error 7 error C4430: missing type specifier - int assumed. Note: C++ does not support default-int c:\program files\microsoft visual studio 9.0\vc\include\iosfwd 207 WiiYourself! lib
Error 8 error C2143: syntax error : missing ';' before '*' c:\program files\microsoft visual studio 9.0\vc\include\iosfwd 207 WiiYourself! lib
Error 9 error C4430: missing type specifier - int assumed. Note: C++ does not support default-int c:\program files\microsoft visual studio 9.0\vc\include\iosfwd 207 WiiYourself! lib
Error 10 error C4430: missing type specifier - int assumed. Note: C++ does not support default-int c:\program files\microsoft visual studio 9.0\vc\include\iosfwd 207 WiiYourself! lib
Error 11 error C2061: syntax error : identifier '_Elem' c:\program files\microsoft visual studio 9.0\vc\include\iosfwd 207 WiiYourself! lib
Error 12 error C4430: missing type specifier - int assumed. Note: C++ does not support default-int c:\program files\microsoft visual studio 9.0\vc\include\iosfwd 209 WiiYourself! lib
Anyone has any idea? Thanks!
User avatar
Kojack
OGRE Moderator
OGRE Moderator
Posts: 7157
Joined: Sun Jan 25, 2004 7:35 am
Location: Brisbane, Australia
x 535

Re: wiiyourself in Visual studio 2008

Post by Kojack »

At a guess, you have a syntax error just before including a standard library header.
The error is propagating into the header, so the compiler thinks that's where the problem is, but it's really in something you put before the header.
kelts
Gnoblar
Posts: 2
Joined: Thu Jan 08, 2009 10:34 am

Re: wiiyourself in Visual studio 2008

Post by kelts »

The code before the headers look alright and I've not make any changes to code which I've downloaded from http://wiiyourself.gl.tter.org/WiiYourself!_1.01a.zip. These errors actually come from a Visual studio file called iosfwd.
boo
Gnoblar
Posts: 1
Joined: Thu Dec 17, 2009 1:32 pm
Location: Ireland

Re: wiiyourself in Visual studio 2008

Post by boo »

Hi guys,

I'm trying to integrate the WiiYourself libraries into my Ogre application and it's throwing up a huge amount of errors. I downloaded the WDK and linked all my inc and libs in the project but when I run it it gives the following errors

Code: Select all

Error	8	error C2059: syntax error : ')'	c:\program files\microsoft visual studio 9.0\vc\include\excpt.h	64
Error	26	error C2059: syntax error : ')'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	94
Error	33	error C2059: syntax error : ')'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	95
Error	38	error C2059: syntax error : ')'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	96
Error	44	error C2059: syntax error : ')'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	97
Error	49	error C2059: syntax error : ')'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	98
Error	55	error C2059: syntax error : ')'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	99
Error	60	error C2059: syntax error : ')'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	100
Error	66	error C2059: syntax error : ')'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	101
Error	71	error C2059: syntax error : ')'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	102
Error	77	error C2059: syntax error : ')'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	103
Error	82	error C2059: syntax error : ')'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	104
Error	88	error C2059: syntax error : ')'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	105
Error	93	error C2059: syntax error : ')'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	106
Error	99	error C2059: syntax error : ')'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	107
Error	2	error C2065: '_In_' : undeclared identifier	c:\program files\microsoft visual studio 9.0\vc\include\excpt.h	60
Error	22	error C2065: '_In_' : undeclared identifier	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	94
Error	28	error C2065: '_In_' : undeclared identifier	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	95
Error	35	error C2065: '_In_' : undeclared identifier	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	96
Error	40	error C2065: '_In_' : undeclared identifier	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	97
Error	46	error C2065: '_In_' : undeclared identifier	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	98
Error	51	error C2065: '_In_' : undeclared identifier	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	99
Error	57	error C2065: '_In_' : undeclared identifier	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	100
Error	62	error C2065: '_In_' : undeclared identifier	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	101
Error	68	error C2065: '_In_' : undeclared identifier	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	102
Error	73	error C2065: '_In_' : undeclared identifier	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	103
Error	79	error C2065: '_In_' : undeclared identifier	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	104
Error	84	error C2065: '_In_' : undeclared identifier	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	105
Error	90	error C2065: '_In_' : undeclared identifier	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	106
Error	95	error C2065: '_In_' : undeclared identifier	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	107
Error	101	error C2065: '_In_' : undeclared identifier	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	108
Error	9	error C2143: syntax error : missing ';' before '*'	c:\winddk\7600.16385.0\inc\api\windef.h	49
Error	10	error C2143: syntax error : missing ';' before '*'	c:\winddk\7600.16385.0\inc\api\windef.h	51
Error	11	error C2143: syntax error : missing ';' before '*'	c:\winddk\7600.16385.0\inc\api\windef.h	53
Error	12	error C2143: syntax error : missing ';' before '*'	c:\winddk\7600.16385.0\inc\api\windef.h	157
Error	13	error C2143: syntax error : missing ';' before '*'	c:\winddk\7600.16385.0\inc\api\windef.h	158
Error	14	error C2143: syntax error : missing ';' before '*'	c:\winddk\7600.16385.0\inc\api\windef.h	159
Error	15	error C2143: syntax error : missing ';' before '*'	c:\winddk\7600.16385.0\inc\api\windef.h	160
Error	16	error C2143: syntax error : missing ';' before '*'	c:\winddk\7600.16385.0\inc\api\windef.h	161
Error	17	error C2143: syntax error : missing ';' before '*'	c:\winddk\7600.16385.0\inc\api\windef.h	164
Error	18	error C2143: syntax error : missing ';' before '*'	c:\winddk\7600.16385.0\inc\api\windef.h	165
Error	19	error C2143: syntax error : missing ';' before '*'	c:\winddk\7600.16385.0\inc\api\windef.h	167
Error	20	error C2143: syntax error : missing ';' before '*'	c:\winddk\7600.16385.0\inc\api\windef.h	168
Error	6	error C2144: syntax error : '_CONTEXT' should be preceded by ';'	c:\program files\microsoft visual studio 9.0\vc\include\excpt.h	62
Error	3	error C2144: syntax error : '_EXCEPTION_RECORD' should be preceded by ')'	c:\program files\microsoft visual studio 9.0\vc\include\excpt.h	60
Error	23	error C2144: syntax error : 'int' should be preceded by ')'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	94
Error	29	error C2144: syntax error : 'int' should be preceded by ')'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	95
Error	36	error C2144: syntax error : 'int' should be preceded by ')'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	96
Error	41	error C2144: syntax error : 'int' should be preceded by ')'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	97
Error	47	error C2144: syntax error : 'int' should be preceded by ')'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	98
Error	52	error C2144: syntax error : 'int' should be preceded by ')'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	99
Error	58	error C2144: syntax error : 'int' should be preceded by ')'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	100
Error	63	error C2144: syntax error : 'int' should be preceded by ')'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	101
Error	69	error C2144: syntax error : 'int' should be preceded by ')'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	102
Error	74	error C2144: syntax error : 'int' should be preceded by ')'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	103
Error	80	error C2144: syntax error : 'int' should be preceded by ')'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	104
Error	85	error C2144: syntax error : 'int' should be preceded by ')'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	105
Error	91	error C2144: syntax error : 'int' should be preceded by ')'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	106
Error	96	error C2144: syntax error : 'int' should be preceded by ')'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	107
Error	102	error C2144: syntax error : 'int' should be preceded by ')'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	108
Error	21	error C2144: syntax error : 'int' should be preceded by ';'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	94
Error	25	error C2144: syntax error : 'int' should be preceded by ';'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	94
Error	27	error C2144: syntax error : 'int' should be preceded by ';'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	95
Error	31	error C2144: syntax error : 'int' should be preceded by ';'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	95
Error	34	error C2144: syntax error : 'int' should be preceded by ';'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	96
Error	39	error C2144: syntax error : 'int' should be preceded by ';'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	97
Error	45	error C2144: syntax error : 'int' should be preceded by ';'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	98
Error	50	error C2144: syntax error : 'int' should be preceded by ';'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	99
Error	56	error C2144: syntax error : 'int' should be preceded by ';'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	100
Error	61	error C2144: syntax error : 'int' should be preceded by ';'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	101
Error	67	error C2144: syntax error : 'int' should be preceded by ';'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	102
Error	72	error C2144: syntax error : 'int' should be preceded by ';'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	103
Error	78	error C2144: syntax error : 'int' should be preceded by ';'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	104
Error	83	error C2144: syntax error : 'int' should be preceded by ';'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	105
Error	89	error C2144: syntax error : 'int' should be preceded by ';'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	106
Error	94	error C2144: syntax error : 'int' should be preceded by ';'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	107
Error	100	error C2144: syntax error : 'int' should be preceded by ';'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	108
Error	5	error C2144: syntax error : 'void' should be preceded by ';'	c:\program files\microsoft visual studio 9.0\vc\include\excpt.h	61
Error	7	error C2144: syntax error : 'void' should be preceded by ';'	c:\program files\microsoft visual studio 9.0\vc\include\excpt.h	63
Error	32	error C2146: syntax error : missing ';' before identifier '_locale_t'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	95
Error	43	error C2146: syntax error : missing ';' before identifier '_locale_t'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	97
Error	54	error C2146: syntax error : missing ';' before identifier '_locale_t'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	99
Error	65	error C2146: syntax error : missing ';' before identifier '_locale_t'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	101
Error	76	error C2146: syntax error : missing ';' before identifier '_locale_t'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	103
Error	87	error C2146: syntax error : missing ';' before identifier '_locale_t'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	105
Error	98	error C2146: syntax error : missing ';' before identifier '_locale_t'	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	107
Error	4	error C2448: '_except_handler' : function-style initializer appears to be a function definition	c:\program files\microsoft visual studio 9.0\vc\include\excpt.h	60
Error	42	error C2448: '_isalpha_l' : function-style initializer appears to be a function definition	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	97
Error	24	error C2448: '_isctype' : function-style initializer appears to be a function definition	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	94
Error	30	error C2448: '_isctype_l' : function-style initializer appears to be a function definition	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	95
Error	75	error C2448: '_isdigit_l' : function-style initializer appears to be a function definition	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	103
Error	64	error C2448: '_islower_l' : function-style initializer appears to be a function definition	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	101
Error	97	error C2448: '_isspace_l' : function-style initializer appears to be a function definition	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	107
Error	53	error C2448: '_isupper_l' : function-style initializer appears to be a function definition	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	99
Error	86	error C2448: '_isxdigit_l' : function-style initializer appears to be a function definition	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	105
Error	37	error C2448: 'isalpha' : function-style initializer appears to be a function definition	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	96
Error	70	error C2448: 'isdigit' : function-style initializer appears to be a function definition	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	102
Error	59	error C2448: 'islower' : function-style initializer appears to be a function definition	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	100
Error	92	error C2448: 'isspace' : function-style initializer appears to be a function definition	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	106
Error	48	error C2448: 'isupper' : function-style initializer appears to be a function definition	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	98
Error	81	error C2448: 'isxdigit' : function-style initializer appears to be a function definition	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	104
Error	103	fatal error C1003: error count exceeds 100; stopping compilation	c:\program files\microsoft visual studio 9.0\vc\include\ctype.h	108
Anyone have any ideas why I'm getting these errors? I haven't changed or added any additional code yet and tried all solutions I found on this page. Thanks
RudeMatrix
Gnoblar
Posts: 7
Joined: Sun Dec 13, 2009 3:49 am

Re: wiiyourself in Visual studio 2008

Post by RudeMatrix »

I know this is an old post, but in case anyone comes across it and is still having problems you may find my post usefull:

http://rudematrix.co.uk/?p=322

it explains the problems i had with the library and provides .libs for 08, 05 both release and debug, I hope this helps someone!
Maraster
Gnoblar
Posts: 1
Joined: Wed Mar 23, 2011 8:25 am

Re: wiiyourself in Visual studio 2008

Post by Maraster »

For anybody else having the issue with a large number of syntax errors from windows' own libraries such as stdio.h and such I found that the solution was to rearrange the include directories. You must include the windows ddk include folders in the right place and order. It must be done in the directories part of the property page for the project. If you try to put it in the property for 'additional includes' that won't work (or at least I couldn't get it to work). I was working on compiling the wiiuse library as part of the wiibalance board project. I'll post the compiled libraries and modified vrpn server on my page at some point soon so others can just use them without wasting time if they'd like:)

I know this was an older post but this answer isn't exactly anywhere else and not specifically mentioned for the wii libraries.

Here is the order you should use:

http://stackoverflow.com/questions/3337 ... rs-problem

and in case that gets taken down, here is the text copied over:

-------
Hi, I found a solution, don't know why this is working, but it is!:

In Visual Studio go to:

Tools->Options->Projects->VC++ Directories and then Show directories for: include files.

Add this folders:

C:\WinDDK\7600.16385.1\inc\ddk and C:\WinDDK\7600.16385.1\inc\api

Now here is the trick that solved the problem for me and I don't know why, because seems odd but here it is:

C:\WinDDK\7600.16385.1\inc\ddk -> This directory have to be the first directory in the list!

C:\WinDDK\7600.16385.1\inc\api -> This directory have to be ABOVE "$(WindowsSdkDir)\include" BUT BELOW "$(VCInstallDir)include"

Example:

C:\WinDDK\7600.16385.1\inc\ddk
$(VCInstallDir)include
$(VCInstallDir)atlmfc\include
C:\WinDDK\7600.16385.1\inc\api
$(WindowsSdkDir)\include
$(FrameworkSDKDir)include
Carlos

link|edit|flag
answered Jul 26 '10 at 19:45
Carlos Dubus
303

-------