mohitnegi

error in systemc.h 118:16 error std::gets is not declared using std::gets

8 posts in this topic

hi ,

I have updated my gcc compiler to 4.9 version . now when I compile my system C model

with g++14 compiler option enabled ,it is giving this error in systemC header file

systemc.h 118:16 error std::gets is not declared using std::gets

 

I was not getting this error earlier . I tried building my systemC library with ./configure CXX=g++-4.9

but the same issue comes up ..

can anyone help in this ??

Share this post


Link to post
Share on other sites

std::fgets was deprecated AFAIR. You can comment this line actually at the moment. An official fix will be probably available with the next release.

Share this post


Link to post
Share on other sites

hi Stephan/Alan,

 

so guys any work around for using c++14 with systemC without " error std::gets is not declared using std::gets" .

 

Thanks

Share this post


Link to post
Share on other sites

FYI,  I had errors when running "gmake check" as part of my build/install of systemc-2.3.1a.  I modified './src/systemc.h' line 120 from "using std::gets" to "using std::fgets".  The "gmake check" did complete execution after I made this change.  Although other warnings were thrown.  I am using gcc 4.8.5 that has g++ version 6.2.1 20160826  (openSUSE Leap 42.2 x86_64).

Share this post


Link to post
Share on other sites

@daveW you can tryout the SystemC 2.3.2 draft release which fixes most of the issues while building under C++11/C++14 compilers.

Have a look here:

Regards,

Ameya Vikram Singh

maehne likes this

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now