]> CyberLeo.Net >> Repos - FreeBSD/releng/10.0.git/blob - gnu/lib/libgomp/Makefile
- Copy stable/10 (r259064) to releng/10.0 as part of the
[FreeBSD/releng/10.0.git] / gnu / lib / libgomp / Makefile
1 # $FreeBSD$
2
3 GCCDIR= ${.CURDIR}/../../../contrib/gcc
4 GCCLIB= ${.CURDIR}/../../../contrib/gcclibs
5 SRCDIR= ${GCCLIB}/libgomp
6
7 .PATH: ${SRCDIR} ${SRCDIR}/config/posix
8
9 LIB=            gomp
10 SHLIB_MAJOR=    1
11
12 SRCS=   alloc.c barrier.c critical.c env.c \
13         error.c iter.c loop.c ordered.c parallel.c sections.c \
14         single.c team.c work.c lock.c mutex.c proc.c sem.c \
15         bar.c time.c fortran.c
16 SRCS+=  gstdint.h libgomp_f.h omp.h omp_lib.h
17
18 INCS+=  omp.h
19
20 CFLAGS+= -DHAVE_CONFIG_H
21 CFLAGS+= -I${.CURDIR} -I. -I${SRCDIR} -I${SRCDIR}/config/posix
22
23 VERSION_MAP=    ${SRCDIR}/libgomp.map
24
25 # Target-specific OpenMP configuration
26 .if ${MACHINE_CPUARCH} == arm || ${MACHINE_CPUARCH} == i386 || \
27     ${MACHINE_ARCH} == powerpc || \
28     (${MACHINE_CPUARCH} == mips &&  ${MACHINE_ARCH:Mmips64*} == "")
29 OMP_LOCK_ALIGN  =       4
30 OMP_LOCK_KIND=          4
31 OMP_LOCK_SIZE=          4
32 OMP_NEST_LOCK_ALIGN=    4
33 OMP_NEST_LOCK_KIND=     8
34 OMP_NEST_LOCK_SIZE=     8
35 .else
36 OMP_LOCK_ALIGN  =       8
37 OMP_LOCK_KIND=          8
38 OMP_LOCK_SIZE=          8
39 OMP_NEST_LOCK_ALIGN=    8
40 OMP_NEST_LOCK_KIND=     8
41 OMP_NEST_LOCK_SIZE=     16
42 .endif
43
44 gstdint.h:
45         echo  '#include <sys/types.h>'  >  ${.TARGET}
46         echo  '#include <stdint.h>'     >> ${.TARGET}
47 CLEANFILES+= gstdint.h
48
49 .for HFILE in libgomp_f.h omp.h omp_lib.h
50 ${HFILE}: ${SRCDIR}/${HFILE}.in ${.CURDIR}/Makefile
51         sed -e 's/@OMP_LOCK_ALIGN@/${OMP_LOCK_ALIGN}/g' \
52             -e 's/@OMP_LOCK_KIND@/${OMP_LOCK_KIND}/g' \
53             -e 's/@OMP_LOCK_SIZE@/${OMP_LOCK_SIZE}/g' \
54             -e 's/@OMP_NEST_LOCK_ALIGN@/${OMP_NEST_LOCK_ALIGN}/g' \
55             -e 's/@OMP_NEST_LOCK_KIND@/${OMP_NEST_LOCK_KIND}/g' \
56             -e 's/@OMP_NEST_LOCK_SIZE@/${OMP_NEST_LOCK_SIZE}/g' \
57             < ${SRCDIR}/${HFILE}.in > ${.TARGET}
58 CLEANFILES+= ${HFILE}
59 .endfor
60
61 .include <bsd.lib.mk>