[haiku-development] Re: Cross-compiling Haiku with jam: how to make clean?

  • From: "Thomas Mueller" <mueller6723@xxxxxxx>
  • To: haiku-development@xxxxxxxxxxxxx
  • Date: Fri, 11 Aug 2017 20:23:34 +0000


from Adrien Destugues:

11 août 2017 15:12 "Thomas Mueller" <mueller6723@xxxxxxx> a Ã©crit:

When cross-compiling Haiku from FreeBSD, after the cross-tools have been 
successfully built and I
run "jam -q @anyboot-image", how do I clean out for the next run?

With make, there is "make clean", "make distclean, etc, but how do I do 
that with jam?

I tried "jam clean", but that was no good.
 
jam clean does clean some things but not everything.
Usually the simplest way is to delete generated/objects, and possibly 
generated/downloads and generated/build_packages.

That was my thought, but didn't really think I would need to delete 
generated/downloads, considering the same files would be downloaded on the next 
run.

Also, how do I get the building process to stick to the proper gcc, instead 
of going to clang,
which screws up?

I have no experience with doing this, but my guess would be that you need to 
export CC and CXX environment variables pointing to the right compiler. You 
need to do this before running the configure script, as the same compiler
will also be used at configure time to compile the cross-tools.

I remember setting the PATH so the desired gcc would be at the head, but it 
might be necessary or at least helpful to export CC, didn't think I needed to 
export CXX, but now I intend to try that.  I guess that would be c++ or 
possibly g++, which appear to be the same file, hard-linked.  If I use 
/usr/bin/clang to build the cross-tools, then I surely need to export CC or it 
won't be found.  I did remember to put jam directory for Haiku at the head of 
the PATH.

I also want try to build for amd64: part of the reason why I need more than one 
"generated" directory.

Tom


Other related posts: