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

[osx] -Wpedantic can not be enabled as we use a GNU extension #30

Open
k4rtik opened this issue Jan 8, 2016 · 0 comments
Open

[osx] -Wpedantic can not be enabled as we use a GNU extension #30

k4rtik opened this issue Jan 8, 2016 · 0 comments

Comments

@k4rtik
Copy link
Contributor

k4rtik commented Jan 8, 2016

If I add -pedantic/-Wpedantic to the Makefile, I receive the following errors:

$ make
cc -fPIC -Wall -Werror -Wunused -Wextra -Wpedantic -O0 -g -std=c11 -fprofile-arcs -ftest-coverage   -c -o common.o common.c
In file included from common.c:5:
./common.h:36:14: error: token pasting of ',' and __VA_ARGS__ is a GNU extension [-Werror,-Wgnu-zero-variadic-macro-arguments]
    log_err(M, ##__VA_ARGS__);                                                 \
             ^
./common.h:25:55: error: token pasting of ',' and __VA_ARGS__ is a GNU extension [-Werror,-Wgnu-zero-variadic-macro-arguments]
          __LINE__, __FUNCTION__, errno, clean_errno(), ##__VA_ARGS__)
                                                      ^
./common.h:36:14: error: token pasting of ',' and __VA_ARGS__ is a GNU extension [-Werror,-Wgnu-zero-variadic-macro-arguments]
    log_err(M, ##__VA_ARGS__);                                                 \
             ^
./common.h:25:55: error: token pasting of ',' and __VA_ARGS__ is a GNU extension [-Werror,-Wgnu-zero-variadic-macro-arguments]
          __LINE__, __FUNCTION__, errno, clean_errno(), ##__VA_ARGS__)
                                                      ^
4 errors generated.
make: *** [common.o] Error 1

No clean solution exists. See: https://stackoverflow.com/questions/5588855/standard-alternative-to-gccs-va-args-trick

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