Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build error on MSYS2: 'atoi' is not a member of 'std' #10

Open
myd7349 opened this issue Jun 26, 2016 · 3 comments
Open

Build error on MSYS2: 'atoi' is not a member of 'std' #10

myd7349 opened this issue Jun 26, 2016 · 3 comments

Comments

@myd7349
Copy link

myd7349 commented Jun 26, 2016

It seems that the using directive at the beginning of src/conv/emf2svg.cpp causes this error.

using namespace std;
@kakwa
Copy link
Owner

kakwa commented Jun 27, 2016

Could you give more information about the environment in which you want to use libemf2svg?

Like the OS, the compiler used, which version of libc?

@myd7349
Copy link
Author

myd7349 commented Jun 28, 2016

@kakwa My environment: MSYS2

$ gcc -v
Using builtin specs。
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/lib/gcc/i686-pc-msys/4.9.2/lto-wrapper.exe
Target:i686-pc-msys
Configuration:/msys_scripts/gcc/src/gcc-4.9.2/configure --build=i686-pc-msys --prefix=/usr --libexecdir=/usr/lib --enable-bootstrap --enable-shared --enable-shared-libgcc --enable-static --enable-version-specific-runtime-libs --with-arch=i686 --disable-multilib --disable-sjlj-exceptions --with-tune=generic --enable-__cxa_atexit --with-dwarf2 --enable-languages=c,c++,fortran,lto --enable-graphite --enable-threads=posix --enable-libatomic --enable-libgomp --disable-libitm --enable-libquadmath --enable-libquadmath-support --enable-libssp --disable-win32-registry --disable-symvers --with-gnu-ld --with-gnu-as --disable-isl-version-check --enable-checking=release --without-libiconv-prefix --without-libintl-prefix --with-system-zlib
Thread:posix
gcc version 4.9.2 (GCC)

@simevo
Copy link

simevo commented Jun 27, 2019

atoi is in stdlib.h, does adding

#include <cstdlib>

at line 26 fix it ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Development

No branches or pull requests

3 participants