sumit_tuwien Posted May 27, 2018 Report Share Posted May 27, 2018 I am trying to use latest systemc library in combination with c++17. For earlier version of systemc, I had no issue to use -std=c++17 switch. I see in the INSTALL of current release, it is written in the section 5. * SC_CPLUSPLUS - Override automatically detected C++ standard support This setting allows downgrading the assumed version of the underlying C++ standard on the current platform. By default, the latest supported version is chosen. Supported values are * SC_CPLUSPLUS=199701L (C++03, ISO/IEC 14882:1998, 14882:2003) * SC_CPLUSPLUS=201103L (C++11, ISO/IEC 14882:2011) * SC_CPLUSPLUS=201402L (C++14, ISO/IEC 14882:2014) * SC_CPLUSPLUS=201703L (C++17, N4659: Working Draft, Standard for Programming Language C++) But when I tried to compile the library using -std=c++17 switch (I forced it manually by editing CMakeLists.txt) and then use it in the user code with the same switch, I got a linker error for an sc_api_version. Even if I compile the library without standard spec [By default it should be c++ 98] and use it in user code compiled with switch -std=c++17, I get the link error related to API. With the previous version, I was still able to use c++17 and now this is very different. I would like to know if I can compile systemc-2.3.2 with -std=c++17 switch and what is I am missing Regards, Sumit P.S: I am using clang at this point of time. Quote Link to comment Share on other sites More sharing options...
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.