Follow @Openwall on Twitter for new release announcements and other news
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date: Mon, 15 Apr 2013 01:35:33 -0400
From: Zvi Gilboa <>
To: <>
Subject: Re: Request for ideas on arch-specific musl-gcc specfile additions

On 04/15/2013 12:49 AM, Rich Felker wrote:
> On Mon, Apr 15, 2013 at 12:31:34AM -0400, Zvi Gilboa wrote:
>> 2) add arch-specific variables in the relevant places and set them
>> from outside, possibly by executing from within an
>> arch-specific shell script.  For instance:
>> *cpp_options:
>> $ARCH_SPECIFIC_CFLAGS -nostdinc -isystem $incdir %(old_cpp_options)
> Hmm, I had forgotten it was a shell script and not just a sed script
> or something doing the replacements. So we could just put something
> like:
> $(case "$ARCH" in
> mips*) echo "mips stuff here" ;;
> powerpc*) echo "ppc stuff here" ;;
> easc)
> Does that work? Might have to add $ARCH to the args to the script, but
> otherwise it seems ok.
> Rich

I am not sure whether /echo/ will be the cleanest way, especially if 
customization is needed in multiple places.  Here is something that I 
just tested and seems to work:

case "$ARCH" in
         x86_64*) CC1_ARCH_SPECIFIC_CFLAGS="x86_64-something-for-cc1" ;;
         powerpc*) CC1_ARCH_SPECIFIC_CFLAGS="powerpc-something-for-cc1" ;;
*$CC1_ARCH_SPECIFIC_CFLAGS* %(cc1_cpu) -nostdinc -isystem $incdir

lib/musl-gcc.specs: tools/ config.mak
         sh $< "$(includedir)" "$(libdir)" "$(LDSO_PATHNAME)" 
*"$(ARCH)"* > $@

Content of type "text/html" skipped

Powered by blists - more mailing lists

Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.