Subject: lib/1886: assembly library sources should be assembled with with compiler front end
To: None <gnats-bugs@gnats.netbsd.org>
From: J.T. Conklin <jtc@slave.cygnus.com>
List: netbsd-bugs
Date: 01/03/1996 17:34:13
>Number:         1886
>Category:       lib
>Synopsis:       assembly library sources should be assembled with with compiler front end
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    lib-bug-people (Library Bug People)
>State:          open
>Class:          change-request
>Submitter-Id:   net
>Arrival-Date:   Thu Jan  4 14:50:01 1996
>Last-Modified:
>Originator:     J.T. Conklin
>Organization:
	
>Release:        1.1
>Environment:
	
System: NetBSD slave.cygnus.com 1.1_ALPHA NetBSD 1.1_ALPHA (SLAVE) #1: Fri Nov 17 15:39:38 PST 1995 jtc@slave.cygnus.com:/usr/src/sys/arch/sun3/compile/SLAVE sun3


>Description:
At the present time, assembly language library sources are assembled
by first processing the source file with cpp and then piping the
output to the assembler.

Compared with simply using the compiler front end (in our case gcc),
this method has a disadvantage that useful manifest constants are not
defined.  For example, bi-endian toolchains like those for the MIPS
and PowerPC usually define preprocessor macros that specify the
selected byte order.  These constants can be used in conditionals in
the assembly source to make the minor changes that may be necessary
between little and big endian versions.

Of course these constants could also be stored in our makefile templates,
but it seems best if they are only in one place (the compiler) so as not
to have multiple versions that get out of sync.

>How-To-Repeat:
	
>Fix:
Patch bsd.lib.mk to assemble *.S files with ${COMPILE.S}...

>Audit-Trail:
>Unformatted: