Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.debian.user > #187858
| From | Evgeny <evgggd@gmail.com> |
|---|---|
| Newsgroups | linux.debian.user |
| Subject | g++ can't build "Hello World" programm |
| Date | 2017-10-13 15:20 +0200 |
| Message-ID | <uA82B-4hy-9@gated-at.bofh.it> (permalink) |
| Organization | linux.* mail to news gateway |
[Multipart message — attachments visible in raw view] - view raw
Dear all, i have some problems with <iostream>, <fstream> etc. libraries on
my debian.
I have pretty simple code:
#include <iostream>
using namespace std;
int main(void) {
cout << "Hello World!" << endl;
return 0;
}
And when i try to compile it, compiler gives me error:
evgeny@debian:~/Documents/Programming$ g++ test.cpp -o testIn file
included from /usr/include/c++/4.9/clocale:42:0,
from
/usr/include/x86_64-linux-gnu/c++/4.9/32/bits/c++locale.h:41,
from /usr/include/c++/4.9/bits/localefwd.h:40,
from /usr/include/c++/4.9/ios:41,
from /usr/include/c++/4.9/ostream:38,
from /usr/include/c++/4.9/iostream:39,
from test.cpp:1:/usr/include/locale.h:29:25: fatal
error: bits/locale.h: No such file or directory
#include <bits/locale.h>
^
compilation terminated.
I've installed libstdc++-developer, build-essentials, tried to use
-I/way-to-the-missing-lib, different architecture keys etc., but it doesn't
work as well.
Architecture info Linux debian 3.16.0-4-amd64 #1 SMP Debian
3.16.43-2+deb8u5 (2017-09-19) x86_64 GNU/Linux
OS Debian 8.9
g++ version g++ (Debian 4.9.2-10) 4.9.2
installed C++ packages list:
my problem that I simply can't compile Hello World programm with g++
#include <iostream>
using namespace std;
int main(void) {
cout << "Hello World!" << endl;
return 0;
}
Compiler gave me message:
evgeny@debian:~/Documents/Programming$ g++ test.cpp -o testIn file
included from /usr/include/c++/4.9/clocale:42:0,
from
/usr/include/x86_64-linux-gnu/c++/4.9/32/bits/c++locale.h:41,
from /usr/include/c++/4.9/bits/localefwd.h:40,
from /usr/include/c++/4.9/ios:41,
from /usr/include/c++/4.9/ostream:38,
from /usr/include/c++/4.9/iostream:39,
from test.cpp:1:/usr/include/locale.h:29:25: fatal
error: bits/locale.h: No such file or directory
#include <bits/locale.h>
^
compilation terminated.
I've installed libstdc++-developer, tried to use -I/way-to-the-missing-lib,
different architecture keys etc., but it doesn't work as well.
Architecture info Linux debian 3.16.0-4-amd64 #1 SMP Debian
3.16.43-2+deb8u5 (2017-09-19) x86_64 GNU/Linux
OS Debian 8.9
g++ version g++ (Debian 4.9.2-10) 4.9.2
installed packages list:
evgeny@debian:~$ dpkg --list | grep c++
ii lib32stdc++-4.9-dev 4.9.2-10
amd64 GNU Standard C++ Library v3 (development
files)
ii lib32stdc++6 4.9.2-10
amd64 GNU Standard C++ Library v3 (32 bit
Version)
ii libflac++6:amd64 1.3.0-3
amd64 Free Lossless Audio Codec - C++ runtime
library
ii libgpgme++2 4:4.14.2-2+deb8u2
amd64 c++ wrapper library for gpgme
ii libsigc++-2.0-0c2a:amd64 2.4.0-1
amd64 type-safe Signal Framework for C++ -
runtime
ii libstdc++-4.9-dev:amd64 4.9.2-10
amd64 GNU Standard C++ Library v3 (development
files)
ii libstdc++6:amd64 4.9.2-10
amd64 GNU Standard C++ Library v3
ii libx32stdc++-4.9-dev 4.9.2-10
amd64 GNU Standard C++ Library v3 (development
files)
ii libx32stdc++6 4.9.2-10
Any suggestions? Thank you in advance.
Back to linux.debian.user | Previous | Next — Next in thread | Find similar | Unroll thread
g++ can't build "Hello World" programm Evgeny <evgggd@gmail.com> - 2017-10-13 15:20 +0200
Re: g++ can't build "Hello World" programm <tomas@tuxteam.de> - 2017-10-13 15:30 +0200
Re: g++ can't build "Hello World" programm "Thomas Schmitt" <scdbackup@gmx.net> - 2017-10-13 16:50 +0200
Re: g++ can't build "Hello World" programm Evgeny <evgggd@gmail.com> - 2017-10-18 21:10 +0200
Re: g++ can't build "Hello World" programm Greg Wooledge <wooledg@eeg.ccf.org> - 2017-10-18 21:20 +0200
Re: g++ can't build "Hello World" programm <tomas@tuxteam.de> - 2017-10-18 21:30 +0200
Re: g++ can't build "Hello World" programm Evgeny <evgggd@gmail.com> - 2017-10-18 22:10 +0200
Re: g++ can't build "Hello World" programm tomas@tuxteam.de - 2017-10-18 22:40 +0200
Re: g++ can't build "Hello World" programm "Thomas Schmitt" <scdbackup@gmx.net> - 2017-10-18 22:10 +0200
csiph-web