I want to launch other executable from my cpp code. I am aware that system() call may do this , But, problem is that , I want my cpp code to capture the standard hat "called" program is writing to stdout.
I've been requested to modify a perl backup script we use which mounts a networked NAS machine. The actual mount command is called inside a system() command. In testing, I can do a test of the return value, so I'm able to tell whether or not I've mounted properly, but I can't make heads or tails out of the return on deliberate errors. (Such as mounting a non-existent box.) I'm displaying the returned value, which is 256 in my tests. The man page for mount listed error messages with values from 1 to 64, but no higher. Am I drawing this error value from the system command somehow? And what would be the best way to determine what this error means?
I am working on a custom hand-held device which runs a variant of Ubuntu Linux, 2.6.18. I have a set of 4 binary files (for oprofile) which have been known to run in this environment, but when I copy them to /usr/bin, I can't run them: I get this message;root@ldogberry:/usr/bin# ./ophelp-sh: ./ophelp: not foundThis happens when I specify the full path, when I run from the /usr/bin directory -- it happens no matter what. Bash even does command-line completion on the file -- and then turns around and instantly claims the file is not found.
Just trying to set up a new backup using tar, but there are a few things I dont want to include. Using --exclude I can exclude sub-directories, but how do I exclude specific files in a subdirectory that are (for instance) executables or have a specific extension?
How do I find paths on ubuntu. I have installed redcar(ide written in ruby similar to textmate) and rvm for ruby. However I cannot locate where the executables are to update my .bashrc.
In practice I have a script that call a java program that call a linux system command. The script if I run it, from a shell functions well,so it is not a java problem. The problem come out when i put this script in a crontab schedulation. The result in this case is that java do not execute the system command. I think it depends on crontab
When I mistype a name of an executable program in terminal, ubuntu tries to search for similar programs in packages and then suggests names. This takes time, slowing down work and entirely useless for me. How to turn this feature off?
I personally can't even find a reason for implementing this feature and rather making it turned on by default. If someone needs a tool, he/she can search through packages.
I have a 'bin' directory in my home that contains executables. For example: scandirs.sh.It's in my PATH, so I can just type 'scan{tab}{tab} to run it. But 'which scandirs.sh' returns nothing.
I have been trying to get Wine to work in Fedora and have had nothing but problems. First of all, I can't open executables in the GUI. If I try, I get a message that says, "The program start.exe has encountered a serious problem and needs to close."
I can open .exe's in the terminal, but when I tried to install iTunes it wasn't able to complete the installation. I got an error message from SELinux that said something about a memory error, and then it asked me if I wanted to turn off some sort of memory management setting. I said yes and it asked me for my password, which I gave, and then it said "unable to grant access". It no longer gives me this error message (that's why I can't recall what it said verbatim), and instead just hangs at the point where I got the error message before. I've tried using Wine in Ubuntu before and could never get anything working in a half-decent way, so this isn't a big surprise.
I'm wondering why in order to run executables after compilation i have to type >"./executableName" I want it to type it just like >"executableName" (with no "./")
I don't know if this matters but I'm using tcsh for my shell...
I just installed the xubuntu-desktop package on my netbook (running UNR), and I've got one major complaint about xfce.
I can't right-click on icons in the Applications menu and add them to the launcher!Instead I have to know the location of the executable for the application, so that I can right-click the panel, add a launcher, and then type the location of the executable in and manually select an icon for it...Of course it probably wouldn't be a pain if I could find everything. In Windows, if I want to know the location of a program that's running, I just open Task Manager, right-click the application, and select Properties.
Is there some equivalent or command-line way of finding the location of a running application in Linux?
A few I'd like to know the location of are: 1) Gnome System Monitor 2) Terminal 3) Swiftfox ... and I'll probably think of others.
Even though I'm using XFCE, I figured this fell under the "all variants" category since my main question is just how to find the locations of executables...
I want to install an executeable and I am not sure how to do this. My intuition was to copy the executeable in the /usr/bin folder, but when I call it now, it says permission denied (and obviously I don't want to call the program with sudo every time).
I have C/C++ source codes and the corresponding binaries in proj/src and proj/bin.I have `import`ed both directories into my svn project and then `checkout`ed both. Later I made changes to the source code and hence new executables, but I'm not able to `checkin` the executables back to the svn project.`svn status` ignores the executables in the proj/bin directory. What should I do to `checkin` executables?
(cross-posted in LQ>Forums>Linux>Software)I have Subversion 1.6.6 on Linux.I have C/C++ source codes and the corresponding binaries in proj/src and proj/bin.I have `import`ed both directories into my svn project and then `checkout`ed both. Later I made changes to the source code and hence new executables, but I'm not able to `checkin` the executables back to the svn project.`svn status` ignores the executables in the proj/bin directory. What should I do to `checkin` executables?
I was trying to compile xbmc today, and got the error about the c compiler not being able to create executables. I did a search on the forum, and found something from 2004.None of the suggestions there worked for me. I can compile libraries, because I did a few for dependencies. The last thing I compiled with an executable was BloodFrontier, and it works perfectly.
earlier this morning, i compiled Qtcurve with no issues. but now, when i try to compile Avant Window Navigator, i get a strange error. everything begins to compile, it checks dependencies, begins compiling, and then i get this error:
Code: checking for C compiler default output file name... configure: error: C compiler cannot create executables
i want to know how to call the other file in linux. example i got this code that store into example1.sh and i want to store the data into other file like example2.
After getting 11.4 up and running, I wanted to install some of the programmes I use.when ever I click on the executable file it tries to down load the thunderball game, and when i try Code:./setup it denies permission even as su.this happens on two different applications i am trying to install. (only two i have tried)
Have installed Wine - version 1.2.3-Oubuntu1-ppa2-maverick1(wine1.2) from the Ubuntu softwear center . Downloaded windows executable PAF5EnglishSetup.exe which is a Genealogy softwear program from a trusted source (familysearch.org) .
However , when i attempt to open with Wine Windows Program Loader i get the pop up window saying the file is not marked as executable then reference to "executable bit" . I then see the following:
"You should only mark a file as executable via the file permissions if you know what you are doing." I do not know what i am doing . Therefore , reluctant to go messing with something i am not familiar with but i really need this softwear installed .
what is what is signal 0 in linux system call ?i can't find that in kill -l signal list . i need to know what is signal 0 . * for examples signal 1 is SIGHUP and signal 2 is SIGINIT . what is signal 0 ?
I am writing a shell script lets say run.sh and i want to call another script lets say test.sh having permissions " root:sys" whereas the permissions for run.sh are "rootther".Problem is that i cannot change the permissions of either of them. run.sh is performing some other important functions as well and test.sh is a system script and i am not supposed to change that.If i do not change the permissions, run.sh simply skips the part where it is suppose to call test.sh.Can anyone tell me how do i call test.sh in run.sh without changing permissions of any of them.
I had an interview , where the interviewer asked me the question "How to create and call a process in unix". I answered that we can use the command FORK()/ CLONE() to create a process. But I didn't have the answer for the second question, how to call a process.
When I an in Emacs, I want to call info pages like in terminal. E.g., info date will call the date info page, but when I in Emacs, I can only use M-x info call the complete info pages, but I only want to see the date info page. Then which command I should execute in emacs.