Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compiling with Visual Studio 2012 #1

Open
ghost opened this issue May 23, 2013 · 2 comments
Open

Compiling with Visual Studio 2012 #1

ghost opened this issue May 23, 2013 · 2 comments

Comments

@ghost
Copy link

ghost commented May 23, 2013

Hi,

I was looking for a small but efficient GLSL friendly C library, and found yours very useful. I just wanted to point out couple of things regarding the compilation with the Visual Studio 2012 Express, as C code:

  • 'inline' needs to be substituted with '__inline'
  • a couple of matrix declarations just need to be shifted before the first function call take place ('mat4x4 S ...;' and 'mat4x4 C;' in 'mat4x4_rotate' fun)
@datenwolf
Copy link
Owner

linmath.h is meant to be used using a C99 compiler, where mixed declaration is allowed. Also the inline keyword is part of C99 as well. Yes, I admit that for use with C++ this library needs some adjustments, but using a modern C compiler, with C99 mode enabled, it works just fine.

@ghost
Copy link
Author

ghost commented Oct 14, 2013

Yes, the thing is that Visual Studio has a very bad support for C99. According to MS, this should change with VS 2013 edition, and hopefully it will get a real C99 compile mode.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant