Code::Blocks Forums

User forums => Help => Topic started by: PinkWolfFenrir on December 20, 2017, 10:08:27 pm

Title: C::B won't compile anything.
Post by: PinkWolfFenrir on December 20, 2017, 10:08:27 pm
I am running Code::Blocks version 13.12 on Mint 18.3. The compiler I use is gcc
version is either 5.4 or 6.0, for some reason both of them are in usr/lib/gcc/x86_64-linux-gnu

When I run the code (just a simple printf), it doesn't start an .exe, from a users standpoint, it does nothing.

Build log:
gcc -Wall  -c /home/alan/programiranje/bla.c -o /home/alan/programiranje/bla.o
g++  -o /home/alan/programiranje/bla /home/alan/programiranje/bla.o   
Process terminated with status 0 (0 minute(s), 0 second(s))
0 error(s), 0 warning(s) (0 minute(s), 0 second(s))
 
Checking for existence: /home/alan/programiranje/bla
Executing: xterm -T '/home/alan/programiranje/bla' -e /usr/bin/cb_console_runner "/home/alan/programiranje/bla" (in /home/alan/programiranje)
Process terminated with status -1 (0 minute(s), 0 second(s))
 

I tried installing gcc again and then restarting c::b, but no joy.
Settings>Compiler>Toolchain executables screenshot is in the attachments.

Title: Re: C::B won't compile anything.
Post by: oBFusCATed on December 20, 2017, 10:23:05 pm
Do you have xterm installed?
You can change the terminal used in the settings -> environment -> general -> terminal
Title: Re: C::B won't compile anything.
Post by: PinkWolfFenrir on December 21, 2017, 06:06:15 pm
Terminal to launch console programs: xterm -T $TITLE -e


Where do I check to see if I have xterm installed?
Title: Re: C::B won't compile anything.
Post by: stahta01 on December 21, 2017, 06:49:44 pm
Where do I check to see if I have xterm installed?

Inside the Linux package manger.

Tim S.
Title: Re: C::B won't compile anything.
Post by: PinkWolfFenrir on December 21, 2017, 07:53:22 pm
I installed xterm, and now it works! Thanks both of you!  But is there any way to use c::b without xterm, only using the standard Linux terminal. I'm not that familiar with xterm, but from what I understand it's just a terminal isn't it?
Title: Re: C::B won't compile anything.
Post by: stahta01 on December 21, 2017, 08:12:25 pm
I installed xterm, and now it works! Thanks both of you!  But is there any way to use c::b without xterm, only using the standard Linux terminal. I'm not that familiar with xterm, but from what I understand it's just a terminal isn't it?

Yes, but, you have to change the setting in CB to use that terminal.
Note: That means you need to know what parameters to use in the CB Settings.

NOTE: I am not sure there really is a standard Linux terminal; each Linux distro seems to have a different terminal as default.

I tend to change mine to
Code
mate-terminal -t $TITLE -x
But, I use a Debian [distro] with the Mate Desktop

Tim S.
 
Title: Re: C::B won't compile anything.
Post by: PinkWolfFenrir on December 22, 2017, 07:55:47 pm
Yeah I misexpressed myself when I said standard Linux terminal, basically what I meant was the terminal the OS came pre-installed with. I didn't know what terminal that actually is because the "label" (file name) just says "Terminal". I checked and it's the gnome terminal. I now selected it in Settings and it works fine, again thank you so much for the help.
Title: Re: C::B won't compile anything.
Post by: oBFusCATed on December 22, 2017, 08:44:56 pm
It seems there is x-terminal-emulator that is a wrapper for the terminal. I'll research if it is possible to use this thing as a default, because this is a common and recurring problem...