Home | History | Annotate | Line # | Download | only in common-target
Makefile revision 1.8
      1 #	$NetBSD: Makefile,v 1.8 2021/04/09 23:15:52 mrg Exp $
      2 
      3 LIBISPRIVATE=	yes
      4 
      5 # For ../Makefile.inc and bsd.own.mk
      6 .include <bsd.init.mk>
      7 
      8 LIB=		common-target
      9 
     10 .include "${.CURDIR}/arch/${GCC_MACHINE_ARCH}.mk"
     11 SRCS=		${G_OBJS-libcommon-target:S/common\///:.o=.c}
     12 
     13 CPPFLAGS+=	-I${GCCARCH} -I${BACKENDOBJ} -I. \
     14 		${G_ALL_CFLAGS:M-D*} ${G_INCLUDES:M-I*:N-I.*} \
     15 		-DPREFIX=\"/usr\" \
     16 		-DDEFAULT_TARGET_VERSION=\"${G_version}\" \
     17 		-DDEFAULT_TARGET_MACHINE=\"${MACHINE_GNU_PLATFORM}\" \
     18 		-DCONFIGURE_SPECS="\"\"" \
     19 		-I${BACKENDOBJ}
     20 
     21 COPTS.prefix.c+=	-Wno-stack-protector
     22 COPTS.opts-common.c+=	-Wno-stack-protector
     23 COPTS.rs6000-common.c+=	-Wno-stack-protector
     24 COPTS.arm-common.c+=	-Wno-stack-protector
     25 .if ${MACHINE_CPU} == "sh3"
     26 COPTS.opts.c+=		${GCC_NO_FORMAT_TRUNCATION}
     27 .endif
     28 
     29 GENPROG_ERROR_DEPENDS=errors.lo
     30 
     31 .include "../Makefile.options"
     32 .include "../../Makefile.hooks"
     33 
     34 ${SRCS}: ${GCCARCH}/defs.mk
     35 
     36 ${G_common_out_file:T:R}.o:  common/common-target-hooks-def.h
     37 
     38 DPSRCS+=	options.h
     39 
     40 HOST_CPPFLAGS+=	-I${BACKENDOBJ} -I${GCCARCH} -I. -I${DIST}/include -I${DIST}/gcc
     41 HOST_CPPFLAGS+=	-DGENERATOR_FILE
     42 
     43 MKPIC:=		no
     44 MKPICLIB:=	no
     45 
     46 HOSTPROG_CXX=	1
     47 
     48 .include <bsd.lib.mk>
     49 
     50 # Force using C++ for this
     51 HOST_CC:=	${HOST_CXX}
     52 CC:=		${CXX}
     53 CFLAGS:=	${CXXFLAGS}
     54 
     55 .PATH: ${DIST}/gcc ${DIST}/gcc/common
     56 .PATH: ${G_common_out_file:H}
     57