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

C++17 support for DoD:S Linux #288

Open
APGRoboCop opened this issue Dec 16, 2024 · 0 comments
Open

C++17 support for DoD:S Linux #288

APGRoboCop opened this issue Dec 16, 2024 · 0 comments

Comments

@APGRoboCop
Copy link

APGRoboCop commented Dec 16, 2024

I wasn't sure if you knew this, but HL2SDK-DODS appears to have a depreciated register in mathlib.h, maybe more, as I cannot compile RCBot2 for DoDS Linux:

/home/linux/Dropbox/src/rcbot2/alliedmodders/hl2sdk-dods/public/mathlib/mathlib.h:331:2: error: ISO C++17 does not allow 'register' storage class specifier [-Wregister] register double __cosr, __sinr; ^~~~~~~~~ /home/linux/Dropbox/src/rcbot2/alliedmodders/hl2sdk-dods/public/mathlib/mathlib.h:331:2: error: ISO C++17 does not allow 'register' storage class specifier [-Wregister] register double __cosr, __sinr; ^~~~~~~~~
Of course, this doesn't affect Windows as it only affects Linux:
#elif defined( _LINUX ) || defined ( __APPLE__ ) register double __cosr, __sinr; __asm __volatile__ ("fsincos" : "=t" (__cosr), "=u" (__sinr) : "0" (radians)); *sine = __sinr; *cosine = __cosr; #endif

I would use the -Wno-register Clang flag in my AMBuildScript, but I don't think that would be wise, as suppressing the warning does not fix the underlying issue.

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