Compiling CPP Code errors

Source: Internet
Author: User
Error:
hdu_admin@hdu:~/neural_work/stf/cdl$ g++-o sdk_api.so-shared-fpic api.cpp in


file included from/usr/include/c++/ 5/chrono:35:0, from
                 api.cpp:7:
/usr/include/c++/5/bits/c++0x_warning.h:32:2: Error: #error the This file requires compiler and library support for the ISO C + + standard. This support must is enabled with the-std=c++11 or-std=gnu++11 compiler options.
 #error This file requires compiler and library support \
  ^
api.cpp:85:25:warning:multi-character character const Ant [-wmultichar]
         header.bftype = ' MB ';
                         ^
api.cpp:18:5: Error: ' uint16_t ' does not name a type
     uint16_t bftype;
Solve:

You can use g++-o sdk_api.so-shared-fpic api.cpp-std=c++11

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.