From: Jeff King <peff@peff.net>
To: Jakub Narebski <jnareb@gmail.com>
Cc: Rafael Gieschke <rafael@gieschke.de>,
Junio C Hamano <gitster@pobox.com>,
git@vger.kernel.org
Subject: Re: Cross-compiling git (was: [PATCHv2] add Android support)
Date: Mon, 23 May 2011 10:30:40 -0400 [thread overview]
Message-ID: <20110523143040.GB17743@sigill.intra.peff.net> (raw)
In-Reply-To: <m3k4dhzynr.fsf_-_@localhost.localdomain>
On Mon, May 23, 2011 at 12:04:44AM -0700, Jakub Narebski wrote:
> > So I think we are probably stuck either with the user setting an ANDROID
> > meta-flag that sets the other flags appropriately, or leaving it up to
> > the user to provide a sane config.mak.
>
> By the way, how well Git supports cross-compiling (which from the
> thread is necessity to generate binaries for Android)? `uname -a`
> trick works only when compiling on same machine.
It should work fine if you set the make variables appropriately for the
target platform. But I've never tried it. Didn't msysgit people
cross-compile for a while (or maybe still do)?
> ./configure supports --host and --build options, but I don't know if
> it pass them down to make somehow. ANDROID=YesPlease seems wasteful:
> what about setting HOST or MACHINE, or even uname_* variables, or just
> using Autoconf's `host` (in the form of CPU-VENDOR-OS)?
I know very little about autoconf internals, but what would
CPU-VENDOR-OS look like? Your CPU is probably some arm variant, though
it will vary from device to device. Your kernel is Linux. The special
steps in this case are about some weird userspace issues. So the
equivalent would be more like finding a Linux distro that ships a crappy
libc. I guess that is what the "vendor" slot is for?
But even if you somehow tell autoconf or the Makefile "yes, this is
android", you are still going to need to manually specify the set of
knobs that should be tweaked in that case. Whether you call it
"ANDROID=YesPlease" or some other form.
-Peff
next prev parent reply other threads:[~2011-05-23 14:30 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-05-16 23:23 [PATCHv2] add Android support Rafael Gieschke
2011-05-19 6:18 ` Junio C Hamano
2011-05-19 11:37 ` Rafael Gieschke
2011-05-19 12:20 ` Jeff King
2011-05-19 17:30 ` Rafael Gieschke
2011-05-19 17:38 ` Jeff King
2011-05-19 19:27 ` Rafael Gieschke
2011-05-23 7:04 ` Cross-compiling git (was: [PATCHv2] add Android support) Jakub Narebski
2011-05-23 14:30 ` Jeff King [this message]
2011-05-25 14:20 ` Jakub Narebski
2011-05-25 15:06 ` Jeff King
2011-05-19 14:17 ` [PATCHv2] add Android support Junio C Hamano
2011-05-23 8:01 ` Tor Arntsen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20110523143040.GB17743@sigill.intra.peff.net \
--to=peff@peff.net \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=jnareb@gmail.com \
--cc=rafael@gieschke.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).