From: Enrico Weigelt <weigelt@metux.de>
To: caml-list@yquem.inria.fr
Subject: crosscompile problem
Date: Fri, 26 Aug 2005 14:00:42 +0200 [thread overview]
Message-ID: <20050826120042.GA9061@nibiru.local> (raw)
[-- Attachment #1: Type: text/plain, Size: 1637 bytes --]
Hi folks,
it seems that crosscompiling ocaml is currently impossible.
The whole ./configure stuff heavily relies on running several
test programs checking target stuff (ie. sizeof()).
Of course this cannot work on cross targets.
I started to add some options for bypassing such tests,
ie. --32bit and --64bit, but this doesnt go far enough and
also requires distro builders to add special fixes for this
package on every target.
Since almost all packages have to cope with this problem and
also widely used buildsystems like autoconf also have no clean
way of handling this, I suggest moving away this configuration
from individual packages to some central point - an global
config database.
We query this database by simply calling some given commandline
with the variable name as parameter. The value is simply printed
out on stdout, without linefeed.
For example to get some type sizes:
/opt/xcompiler/minibox/bin/buildconf-query host.ansi-c.sizes.long
This can be easily solved by a tiny shellscript and some carefully
maintained text database. (see attachement)
I'll now starting to rewrite the configure script ...
cu
--
---------------------------------------------------------------------
Enrico Weigelt == metux IT service
phone: +49 36207 519931 www: http://www.metux.de/
fax: +49 36207 519932 email: contact@metux.de
cellphone: +49 174 7066481
---------------------------------------------------------------------
-- DSL ab 0 Euro. -- statische IP -- UUCP -- Hosting -- Webshops --
---------------------------------------------------------------------
[-- Attachment #2: buildconf-query --]
[-- Type: text/plain, Size: 255 bytes --]
#!/bin/bash
DB=/install/config/systems/jail/etc/buildconf/buildconf.db
if [ ! "$1" ]; then
echo "$0 <query>";
exit 1;
fi
QUERY="$1";
OUT=`cat $DB | grep -E "^$QUERY:" | sed -e "s/^$QUERY://;" | sed 's/ / /g;' | sed "s/^ *//"`
echo -n "$OUT"
[-- Attachment #3: buildconf.db --]
[-- Type: text/plain, Size: 254 bytes --]
### system build configuration stuff for: JAIL (HOMER)
host.cpu.family: x86
host.cpu.type: athlon-xp
host.cpu.has-mmx: yes
host.cpu.has-mmx2: yes
host.name: jail
host.ansi-c.sizes.short: 2
host.ansi-c.sizes.long: 4
host.ansi-c.sizes.longlong: 8
next reply other threads:[~2005-08-26 12:00 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-08-26 12:00 Enrico Weigelt [this message]
2005-08-26 12:18 ` [Caml-list] " David MENTRE
2005-08-26 12:33 ` Enrico Weigelt
2005-08-26 12:18 ` Sebastian Egner
2005-08-26 13:50 ` Enrico Weigelt
2005-08-26 13:42 ` Eric Cooper
2005-08-26 17:38 ` Enrico Weigelt
2005-08-26 20:11 ` Enrico Weigelt
2005-08-26 19:50 ` Enrico Weigelt
2005-08-26 22:47 ` skaller
2005-08-27 6:20 ` Enrico Weigelt
2005-08-28 17:39 ` Quôc Peyrot
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=20050826120042.GA9061@nibiru.local \
--to=weigelt@metux.de \
--cc=caml-list@yquem.inria.fr \
/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