Author Topic: Codeblocks with avr-gcc os ubuntu linux  (Read 5419 times)

mgordon

  • Guest
Codeblocks with avr-gcc os ubuntu linux
« on: May 14, 2006, 02:59:31 am »
I am a high school science(robotics) teacher and I do AVR 8-bit embedded development using commercial tools. I would like to use codeblocks and avr-gcc to do same. Can anyone help me set up the IDE for this purpose. I've read the thread on using custom makefiles but I've been unsuccessful in implementing. I'm relatively new to linux and gcc so need some beginner type guidance.

Offline Michael

  • Lives here!
  • ****
  • Posts: 1608
Re: Codeblocks with avr-gcc os ubuntu linux
« Reply #1 on: May 14, 2006, 09:38:54 pm »
Hello,

It could be helpful if you post which thread you mean and the errors you get or your specific problems. Moreover, which C::B revision are you using?

Best wishes,
Michael

mg

  • Guest
Re: Codeblocks with avr-gcc os ubuntu linux
« Reply #2 on: May 15, 2006, 04:10:37 am »
I am using the may 9 build of the .deb distro on ubuntu. I've narrowed the problem that I'm having to a glitch in the settings menu. According to item 2.3 in the codeblocks FAQ, I navigated to settings-compiler and debugger-other, option where I should be able to select work with makefiles in the build method setting. When navigating to this location the item is greyed out(not available). I have set the project's Properties to use a makefile, and checked "This is a custommakefile." Am I missing something?

FAQ link:
http://wiki.codeblocks.org/index.php?title=FAQ#Q:_My_project_should_be_compiled_with_a_custom_makefile._Is_it_possible_with_Code::Blocks.3F

Offline killerbot

  • Administrator
  • Lives here!
  • *****
  • Posts: 5491
Re: Codeblocks with avr-gcc os ubuntu linux
« Reply #3 on: May 15, 2006, 07:38:40 am »
I am using the may 9 build of the .deb distro on ubuntu. I've narrowed the problem that I'm having to a glitch in the settings menu. According to item 2.3 in the codeblocks FAQ, I navigated to settings-compiler and debugger-other, option where I should be able to select work with makefiles in the build method setting. When navigating to this location the item is greyed out(not available). I have set the project's Properties to use a makefile, and checked "This is a custommakefile." Am I missing something?

FAQ link:
http://wiki.codeblocks.org/index.php?title=FAQ#Q:_My_project_should_be_compiled_with_a_custom_makefile._Is_it_possible_with_Code::Blocks.3F
I think the fact it is grayed out, it because it is not supported at the moment (custom make files), do a search in the forum. I am not 100% sure.

But you propably won't need makefiles, you can use CB project files. For your 'new' projects you can specify to us the avr compiler instead of (regular)gcc.
You just need to make CB aware of that avr-compiler. Since it is also a GCC variant, probably all the gcc switches/options might work.
Go to the "compiler and debugger" settings, make sure the GCC is selected, and press the copy button (we are creating a new compiler set), give it a name (eg : avr), then make sure this "avr" is selected and go to the "programs" tab, and change the "normal gcc" executables with your "avr" ones, do this by first setting your programs dir (the one containing the bin directory).
It is probably as simple as that ;-)