1 # $NetBSD: Makefile,v 1.25 2020/05/15 14:29:29 joerg Exp $ 2 3 # build GCC's libgomp, so that -fopenmp works. 4 5 # XXX 6 NOLINT= # defined 7 8 UNSUPPORTED_COMPILER.clang= # defined 9 10 .include <bsd.own.mk> 11 12 .if !defined(NO_LIBGOMP) # { 13 14 DIST= ${GCCDIST} 15 16 17 LIB= gomp 18 19 .include "${.CURDIR}/defs.mk" 20 SRCS= ${G_libgomp_la_SOURCES} 21 22 GOMP_MACHINE_ARCH?= ${MACHINE_ARCH:S/earmv5/earm/} 23 ARCHDIR= ${.CURDIR}/arch/${GOMP_MACHINE_ARCH} 24 25 CPPFLAGS+= \ 26 -DHAVE_CONFIG_H \ 27 -I${DIST}/libgomp \ 28 -I${DIST}/libgomp/config/posix \ 29 -I${DIST}/libgcc \ 30 -I${DIST}/include \ 31 -I${ARCHDIR} 32 CFLAGS+=-pthread 33 34 SHLIB_MAJOR= 2 35 SHLIB_MINOR= 0 36 37 LDFLAGS+= -Wl,--version-script,${DIST}/libgomp/libgomp.map 38 39 .if ${GOMP_MACHINE_ARCH} == ${MACHINE_ARCH:S/earmv5/earm/} 40 # This is where GCC looks for it. 41 FILES= libgomp.spec 42 FILESDIR= ${LIBDIR} 43 44 INCS= omp.h openacc.h 45 INCSDIR= ${GCC_INCSDIR} 46 .endif 47 48 .else # } else { 49 libinstall:: 50 .endif # } 51 52 .include <bsd.lib.mk> 53 54 COPTS+= -Wno-stack-protector -Wno-missing-prototypes 55 COPTS.oacc-mem.c+= -Wno-pointer-arith 56 57 COPTS.lock.c+= -Wno-error=incompatible-pointer-types 58 COPTS.target.c+= -Wno-error=pointer-arith 59 60 .PATH: ${DIST}/libgomp/config/posix 61 .PATH: ${ARCHDIR} ${DIST}/libgomp 62