[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Fix compilation of assembler files with subdir-objects
From: |
Alexandre Duret-Lutz |
Subject: |
Re: Fix compilation of assembler files with subdir-objects |
Date: |
Mon, 20 Sep 2004 23:00:33 +0200 |
User-agent: |
Gnus/5.1003 (Gnus v5.10.3) Emacs/21.3.50 (gnu/linux) |
Hi Andreas,
Sorry for the delay. I was rushing for 1.9.2 and this one did
not seem obvious.
>>> "Andreas" == Andreas Schwab <address@hidden> writes:
Andreas> There are currently two languages that don't define
Andreas> output_flag: c and asm. For c there is a special case
Andreas> that sets output_flag to '-o' when subdir-objects is
Andreas> enabled.
Ouch, I never noticed that hack before. This means one of my
earlier patch to fine tune the conditions when Automake requires
AM_PROG_CC_C_O is wrong. Currently AM_PROG_CC_C_O is required
whenever a object is effectively compiled in subdirectory,
however this code uses `-o' whenever the subdir-objects option
is used (that's quite a difference, especially if subdir-objects
is set globally from AM_INIT_AUTOMAKE). I guess we should
change this code to use -o only when subdir objects are actually
compiled. At least for C.
Andreas> The same handling needs to be applied when compiling
Andreas> assembler files (which actually uses the same
Andreas> compiler), otherwise the object files won't end up in
Andreas> the correct directory.
For C we also need `compile' to work around compilers that do
not support `-c' and `-o' (don't ask me which). I wonder whether
we should do the same thing here, and add support for assembly
sources to `compile'. Does there exist some C compiler that
supports assembly but not -c -o? If not, maybe it's simpler
that we fix output_flag to `-o' for assembly.
--
Alexandre Duret-Lutz