Hi
I have searched both the user and dev lists for hints on how to
cross-compile Apache 2, however with minor success. I am currently
trying to cross-compile for arm-linux and what I have done so far is to
modify the build scripts to get it to compile at all:
CC=arm-linux $APACHE_SRC_DIR/configure --host=arm-linux
--build=i686-pc-linux-gnu --srcdir $APACHE_SRC_DIR --prefix
$APACHE_DIST_DIR/$APACHE_PREFIX
* Test fails: set prgp (Set process group ID, ac_cv_func_setpgrp=no)
- Action: Overriden
* Somehow the test for size_t_fmt fails in /srclib/apr/configure.in
- Action: added a temporary hack in configure.in
# Basically, we have tried to figure out the correct format strings
# for APR types which vary between platforms, but we don't always get
# it right. If you find that we don't get it right for your platform,
# you can override our decision below.
case $host in
*linux*)
off_t_fmt='#define APR_OFF_T_FMT "ld"'
case $host in
s390*)
size_t_fmt='#define APR_SIZE_T_FMT "ld"'
;;
arm*)
dnl Temporary Hack
ssize_t_fmt='#define APR_SSIZE_T_FMT "ld"'
size_t_fmt='#define APR_SIZE_T_FMT "ld"'
off_t_fmt='#define APR_OFF_T_FMT "ld"'
;;
* IPPROTO_SCTP and SCTP_NODELAY are not set.
- Action: added temporary hack in configure.in
echo "${nl}Checking for IPv6 Networking support..."
dnl Start of checking for IPv6 support...
AC_ARG_ENABLE(ipv6,
[ --disable-ipv6 Disable IPv6 support in APR.],
[ if test "$enableval" = "no"; then
user_disabled_ipv6=1
fi ],
[ user_disabled_ipv6=0 ] )
case $host in
*apple-darwin*)
# It appears that Jaguar has all the right features, but
# getnameinfo() fails to find the hostname for a mapped
# address.
broken_ipv6=1
;;
*arm*-linux*)
# Temporary Hack
have_sctp="0"
;;
*)
broken_ipv6=0
esac
What I have run into now is that gen_uri_delims that is executed during
compile is actually compiled for arm-linux which makes the build fail.
My questions are:
1. Is Apache 2 prepared for cross-compiling or is there a lot of work
ahead?
2. The problems that I have encountered are they due to not enabling or
disabling features in the main configuration script.
3. Is there a way to get the gen_uri_delims to be compiled for the build
platform and is it correct to specify CC for autoconf2.5+ ? (see
http://www.gnu.org/manual/autoconf/html_node/autoconf_164.html#SEC164)
Thanks in advance,
David
--
David Tunkrans Net Insight AB
Box 42093, SE-126 14 STOCKHOLM, SWEDEN
Phone: +46-8-685 06 95 Visiting address: V�stberga All� 9
Fax: +46-8-685 04 20 http://www.netinsight.net