handle assembly files for MKPIE

This commit is contained in:
christos 2008-10-19 15:22:50 +00:00
parent bdb5cd51ab
commit 81dd08df0d
3 changed files with 7 additions and 4 deletions

View File

@ -1,4 +1,4 @@
# $NetBSD: bsd.lib.mk,v 1.287 2008/10/17 17:29:39 christos Exp $
# $NetBSD: bsd.lib.mk,v 1.288 2008/10/19 15:22:50 christos Exp $
# @(#)bsd.lib.mk 8.3 (Berkeley) 4/22/94
.include <bsd.init.mk>
@ -39,6 +39,7 @@ clean: cleanlib
# files or always have a shared library.
.if defined(MKPIE) && (${MKPIE} != "no")
CFLAGS+= ${PIE_CFLAGS}
AFLAGS+= ${PIE_AFLAGS}
.endif
COPTS+= ${COPTS.lib${LIB}}
CPPFLAGS+= ${CPPFLAGS.lib${LIB}}

View File

@ -1,4 +1,4 @@
# $NetBSD: bsd.prog.mk,v 1.238 2008/10/16 14:36:42 christos Exp $
# $NetBSD: bsd.prog.mk,v 1.239 2008/10/19 15:22:50 christos Exp $
# @(#)bsd.prog.mk 8.2 (Berkeley) 4/2/94
.ifndef HOSTPROG
@ -53,6 +53,7 @@ CLEANFILES+=strings
.if defined(MKPIE) && (${MKPIE} != "no")
CFLAGS+= ${PIE_CFLAGS}
AFLAGS+= ${PIE_AFLAGS}
LDFLAGS+= ${PIE_LDFLAGS}
.endif

View File

@ -1,4 +1,4 @@
# $NetBSD: bsd.sys.mk,v 1.174 2008/10/16 14:36:42 christos Exp $
# $NetBSD: bsd.sys.mk,v 1.175 2008/10/19 15:22:50 christos Exp $
#
# Build definitions used for NetBSD source tree builds.
@ -89,8 +89,9 @@ CFLAGS+= ${CPUFLAGS}
AFLAGS+= ${CPUFLAGS}
# Position Independent Executable flags
PIE_CFLAGS?= -fPIC
PIE_CFLAGS?= -fPIC -DPIC
PIE_LDFLAGS?= -Wl,-pie -shared-libgcc
PIE_AFLAGS?= -fPIC -DPIC
# Helpers for cross-compiling
HOST_CC?= cc