cross-compiling talloc with waf

tridge at tridge at
Tue Apr 13 17:15:44 MDT 2010

Thanks George!

Maybe we should have a new cross-compiling wiki page on It would be good to save instructions like these.

I'm also thinking about how to make it easy to cross-compile when you
don't have a cross-execute emulator available. I don't think the
traditional autoconf method is very good as it copes badly with
configure tests that need to execute on the target. Using an emulator
is of course ideal, but not everyone has one.

I'm thinking of adding the following two steps:

1) run
  waf configure --cross-compile --cross-answers-build=template.txt

  waf configure --cross-compile --cross-answers=myanswers.txt

the first step would build my template.txt, which would look like

  Checking simple C program       : UNKNOWN
  Checking for large file support : UNKNOWN
  Checking size of long long      : UNKNOWN

then you would copy template.txt to myanswers.txt, and change the
UNKNOWN values to the right answers.

  Checking simple C program       : OK
  Checking for large file support : OK
  Checking for WORDS_BIGENDIAN    : NO
  Checking size of long long      : 8

you would then run another configure using
--cross-answers=myanswers.txt and it would be ready to build.

Does that sound ok?

Cheers, Tridge

More information about the samba-technical mailing list