This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: Support bits/syscall.h build for triarch systems
- From: Roland McGrath <roland at hack dot frob dot com>
- To: "Joseph S. Myers" <joseph at codesourcery dot com>
- Cc: libc-alpha at sourceware dot org, aoliva at redhat dot com, jakub at redhat dot com, hongjiu dot lu at intel dot com
- Date: Mon, 19 Dec 2011 14:26:38 -0800 (PST)
- Subject: Re: Support bits/syscall.h build for triarch systems
- References: <Pine.LNX.4.64.1112192201410.2467@digraph.polyomino.org.uk>
There's nothing really wrong with having such a conditional in case some
sysdeps/.../Makefile turns out to really need it. But I'm more inclined to
see if we can generalize the common rule so that there's a way to support
all the variants without each port repeating a variant of the same hairy
command sequence.
It seems like it should be doable. What I have in mind is something like a
standard variable that lists the flavor names (32 and 64 for the common
bi-arch case). Then variables with names derived from that can contain the
predefines needing -U treatment. Another variable can list the headers
used to distinguish, or probably better a command sequence to emit the
preamble (what's now "echo '#include <bits/wordsize.h>'; echo '';"). It
will be some fiddly work today to get the rule to work right for the
uniarch, biarch, and triarch examples we have at hand. But thereafter, any
changes will be in the common place, and new ports won't have to cargo-cult
the big hairy rule across.
Thanks,
Roland