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

Build error on older GCC, e.g. 4.8.3 #165

Closed
troglobit opened this issue Aug 20, 2021 · 0 comments
Closed

Build error on older GCC, e.g. 4.8.3 #165

troglobit opened this issue Aug 20, 2021 · 0 comments

Comments

@troglobit
Copy link
Owner

In SMCRoute 2.5.0, inline declarations from C99 were introduced. This caused older toolchains, like the sourcery-arm toolchain in Buildroot, to fail. Older GCC like 4.8.3 have -std=gnu90 as their default. This changed in later releases to gnu99.

Example:

mroute.c: In function 'mfc_install':
mroute.c:498:3: error: 'for' loop initial declarations are only allowed in C99 mode
   for (size_t i = 0; i < NELEMS(route->ttl); i++) {
   ^
mroute.c:498:3: note: use option -std=c99 or -std=gnu99 to compile your code
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