Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files. =================================================================== RCS file: /ftp/cvs/cvsroot/src/share/mk/bsd.lib.mk,v rcsdiff: /ftp/cvs/cvsroot/src/share/mk/bsd.lib.mk,v: warning: Unknown phrases like `commitid ...;' are present. retrieving revision 1.239 retrieving revision 1.243 diff -u -p -r1.239 -r1.243 --- src/share/mk/bsd.lib.mk 2003/10/26 03:29:44 1.239 +++ src/share/mk/bsd.lib.mk 2003/12/23 10:30:02 1.243 @@ -1,4 +1,4 @@ -# $NetBSD: bsd.lib.mk,v 1.239 2003/10/26 03:29:44 lukem Exp $ +# $NetBSD: bsd.lib.mk,v 1.243 2003/12/23 10:30:02 rtr Exp $ # @(#)bsd.lib.mk 8.3 (Berkeley) 4/22/94 .include @@ -21,6 +21,7 @@ LDFLAGS+= ${LDFLAGS.lib${LIB}} LDSTATIC+= ${LDSTATIC.lib${LIB}} ##### Build and install rules +MKDEP_SUFFIXES?= .o .po .so .ln CPPFLAGS+= ${DESTDIR:D-nostdinc ${CPPFLAG_ISYSTEM} ${DESTDIR}/usr/include} CXXFLAGS+= ${DESTDIR:D-nostdinc++ ${CPPFLAG_ISYSTEMXX} ${DESTDIR}/usr/include/g++} @@ -134,7 +135,16 @@ CAPICFLAGS?= ${CPPPICFLAGS} ${CPICFLAGS} APICFLAGS?= -k # XXX libraries often need the millicode functions in libgcc.a, # so we have to work around the -nostdlib: -LDADD+= `${CC} -print-libgcc-file-name` +LDADD+= -L${_GCC_LIBGCCDIR} -lgcc_pic + +.elif ${MACHINE_ARCH} == "ns32k" + +# XXX no shared libraries yet on ns32k +FPICFLAGS?= +CPICFLAGS?= +CPPPICFLAGS?= +CAPICFLAGS?= +APICFLAGS?= .else @@ -375,16 +385,20 @@ SOBJS= realall: ${SRCS} ${ALLOBJS:O} ${_LIBS} +.if !target(__archivebuild) __archivebuild: .USE ${_MKTARGET_BUILD} rm -f ${.TARGET} ${AR} cq ${.TARGET} `NM=${NM} ${LORDER} ${.ALLSRC:M*o} | ${TSORT}` ${RANLIB} ${.TARGET} +.endif +.if !target(__archiveinstall) __archiveinstall: .USE ${_MKTARGET_INSTALL} ${INSTALL_FILE} -o ${LIBOWN} -g ${LIBGRP} -m ${LIBMODE} \ ${UPDATE:D:U-a "${RANLIB} -t"} ${SYSPKGTAG} ${.ALLSRC} ${.TARGET} +.endif __archivesymlinkpic: .USE ${_MKTARGET_INSTALL} @@ -433,9 +447,9 @@ lib${LIB}.so.${SHLIB_FULLVERSION}: ${SOL # We don't use INSTALL_SYMLINK here because this is just # happening inside the build directory/objdir. XXX Why does # this spend so much effort on libraries that aren't live??? XXX - ln -sf lib${LIB}.so.${SHLIB_FULLVERSION} lib${LIB}.so.${SHLIB_MAJOR}.tmp + ${HOST_LN} -sf lib${LIB}.so.${SHLIB_FULLVERSION} lib${LIB}.so.${SHLIB_MAJOR}.tmp mv -f lib${LIB}.so.${SHLIB_MAJOR}.tmp lib${LIB}.so.${SHLIB_MAJOR} - ln -sf lib${LIB}.so.${SHLIB_FULLVERSION} lib${LIB}.so.tmp + ${HOST_LN} -sf lib${LIB}.so.${SHLIB_FULLVERSION} lib${LIB}.so.tmp mv -f lib${LIB}.so.tmp lib${LIB}.so .endif @@ -459,14 +473,6 @@ cleanlib: rm -f ${OBJS:=.tmp} ${POBJS:=.tmp} ${SOBJS:=.tmp} rm -f llib-l${LIB}.ln ${LOBJS} -.if defined(SRCS) -afterdepend: .depend - @(TMP=/tmp/_depend$$$$; trap 'rm -f $$TMP ; exit 1' 1 2 3 13 15; \ - sed -e 's/^\([^\.]*\).o[ ]*:/\1.o \1.po \1.so \1.ln:/' \ - < .depend > $$TMP && \ - mv $$TMP .depend) -.endif - .if !target(libinstall) # Make sure it gets defined, in case MKPIC==no && MKLINKLIB==no libinstall::