Comments (6)
@rai20 The problem with the -std=c++11 option can be fixed by replacing
add_compile_options(-std=c++11 )
with
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
I am not doing a pull request, because #8 is still an issue, I get the same error. Maybe you can check
from kuksa.apps.
Compilation also yields warnings
regarding the GCC-Compiler and the specified flags.
Starting with gcc 7.1
the code won't build anymore, due to outdated allocation-calls.
/usr/include/c++/6.4.0/bits/stl_algobase.h: In function '_OI std::__copy_move_a2(_II, _II, _OI) [with bool _IsMove = true; _II = jsoncons::key_value_pair<std::__cxx11::basic_string<char>, jsoncons::basic_json<char, jsoncons::sorted_policy, std::allocator<char> > >*; _OI = __gnu_cxx::__normal_iterator<jsoncons::key_value_pair<std::__cxx11::basic_string<char>, jsoncons::basic_json<char, jsoncons::sorted_policy, std::allocator<char> > >*, std::vector<jsoncons::key_value_pair<std::__cxx11::basic_string<char>, jsoncons::basic_json<char, jsoncons::sorted_policy, std::allocator<char> > >, std::allocator<jsoncons::key_value_pair<std::__cxx11::basic_string<char>, jsoncons::basic_json<char, jsoncons::sorted_policy, std::allocator<char> > > > > >]':
Since the current stable release is gcc 8.3
the build-scripts should be updated to conform to modern standards. (~50-100 of these are thrown)
from kuksa.apps.
Also the c++
-flag should be disabled, when compiling c
. This is a negligible warning, but bloats the logs
/std::out
/std::err
and makes information-extraction very complicated.
[ XY%] Building C object CMakeFiles/paho-lib.dir/app/3rd-party-libs/....c.o cc1: warning: command line option '-std=c++11' is valid for C++/ObjC++ but not for C
from kuksa.apps.
@argerus The former comment changing the way compile options are set can also make the warnings go away, when building the kuksa-cloud-dashboard
from kuksa.apps.
Update:
No warnings on amd64 (GCC 7.4.0 and 6.4) and and ARM64 (gcc 6.4.0), only arm32v6 (gcc6.4) produces warnings
In file included from /app/kuksa-cloud-dashboard/../3rd-party-libs/jsoncons/json.hpp:24:0,
from /app/kuksa-cloud-dashboard/src/main.cpp:22:
/app/kuksa-cloud-dashboard/../3rd-party-libs/jsoncons/json_structures.hpp: In member function 'typename std::enable_if<jsoncons::is_stateless<A>::value, void>::type jsoncons::json_object<KeyT, Json, false>::set_(typename jsoncons::Json_object_<KeyT, Json>::key_storage_type&&, T&&) [with T = int&; A = std::allocator<char>; KeyT = std::__cxx11::basic_string<char>; Json = jsoncons::basic_json<char, jsoncons::sorted_policy, std::allocator<char> >]':
/app/kuksa-cloud-dashboard/../3rd-party-libs/jsoncons/json_structures.hpp:1055:118: note: parameter passing for argument of type '__gnu_cxx::__normal_iterator<jsoncons::key_value_pair<std::__cxx11::basic_string<char>, jsoncons::basic_json<char, jsoncons::sorted_policy, std::allocator<char> > >*, std::vector<jsoncons::key_value_pair<std::__cxx11::basic_string<char>, jsoncons::basic_json<char, jsoncons::sorted_policy, std::allocator<char> > >, std::allocator<jsoncons::key_value_pair<std::__cxx11::basic_string<char>, jsoncons::basic_json<char, jsoncons::sorted_policy, std::allocator<char> > > > > >' will change in GCC 7.1
[](const value_type& a, const string_view_type& k){return a.key().compare(k) < 0;});
^
/app/kuksa-cloud-dashboard/../3rd-party-libs/jsoncons/json_structures.hpp: In member function 'typename std::enable_if<jsoncons::is_stateless<A>::value, void>::type jsoncons::json_object<KeyT, Json, false>::set_(typename jsoncons::Json_object_<KeyT, Json>::key_storage_type&&, T&&) [with T = int; A = std::allocator<char>; KeyT = std::__cxx11::basic_string<char>; Json = jsoncons::basic_json<char, jsoncons::sorted_policy, std::allocator<char> >]':
/app/kuksa-cloud-dashboard/../3rd-party-libs/jsoncons/json_structures.hpp:1055:118: note: parameter passing for argument of type '__gnu_cxx::__normal_iterator<jsoncons::key_value_pair<std::__cxx11::basic_string<char>, jsoncons::basic_json<char, jsoncons::sorted_policy, std::allocator<char> > >*, std::vector<jsoncons::key_value_pair<std::__cxx11::basic_string<char>, jsoncons::basic_json<char, jsoncons::sorted_policy, std::allocator<char> > >, std::allocator<jsoncons::key_value_pair<std::__cxx11::basic_string<char>, jsoncons::basic_json<char, jsoncons::sorted_policy, std::allocator<char> > > > > >' will change in GCC 7.1
[](const value_type& a, const string_view_type& k){return a.key().compare(k) < 0;});
It is from the included 3rd party lib. Do we even want to fix that?
from kuksa.apps.
Ok, it seems more of a compiler fix. So I vote won't fix:
https://stackoverflow.com/questions/48149323/what-does-the-the-gcc-warning-project-parameter-passing-for-x-changed-in-gcc-7
We are not linking to dynamic libs (the json stuff is header-only lib), so there should be no problem.
Warning could be disabled
https://stackoverflow.com/questions/52020305/what-exactly-does-gccs-wpsabi-option-do-what-are-the-implications-of-supressi
(tested, works)
But that is only cosemtic, so I rather keep it, as there might be situations where it is more important
from kuksa.apps.
Related Issues (20)
- Dashboard - weird build behaviour HOT 1
- Deprecated functions in App-Publisher HOT 4
- App-Publisher ignores newapp-Flag HOT 4
- APP-Publisher does not conform to our Docker-standards HOT 3
- APP-Publisher borked naming-convention HOT 4
- App-Publisher never re-publishes HOT 9
- APP-Publisher uses wrong protocol (http instead of https) HOT 1
- App-Publisher hard-coded architecture errors HOT 2
- Apps hard-coded App-store / HawkBit IP error HOT 2
- Cloud-mechanic incompatible with newer GCC HOT 4
- Traccar Docker last layer corruption
- [App-Store] Validate if app name is ok before category is created
- Error building docker image kuksa-cloud-dashboard
- Incompatibility with Boost version 1.71
- Discussion on archiving kuksa.apps repo HOT 2
- Get rid of 3rd-party-lib folder
- Network settings HOT 1
- Mixed APP-Instructions
- Building Cloud-mechanic fails HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from kuksa.apps.