Tag Info

New answers tagged


don_jones' answer seems to cover how the basic setup that will work. But it's not how it should be, there is a long development history for this. Why? I don't have much background on this, but these what I could think of: About default location or symlink /usr/include/dbus The system is prepared to have multiple versions of the same library which are not ...


you're using the wrong tool. GCC is to compile C code. you are making bash code which interpreted at runtime. all you need to do is give it executable permission. take a look at the man page for chmod man chmod and decide what permissions you want it to have. or just run chmod 711 [your file name]


Fabrice Bellard's TCC seems to be still in the repositories. It can run in a kind of interpreter-mode which makes the following possible: You can make a simple C-file executable like the OP tried to do by adding the line #!/usr/bin/tcc -run to the very top of the file. It also accepts input from STDIN by adding an empty option (just the minus sign -) at ...


You need to compile your program before you can run it. To do this, you'll need a C compiler, like gcc. You can install this with: sudo apt-get install gcc Then, to compile your program, creating an executable called file: gcc -Wall -o file file.c Which you should then be able to run: ./file


AFAIK, you have to compile C code before executing it like so: gcc file.c


sudo install helloworld /usr/local/bin installs it to /usr/local/bin (read man install).Btw, your helloworld.c should really be: #include <stdio.h> int main(void){ printf("Hello World"); return 0; }


Is there any easy way to install helloworld on to my computer? The next actions you need to do: make the file executable with chmod 775 helloworld from the directory where the file is. copy it over to a directory in your PATH. I would suggest sudo cp helloworld /usr/local/bin/ (local since it is your local system and bin since it is a binairy). And ...


Without root permission the best thing for you to do is create a bin directory within your home directory and then add it to your PATH environment variable. So after creating a directory called bin in /home/$USER open ~/.bashrc in your favourite editor, for example gedit ~/.bashrc. You then need to add: export PATH=$PATH:~/bin What this is doing is ...

Top 50 recent answers are included