[asterisk-dev] Cross compiling zaptel

Kristian Kielhofner kristian.kielhofner at gmail.com
Tue Aug 21 13:16:11 CDT 2007


On 8/21/07, Tzafrir Cohen <tzafrir.cohen at xorcom.com> wrote:
> On Tue, Aug 21, 2007 at 12:51:45PM -0400, Kristian Kielhofner wrote:
> > Hello everyone,
> >
> >   I know that this has come up on the list before but I am trying to
> > figure out how to properly cross compile zaptel 1.4 (and asterisk,
> > soon).
> >
> >   I have attached the output of what I *think* should work (it
> > obviously doesn't).
> >
> >   I think Russell has stated in the past that menuselect is NOT
> > required to build zaptel or asterisk.  Which makefile targets should I
> > be calling to get around menuselect?  If I try to name a few specific
> > targets - "make modules programs", it fails with:
>
> menuselect itself cerainly is. An explicit 'menuselect' command is not
> required. If it is not not used, menuselect --fixdeps  will be used.

  That's good to know.  I guess those Makefile variables need to come
from somewhere!

> >
> > No rule to make target `pciradio.ko', needed by `install-modules'
>
> Everything regarding the makefile target has been well-documented in
> 1.4.5 and fixed slightly afterwards :-( . Try current 1.4.5 svn (or next
> zaptel version)

  1.4.5 is much better, see below.

> >
> > (as seen in zaptel-build.log)
> >
> >   In Zaptel 1.4.4 menuselect builds with the target CC (instead of
> > HOSTCC) and can't run (as seen in zaptel-build-notarget.log).  The
> > "command not found" error is because the menuselect binary is linked
> > against a different C library that does not exist on my host system.
>
> Should be fixed in 1.4.5 , as I mentioned.
>

Also fixed.  Thanks Tzafrir!

My latest snag (you might know something about this, too):

from xpp/utils/Makefile:

PERLLIBDIR      := $(shell eval `perl -V:sitelib`; echo "$$sitelib")

  My target doesn't have perl, so I don't expect to make this work.
However, the error here is obvious for a cross compile.  ATM, I am
just defining another variable in my AstLinux parent makefile and
creating the parent directories in my target filesystem before the
various install-* targets run.  I then remove them later (again, I
don't have perl anyways).

  It also appears that there is a typo in the main zaptel Makefile:

install-programs: install-utils install-libs install-inlcude

  Fails because "install-inlcude" should be "install-include":

--- zaptel-1.4.5/Makefile.orig  2007-08-21 14:12:20.000000000 -0400
+++ zaptel-1.4.5/Makefile       2007-08-21 14:12:29.000000000 -0400
@@ -446,7 +446,7 @@
        @echo "###"
        @echo "###################################################"

-install-programs: install-utils install-libs install-inlcude
+install-programs: install-utils install-libs install-include

 install-utils: utils install-xpp
        install -d $(DESTDIR)$(BIN_DIR)


  Thanks again for all of your help on this!  With this simple patch
and the perl workaround I mentioned before, I can now build and
install zaptel 1.4 in AstLinux.  I haven't tested it yet, but I will
shortly!

  On to Asterisk...

-- 
Kristian Kielhofner



More information about the asterisk-dev mailing list