Path: utzoo!utgpu!watmath!watdragon!watsol!tbray From: tbray@watsol.waterloo.edu (Tim Bray) Newsgroups: comp.unix.wizards Subject: Re: generating code to run multiple targets/configurations from single Summary: Flame at minor stupidity in sun cc Message-ID: <13157@watdragon.waterloo.edu> Date: 9 Apr 89 14:44:32 GMT References: <18927@adm.BRL.MIL> <10445@bloom-beacon.MIT.EDU> Sender: daemon@watdragon.waterloo.edu Reply-To: tbray@watsol.waterloo.edu (Tim Bray) Organization: U. of Waterloo, Ontario Lines: 16 In article <10445@bloom-beacon.MIT.EDU> scs@adam.pika.mit.edu (Steve Summit) writes: >One thing I've found which helps is if your C compiler(s) pay >attention to the -o flag even in the presence of -c. >Then you can you can use a different >suffix (not just .o) for each kind of object file, and keep them >all in the same directory with one copy of the source. I've used >.ovax for vax, .o11 for pdp11, .po for profiled, etc. An excellent idea, but you happen to be in the Sun world, and you're running Sunos 4.x, and you do this, you get hundreds of brain-dead idiotic warnings from cc about 'file with unknown suffix .po passed to ld'; not that it doesn't work. I mean, *I* know what the file is, *unix* knows what the file is by looking at the magic number, which ld BETTER DO ANYHOW, on Unix we gotta depend on file extensions to tell us what a file is?, gotta wonder what kind of underworked enthusiast at Sun put that inspiration in. Grumble, Tim Bray, New OED Project, U of Waterloo, Ontario