-
Notifications
You must be signed in to change notification settings - Fork 322
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
Fix a few warnings #128
Fix a few warnings #128
Conversation
The warning is gone on clang 3.8.0. On the other hand I'm getting a linking error (already happening in
The symbol is diff --git a/src/makefile b/src/makefile
index c752296..74db6ae 100644
--- a/src/makefile
+++ b/src/makefile
@@ -5,8 +5,8 @@
# Variables.
CXX ?= g++
-CXXFLAGS = -MMD -MP -I. -std=c++14 -Wextra -Wpedantic -Wall -O3 -DBOOST_LOG_DYN_LINK
-LDLIBS = -lboost_system -lboost_log -lboost_log_setup -lpthread -lboost_thread
+CXXFLAGS = -MMD -MP -I. -std=c++14 -Wextra -Wpedantic -Wall -O3 -DBOOST_LOG_DYN_LINK -stdlib=libstdc++
+LDLIBS = -lboost_system -lboost_log -lboost_log_setup -lpthread -lboost_thread -lstdc++
# Using all cpp files in current directory.
MAIN = ../bin/vroom Not sure if this is limited to this clang version, or if we should include those flags for clang only? |
Whats you CXX? This looks like your are using The flags you added tell the C-compiler to link the C++ standard library. |
My bad, I'd been indeed trying with |
Regarding the I've updated my |
Note for future reference: if we upgrade to |
I downloaded this zip: https://github.com/Tencent/rapidjson/archive/v1.1.0.zip and manually copied the files from the include directory. If I take a look at the v.1.1.0 tag via the github webinterface, it does not contain the cursorstreamwrapper.h file. /e However, I'll check if I included the correct version |
I looked at the diff the wrong way around, the |
This fixes warnings on gcc 8.1.0 and clang 6.0.0, should have no downsides
No semantic change, silences a warning on clang 3.8.0 through 5.0.0
Yep, looks like I did not use the correct rapidjson version and made a mistake while copying. I updated the commits in this PR such that rapidjson is now the version from the tag v1.1.0 plus 54dab1ee, since that commit silences a new warning that was introduced in gcc 8. |
This PR updates rapidjson to 1.1 since 1.0.2 was giving me a lot of warnings on gcc 8.1.0 and clang 6.0.0.
Additionally it adresses #114 by adding the requested braces. This warning is only emitted on clang <= 5.0.0.
With this PR, vroom compiles without warnings for me on gcc 8.1.0 and clang 6.0.0.
Issue
fixes #114
Tasks