1 # $NetBSD: Makefile,v 1.3 2011/09/22 20:55:17 mrg Exp $ 2 3 # build GCC's libgomp, so that -fopenmp works. 4 5 # XXX 6 NOLINT= # defined 7 8 .include <bsd.own.mk> 9 DIST= ${NETBSDSRCDIR}/external/gpl3/gcc/dist 10 11 LIB= gomp 12 SRCS= \ 13 alloc.c \ 14 barrier.c \ 15 critical.c \ 16 env.c \ 17 error.c \ 18 iter.c \ 19 iter_ull.c \ 20 loop.c \ 21 loop_ull.c \ 22 ordered.c \ 23 parallel.c \ 24 sections.c \ 25 single.c \ 26 task.c \ 27 team.c \ 28 work.c \ 29 lock.c \ 30 mutex.c \ 31 proc.c \ 32 sem.c \ 33 bar.c \ 34 ptrlock.c \ 35 time.c \ 36 fortran.c \ 37 affinity.c 38 39 GOMP_MACHINE_ARCH?= ${MACHINE_ARCH} 40 ARCHDIR= ${.CURDIR}/arch/${GOMP_MACHINE_ARCH} 41 42 CPPFLAGS+= \ 43 -DHAVE_CONFIG_H \ 44 -I${DIST}/libgomp \ 45 -I${DIST}/libgomp/config/posix \ 46 -I${DIST}/libgcc \ 47 -I${ARCHDIR} 48 CFLAGS+=-pthread 49 50 # libgomp.so.1.0 is in GCC 4.5. 51 SHLIB_MAJOR= 1 52 SHLIB_MINOR= 0 53 54 LDFLAGS+= -Wl,--version-script,${DIST}/libgomp/libgomp.map 55 56 .PATH: ${ARCHDIR} ${DIST}/libgomp ${DIST}/libgomp/config/posix 57 58 .include <bsd.lib.mk> 59 60 .if ${GOMP_MACHINE_ARCH} == ${MACHINE_ARCH} 61 # This is where GCC looks for it. 62 FILES= libgomp.spec 63 FILESDIR= ${LIBDIR} 64 .endif 65 66 .include <bsd.files.mk> 67