WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: request : gcc supports c++ 11 standard  (Read 1063 times)

Offline lovelypp

  • Jr. Member
  • **
  • Posts: 51
request : gcc supports c++ 11 standard
« on: September 29, 2020, 09:14:35 PM »
when port my app from other linux dist,  there are some lib requre c++11 support, like log4cplus, boost(version 1.72) qt ? and others

thanks
« Last Edit: September 29, 2020, 09:17:13 PM by lovelypp »

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 10916
Re: request : gcc supports c++ 11 standard
« Reply #1 on: September 29, 2020, 09:48:06 PM »
Hi lovelypp
Run this command:
Code: [Select]
tc@E310:~$ gcc -std=c++11 2>&1
gcc: fatal error: no input files
compilation terminated.
tc@E310:~$
That response means it supports c++11.

If the response includes:
Code: [Select]
gcc: error: unrecognized command line option '-std=c++11That means it does not support c++11

If it supports c++11, try adding this to CXXFLAGS:
Code: [Select]
-std=c++11

Offline lovelypp

  • Jr. Member
  • **
  • Posts: 51
Re: request : gcc supports c++ 11 standard
« Reply #2 on: September 29, 2020, 10:08:25 PM »
Rich
   sorry, I seems that it supports c++11,  I have made a mistake.

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 10916
Re: request : gcc supports c++ 11 standard
« Reply #3 on: September 29, 2020, 10:11:44 PM »
Hi lovelypp
That's OK. I make mistakes all the time. ;D

Offline lovelypp

  • Jr. Member
  • **
  • Posts: 51
Re: request : gcc supports c++ 11 standard
« Reply #4 on: September 29, 2020, 10:44:38 PM »
 :)