Subject: misc/2883: bsd.lib.mk .S.so and .S.po rules misrepresent themselves
To: None <gnats-bugs@gnats.netbsd.org>
From: Mike Long <mike.long@analog.com>
List: netbsd-bugs
Date: 10/22/1996 00:23:37
>Number:         2883
>Category:       misc
>Synopsis:       bsd.lib.mk .S.so and .S.po rules misrepresent themselves
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    misc-bug-people (Misc Bug People)
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Mon Oct 21 21:35:00 1996
>Last-Modified:
>Originator:     Mike Long <mike.long@analog.com>
>Organization:
	Evil Geniuses for a Better Tomorrow
>Release:        1.2A
>Environment:
System: NetBSD azathoth 1.2A NetBSD 1.2A (AZATHOTH) #6: Sat Oct 19 02:14:49 EDT 1996 root@azathoth:/usr/src/sys/arch/i386/compile/AZATHOTH i386

>Description:
	I noticed that the libm build appeared to be creating .so.o
files.  I was worried until I realized that bsd.lib.mk was lying to
me; it was adding an extra .o to the object name in the echoed
command.
>How-To-Repeat:
	(on an alpha, m68k, vax, or i386 with a hacked libm Makefile)
	cd /usr/src/lib/libm; make clean && make
>Fix:
	Apply this patch:

*** src/share/mk/bsd.lib.mk.orig	Fri Oct 18 07:16:07 1996
--- src/share/mk/bsd.lib.mk	Tue Oct 22 00:16:23 1996
***************
*** 66,70 ****
  
  .S.po .s.po:
! 	@echo "${COMPILE.S} -DPROF ${CFLAGS:M-[ID]*} ${AINC} ${.IMPSRC} -o ${.TARGET}.o"
  	@${COMPILE.S} -DPROF ${CFLAGS:M-[ID]*} ${AINC} ${.IMPSRC} -o ${.TARGET}.o
  	@${LD} -X -r ${.TARGET}.o -o ${.TARGET}
--- 66,70 ----
  
  .S.po .s.po:
! 	@echo "${COMPILE.S} -DPROF ${CFLAGS:M-[ID]*} ${AINC} ${.IMPSRC} -o ${.TARGET}"
  	@${COMPILE.S} -DPROF ${CFLAGS:M-[ID]*} ${AINC} ${.IMPSRC} -o ${.TARGET}.o
  	@${LD} -X -r ${.TARGET}.o -o ${.TARGET}
***************
*** 72,76 ****
  
  .S.so .s.so:
! 	@echo "${COMPILE.S} ${PICFLAG} -DPIC ${CFLAGS:M-[ID]*} ${AINC} ${.IMPSRC} -o ${.TARGET}.o"
  	@${COMPILE.S} ${PICFLAG} -DPIC ${CFLAGS:M-[ID]*} ${AINC} ${.IMPSRC} -o ${.TARGET}.o
  	@${LD} -x -r ${.TARGET}.o -o ${.TARGET}
--- 72,76 ----
  
  .S.so .s.so:
! 	@echo "${COMPILE.S} ${PICFLAG} -DPIC ${CFLAGS:M-[ID]*} ${AINC} ${.IMPSRC} -o ${.TARGET}"
  	@${COMPILE.S} ${PICFLAG} -DPIC ${CFLAGS:M-[ID]*} ${AINC} ${.IMPSRC} -o ${.TARGET}.o
  	@${LD} -x -r ${.TARGET}.o -o ${.TARGET}

>Audit-Trail:
>Unformatted: