C++ is a statically typed, free-form, multi-paradigm, compiled, general-purpose programming language.

learn more… | top users | synonyms

-1
votes
1answer
6 views

How can I run a c++ application on gnome-terminal directly from Eclipse instead of its console?

Trying here to set a c++ application to run on gnome-terminal instead of eclipse console from within eclipse itself. Already done it with Java, but with c++ the menus are different.
1
vote
0answers
33 views

how to create an icon button in X11?

I am using x11 library for creating a simple window application in Linux. I want to add an icon button (graphical button) to my app - something similar to this: Are there any instructions on how to ...
1
vote
1answer
62 views

How to install GCC 5 on debian jessie 8.1

I tried many solutions to install update for my gcc compiler on debian server. None of them worked. I need the compiler update to use new features of c++11, as this provides a stable libcxx11 ABI, and ...
0
votes
0answers
7 views

Boost ASIO async_write_some is really slow [migrated]

I finally found the bottleneck of my server and it turns out to be async_write and the same goes for async_write_some. Here the following benchmark code: struct timespec start, end; ...
-1
votes
3answers
26 views

Get compilate date [duplicate]

I am trying to extract the compilation date from a linux command (or cpp would be fine too). I am using: stat -c %z ./myProgram.bin However, if I copy myProgram.bin to an another place via ssh for ...
-1
votes
1answer
40 views

The LD_LIBRARY_PATH environment variable is not recognized by the target C# executable's runtime environment [closed]

I tested this C++ program on Ubuntu Linux 16.04 yesterday. What bothers me is the fact that the following program starts a mono-service programmatically which I see in the Ubuntu 16.04 ...
-1
votes
1answer
38 views

How to pipe a cat output to stdin? [closed]

C++ -------> g++ -------> bash : #include <cstdlib> using namespace std; int main(){ system("mail -s test_mail xxxx@testdomain.com"); system("test msg"); system("."); return ...
1
vote
1answer
74 views

Compilation error on fedora 14

I installed fedora version 14 using virtual box but when I try to compile a program then displayed command not found. After that I tried to install g++ compiler using commands but, the way I followed ...
0
votes
0answers
9 views

Converting c++ to bash, need to know if a specific variable has bash significance [migrated]

I am converting a c++ code to bash for several reasons, one being that I only know bash aside from what I've been learning while doing this conversion! There's a variable (let's call it "size") that ...
6
votes
2answers
38k views

How to install g++ 4.7.2 & c++11 on CentOS 5.x?

I'm trying to install the latest stable g++ and c++11. My host did it through yum install and thought that it was the latest, but it's not, and they are now saying that this is beyond their level of ...
0
votes
2answers
273 views

How to install latest stable release of GCC in Linux Mint?

I want to install the latest version of GCC (GNU compiler collection) in Linux Mint 17.3. Currently g++ --version returns 4.8.4, whereas the latest stable release is 5.3.
0
votes
1answer
95 views

How to fix the Ubuntu Linux 15.10 Files GUI manager , Nautilus , flickers on and off

I recently installed Ubuntu Linux 15.10 on a Lenovo desktop.After a mysterious crash last night while testing point and click of an Mono-.NET 4.5 C# executable which DLLImport's an C++ shared object, ...
0
votes
1answer
144 views

how to define the top dir in automake system?

I usually use a typical steps to generate the makefile, and firstly I use the "build.sh init" to generate the configure file, and then I use "configure" to generate the makefile with makefile.am file. ...
0
votes
2answers
87 views

How may an managed C# executable step into an Unmanaged C++ shared object's code using the Monodevelop debugger on a Ubuntu Linux 15.10 platform?

We would like to know how a managed C# executable running in the mono environment can step into an unmanaged C++ shared object's code using the Monodevelop debugger on a Ubuntu Linux 15.10 platform. ...
0
votes
0answers
38 views

Why does a Ubuntu Linux Mono-.NET 4.5 C# Program GP Fault upon loading and running a Shared Object?

On my Ubuntu Linux 15.10 Lenovo desktop computer, I wrote a Mono-.NET 4.5 C# program with a BuildIPCameraListLinux.config file which uses DLLImport to load libxmlconverter.so. Only upon point and ...
1
vote
0answers
91 views

error while compiling my first program in C language? [closed]

I am a newer user of Ubuntu I used to compile c file via Code Block in Win OS. But now I've created a simple program (hello ,world!). This is the code #include<stdio.h> /* demo.c: My first C ...
0
votes
1answer
67 views

how to change the Output Directory in a LINUX makefile so that a shared object can be relatively specified in C# DLLImport?

I would like to find out how to change the Output Directory in a LINUX makefile so that a shared object can be relatively specified in C# DLLImport? I read the following hint in ...
3
votes
1answer
175 views

how to read variables in bash and pass these variables to a c++ program as arguments

I am trying to read a few vars in my bash script and pass these to a C++ program which will accept these variables as arguments. any help please? I got this far..but it does not work... echo -n ...
0
votes
1answer
35 views

openSSL Key and Certificate

As far I know, in an authenticated SSL connection, both the client and server have private keys and provide their certificates (with the corresponding public keys) across the connection before ...
0
votes
1answer
26 views

Why is echo not working for mt valgrind command?

So I have my makefile working great, except that It doesn't create the valgrind.out file and I don't know why. So the console succesfully prints out that my executable file line is created but not ...
0
votes
1answer
47 views

Execute a init script from C++ program

I have a script in my /etc/init.d/ which executes an application. I am able to start,stop and get status of the service from terminal. Now I would like to start the same service from my C++ program. ...
1
vote
2answers
188 views

How to replace GnuPG stable with GnuPG modern?

First I would like to state that I'm an absolute beginner in the Linux environment. For decades I only used Windows. Since a week or two I'm now using Debian for developing a C++ application with ...
2
votes
1answer
145 views

Compiler for 32-bit LSB MIPS MIPS32 architecture

I have a TV set top box that i'm currently experimenting on: I established a serial console connection to it through a serial port located on the board. I am trying to compile a simple C executable ...
1
vote
0answers
26 views

my gsm modem echo my command on mini2440

I have mini2440 and GSM modem that they connected to each other with USB serial port (ttyUSB0). this is my code in c++ to send AT: #include <QCoreApplication> #include <stdio.h> /* ...
1
vote
2answers
22 views

Is there a way to get directory part from variable in make?

I have makefile, where I define some lib and its path: MY_LIB= dir/lib Now I know that I can use @D to get directory part from target: #This will go to dir $(MY_LIB): cd $(@D) But I want to ...
0
votes
0answers
19 views

Reload all text of glade interface (Gtk::Builder) when change language in gtkmm

I use gtkmm, glade (Gtk::Builder) and gettext. When users select other language in the program, I have to restart the process to reload all interfaces. Is there any way to reload text of glade ...
0
votes
0answers
75 views

program “killed” as soon as it runs

Ubuntu 12.04 I have success with make, and output a program name algo. When I type ./algo,the terminal just directly shows 'killed' And I searched the var/log/message or syslog kern.log. I don't ...
0
votes
0answers
44 views

custom runtime environment - libpthread segmentation fault

I have built a project using gcc 4.9.2 (libstdc++.so.6.0.20). When I want to run that program on the virtual machine which is equipped with gcc 4.6.3 (libstdc++.so.6.0.16) I have to deliver ...
1
vote
0answers
421 views

Geany feature or plugin to show members of a class

Im using ubuntu 12.04. For c++, is there a functionality (or plugins that will provide this) in Geany which enables suggestion/hint list of all members of a class, also classes from a linked library? ...
1
vote
2answers
52 views

How to create 32bit chroot system that is just a mirror of my current system for compiling purposes?

After lot of googling and posting and crying over obscure GCC linker error messages I concluded that the only way to reliably build something in foreign CPU architecture is to set up a chroot ...
1
vote
0answers
162 views

Error building and compiling GCC 5.2.0 from scratch on Vortex86DX

In order to upgrade a VortexDX86 custom linux with a gcc 3.2.3 compiler, I´m trying to built the GCC 5.2.0 compiler to support the latest C++ 11 standard. I have downloaded its source code from ...
0
votes
0answers
56 views

dlopen causes segfault when running in gdb

My project loads a libray (compiled in debug mode) dynamically within the main thread with dlopen and then uses dlsym without problem. However, when running in debug mode with gdb 7.7.1+dfsg-5, it ...
0
votes
0answers
28 views

how to covert character within each column as sub-column without duplication

I have a data.frame file like this: 1 200 444 444 2 310 NA 444 3 310 NA 444 4 NA 444 444 5 200 444 444 6 200 NA 444 7 310 444 444 8 310 876 444 9 310 876 444 10 NA 876 444 I want to convert ...
-1
votes
1answer
248 views

Forwarding return value of shell script to C/C++ [closed]

I tried to find possible solution on Google, but all I found is explanation on how to return value, but not how to accept it in some programming language, in my case C/C++? Does anybody have idea on ...
-1
votes
1answer
267 views

Communicating derived C++ types through a named pipe impossible? [closed]

I found that communicating a derived C++ type such as an opencv Mat or other derived types do go through the pipe if I send the derived type as a reference through a pipe: //Measurement FIFO ...
0
votes
1answer
46 views

CentOS and a small boost example

I ask this question here, because I think, it has more to do with linux than with boost itself. So i created a small cpp file: #include <boost/math/special_functions/round.hpp> #include ...
0
votes
0answers
83 views

Error building nodejs from source on Debian

I keep getting the same error when running make on nodejs source code. I've looked and some common problems seem to be lack of a c compilier or install g++. I have these and have double checked. Here ...
1
vote
3answers
862 views

Running a C++ compiled program in the background and sending input whenever needed

I have a compiled program written in C++ for a UNIX environment which has this kind of structure: int main(){ ... LoadEngine() ... while(1){ std::cin >> buffer; ... ...
1
vote
0answers
680 views

Work on a remote project with Eclipse via SSH and SVN+SSH (2 remote Linux)

I have the following boxes: a) A Windows box with Eclipse CDT(or PTP) b) A Linux box,including Compiler, accessible for me only via SSH. c) A Linux box, including SVN Source, accessible for me only ...
-2
votes
2answers
570 views

Pipe Named Fifo [closed]

I am implementing a named pipe to write and read data between two processes in cpp. The first process acquires a feature point from an image in real time while the second reads this feature point. It ...
0
votes
0answers
55 views

Weird G++/AR Compilation issue

I'm working a patch-set to compile dpkg and APT onto Cygwin. I've almost got everything working, but I'm encountering some weird behavior with ar/g++ that I can't explain. APT's stock Makefile uses ...
1
vote
0answers
927 views

error while loading shared libraries: libboost_thread.so.1.54.0: cannot open shared object file: No such file or directory

I am trying to connect MongoDb with Qt c++. When I build it there is no error, just information like; :-1: warning: libboost_system.so.1.54.0, needed by /usr/local/lib/libboost_thread.so, may ...
0
votes
0answers
64 views

Trouble with Boost due to missing Makefile.cmake file?

I'm not very familiar with cmake and am afraid if I make one small wrong error, things will really screw up. I have a previous project(PrevProject) that I got to compile successfully using ...
2
votes
0answers
49 views

Which process wrote to which memory address? [closed]

Recently, I've been seeing a wide variety of memory-related crashes at work (C++ applications on Ubuntu 14.04). Our applications use a properietary third party library to interface with real time data ...
3
votes
0answers
182 views

Cannot use keyboard within Qt app without sudo

I have an embedded Qt application crosscompiled that runs on BeagleBone Black. It works Ok, but one thing- It doesnt accept keyboard input if i wont run in directly on BeagleBone Black preceeding with ...
0
votes
1answer
75 views

Build log4cxx [DEBIAN]

Please help me from where to start when building log4cxx package, do I need some other packages for bulding this? I can't find anything significant to help me to solve this problem. I tried with ...
2
votes
2answers
69 views

Releasing linux software - compatibility

I want to release a C++ library for Linux. Is it true that (when no other libs are dynamically linked) only the glibc version decides compatibility to other Linux distributions? Is there a better way ...
0
votes
1answer
127 views

gdb displays not all variables in KDevelop [closed]

Hoping, the image describes the issue much better than I can do. Generally, I'm debugging a multithreaded application in KDevelop with gdb. I'm debugging the app step by step (F11 shortcut) and have ...
1
vote
1answer
583 views

Using MPI with a .sh script?

I am a beginner with Unix and MPI. I have a runPR.sh script as below DIR=/directory/buildagain/bin/Project FILELIST=$1 while read FILE do echo "Processing ${FILE}..." ./makeInp.sh ...
3
votes
1answer
194 views

Io redirection vs file logging performance c/c++

Is there a performance difference from a latency point of view if we do a regular printf and redirect stdout to a file when running the program ( e.g., ./a.out > log.txt 2>&1 ) vs using fprintf ...