Keitel
January 10, 2015, 7:51pm
1
Hi,
I am trying to compile some of the recording examples, but get many syntax errors in the xstddef and cstdlib files when compiling. Could anyone explain why? I am working in C with Microsoft Visual C++ 2010 Express in Windows 7.
Thanks in advance.
Keitel
mathew
January 12, 2015, 12:58am
2
Can you please provide the exact errors you are getting.
Keitel
January 12, 2015, 1:46am
3
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(19): error C2054: expected ‘(’ to follow ‘using’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(19): error C2061: syntax error : identifier ‘using’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(19): error C2054: expected ‘(’ to follow ‘using’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(21): error C2061: syntax error : identifier ‘using’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(21): error C2061: syntax error : identifier ‘abs’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(21): error C2059: syntax error : ‘;’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(21): error C2061: syntax error : identifier ‘atexit’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(21): error C2059: syntax error : ‘;’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(22): error C2061: syntax error : identifier ‘atof’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(22): error C2059: syntax error : ‘;’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(22): error C2061: syntax error : identifier ‘atoi’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(22): error C2059: syntax error : ‘;’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(22): error C2061: syntax error : identifier ‘atol’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(22): error C2059: syntax error : ‘;’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(23): error C2061: syntax error : identifier ‘bsearch’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(23): error C2059: syntax error : ‘;’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(23): error C2061: syntax error : identifier ‘calloc’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(23): error C2059: syntax error : ‘;’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(23): error C2061: syntax error : identifier ‘div’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(23): error C2059: syntax error : ‘;’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(24): error C2061: syntax error : identifier ‘exit’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(24): error C2059: syntax error : ‘;’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(24): error C2061: syntax error : identifier ‘free’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(24): error C2059: syntax error : ‘;’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(24): error C2061: syntax error : identifier ‘getenv’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(24): error C2059: syntax error : ‘;’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(25): error C2061: syntax error : identifier ‘labs’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(25): error C2059: syntax error : ‘;’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(25): error C2061: syntax error : identifier ‘ldiv’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(25): error C2059: syntax error : ‘;’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(25): error C2061: syntax error : identifier ‘malloc’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(25): error C2059: syntax error : ‘;’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(26): error C2061: syntax error : identifier ‘mblen’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(26): error C2059: syntax error : ‘;’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(26): error C2061: syntax error : identifier ‘mbstowcs’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(26): error C2059: syntax error : ‘;’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(26): error C2061: syntax error : identifier ‘mbtowc’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(26): error C2059: syntax error : ‘;’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(27): error C2061: syntax error : identifier ‘qsort’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(27): error C2059: syntax error : ‘;’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(27): error C2061: syntax error : identifier ‘rand’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(27): error C2059: syntax error : ‘;’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(27): error C2061: syntax error : identifier ‘realloc’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(27): error C2059: syntax error : ‘;’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(28): error C2061: syntax error : identifier ‘srand’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(28): error C2059: syntax error : ‘;’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(28): error C2061: syntax error : identifier ‘strtod’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(28): error C2059: syntax error : ‘;’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(28): error C2061: syntax error : identifier ‘strtol’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(28): error C2059: syntax error : ‘;’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(29): error C2061: syntax error : identifier ‘strtoul’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(29): error C2059: syntax error : ‘;’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(29): error C2061: syntax error : identifier ‘system’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(29): error C2059: syntax error : ‘;’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(30): error C2061: syntax error : identifier ‘wcstombs’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(30): error C2059: syntax error : ‘;’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(30): error C2061: syntax error : identifier ‘wctomb’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(30): error C2059: syntax error : ‘;’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(32): error C2054: expected ‘(’ to follow ‘using’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(34): error C2061: syntax error : identifier ‘using’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(34): error C2061: syntax error : identifier ‘lldiv’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstdlib(34): error C2059: syntax error : ‘;’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstddef(18): error C2054: expected ‘(’ to follow ‘using’
1>c:\program files\microsoft visual studio 10.0\vc\include\cstddef(18): error C2061: syntax error : identifier ‘using’
1>c:\program files\microsoft visual studio 10.0\vc\include\xstddef(78): error C2143: syntax error : missing ‘{’ before ‘<’
1>c:\program files\microsoft visual studio 10.0\vc\include\xstddef(78): error C2059: syntax error : ‘<’
1>c:\program files\microsoft visual studio 10.0\vc\include\xstddef(87): error C2143: syntax error : missing ‘{’ before ‘<’
1>c:\program files\microsoft visual studio 10.0\vc\include\xstddef(87): error C2059: syntax error : ‘<’
1>c:\program files\microsoft visual studio 10.0\vc\include\xstddef(98): error C2061: syntax error : identifier ‘tr1’
1>c:\program files\microsoft visual studio 10.0\vc\include\xstddef(98): error C2059: syntax error : ‘;’
1>c:\program files\microsoft visual studio 10.0\vc\include\xstddef(98): error C2449: found ‘{’ at file scope (missing function header?)
1>c:\program files\microsoft visual studio 10.0\vc\include\xstddef(101): error C2059: syntax error : ‘}’
1>c:\program files\microsoft visual studio 10.0\vc\include\xstddef(125): error C2143: syntax error : missing ‘{’ before ‘:’
1>c:\program files\microsoft visual studio 10.0\vc\include\xstddef(125): error C2059: syntax error : ‘:’
1>c:\program files\microsoft visual studio 10.0\vc\include\xstddef(132): error C2143: syntax error : missing ‘{’ before ‘<’
1>c:\program files\microsoft visual studio 10.0\vc\include\xstddef(132): error C2059: syntax error : ‘<’
1>c:\program files\microsoft visual studio 10.0\vc\include\xstddef(141): error C2143: syntax error : missing ‘{’ before ‘<’
1>c:\program files\microsoft visual studio 10.0\vc\include\xstddef(141): error C2059: syntax error : ‘<’
1>c:\program files\microsoft visual studio 10.0\vc\include\eh.h(27): fatal error C1189: #error : “eh.h is only for C++!”
1> Generating Code…
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
brett
February 1, 2015, 11:27pm
4
This isnt really an FMOD issue, a quick google of your error leads me to this as the top result
Keitel
February 2, 2015, 11:45am
5
Thanks for your answer. Sorry for my ignorance, but with my limited knowledge, I don’t always know what’s directly related to Fmod or not. But I understand that there are header files that can only be used for C++ and not for C. it’s logical, I just didn’t think of it. I also now understand that I need to reference stdlib.h instead of cstdlib.h - and maybe there’s a reference here to the other header files that get errors - but the problem is that I don’t understand where the reference to cstdlib is made. Because I can’t find it neither in the main file nor in the header files it refers to, while I also have been looking in the project properties, but can’t find it there either. This would then probably be an issue more suitable for the MSDN forum, but since we’re already at it, I ask you for now. Maybe it also can be useful to others.
Thanks in advance