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 Mac OS X: "-Wno-deprecated" is valid for C++/Java/ObjC++ but not for C #29

Closed
calder opened this issue Dec 19, 2013 · 2 comments

Comments

@calder
Copy link

calder commented Dec 19, 2013

Compiling on Mac OS 10.8.5 following the Mac build instructions yields this:

gcc -I/usr/local/include -I/usr/local/Cellar/readline/6.2.4/include  -DHAVE_CONFIG_H -Wall -Wextra -Werror -Wno-deprecated -fno-strict-aliasing -fno-omit-frame-pointer -ggdb -I. -I. -c main.c -o main.o
cc1: warnings being treated as errors
cc1: warning: command line option "-Wno-deprecated" is valid for C++/Java/ObjC++ but not for C
make: *** [main.o] Error 1

It's fixable by removing "-Werror" from Makefile.in:7, but I'm not sure if that's something you want to do.

@vysheng
Copy link
Owner

vysheng commented Dec 19, 2013

I know about this problem, but I don't know any good workarounds. I want to keep -Werror, so I put -Wno-deprecated. Deprecated functions are in libopenssl and I think it is ok to use them. They are not marked as deprecated on linux. Probably newer version of gcc will compile it. If not you can remove -Wno-deprecated and -Werror and it should be fine.

@calder
Copy link
Author

calder commented Dec 20, 2013

Ok, thanks!

On Thu, Dec 19, 2013 at 4:20 PM, vysheng notifications@github.com wrote:

I know about this problem, but I don't know any good workarounds. I want
to keep -Werror, so I put -Wno-deprecated. Deprecated functions are in
libopenssl and I think it is ok to use them. They are not marked as
deprecated on linux. Probably newer version of gcc will compile it. If not
you can remove -Wno-deprecated and -Werror and it should be fine.


Reply to this email directly or view it on GitHubhttps://github.com//issues/29#issuecomment-30972231
.

@vysheng vysheng closed this as completed Dec 20, 2013
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

2 participants