User forums > Using Code::Blocks

Search path in custom makefile when cross-compiling

(1/2) > >>

Mazze:
I want to cross-compile with a custom makefile.

I have the lines
CC=i386-aros-gcc
LD=i386-aros-gcc
in the makefile.

This fails because c::b ignores the Linux search path. Compiling works when I write the full path in the CC variable.
But I don't want to have a path which is only valid on my machine in the makefile.

So how can I tell c::b about the path of the required tools?

stahta01:
Does it work right when using the make command (outside of Code::Blocks)?
If not, fix it for make then try again with Code::Blocks.

Edit: Try doing full compiler logging and see if that gives info. Not sure how it works with custom makefile.
http://wiki.codeblocks.org/index.php?title=FAQ#Q:_How_do_I_troubleshoot_an_compiler_problem.3F

Tim S.

Mazze:
Thanks. It's working now. I defined a cross-compiler like explained here:
http://wiki.codeblocks.org/index.php?title=Code::Blocks_and_Cross_Compilers

Although I'm using a custom makefile c::b is using the path from the cross-compiler setup.

Mazze:
Stop. I drew wrong conclusions.

What made it working was starting c::b from the console instead of Gnome menu.

Jenna:
That means gnome does not pass your environment to C::B, most likely the (some) startup-scripts are only used in login-shells.

So no C::B issue, but a gnome (configuration?) problem.

Navigation

[0] Message Index

[#] Next page

Go to full version