1 # $NetBSD: Makefile,v 1.14.8.2 2013/06/23 06:28:45 tls Exp $ 2 3 NOLINT= 1 # defined 4 5 .include <bsd.own.mk> 6 7 LIB= pixman-1 8 9 DIST= ${X11SRCDIR.pixman}/pixman 10 .PATH: ${DIST} 11 12 SRCS= \ 13 pixman.c \ 14 pixman-access.c \ 15 pixman-access-accessors.c \ 16 pixman-bits-image.c \ 17 pixman-combine32.c \ 18 pixman-combine-float.c \ 19 pixman-conical-gradient.c \ 20 pixman-edge.c \ 21 pixman-edge-accessors.c \ 22 pixman-fast-path.c \ 23 pixman-filter.c \ 24 pixman-glyph.c \ 25 pixman-general.c \ 26 pixman-gradient-walker.c \ 27 pixman-image.c \ 28 pixman-implementation.c \ 29 pixman-linear-gradient.c \ 30 pixman-matrix.c \ 31 pixman-noop.c \ 32 pixman-radial-gradient.c \ 33 pixman-region16.c \ 34 pixman-region32.c \ 35 pixman-solid-fill.c \ 36 pixman-timer.c \ 37 pixman-trap.c \ 38 pixman-utils.c 39 40 SRCS+= \ 41 pixman-x86.c \ 42 pixman-mips.c \ 43 pixman-arm.c \ 44 pixman-ppc.c \ 45 46 # XXX 47 48 .if ${MACHINE_ARCH} == "i386" 49 SRCS+= pixman-mmx.c 50 COPTS.pixman-mmx.c= -mmmx -fvisibility=hidden 51 MKDEPFLAGS+= -mmmx -msse2 -fvisibility=hidden 52 SRCS+= pixman-sse2.c 53 COPTS.pixman-sse2.c= -msse2 -fvisibility=hidden 54 CPPFLAGS+= -DUSE_SSE2 -DUSE_X86_MMX 55 .elif ${MACHINE_ARCH} == "x86_64" 56 SRCS+= pixman-sse2.c 57 COPTS.pixman-sse2.c= -msse2 -fvisibility=hidden 58 CPPFLAGS+= -DUSE_SSE2 59 .endif 60 61 .if ${MACHINE_ARCH} == "powerpc" 62 SRCS+= pixman-vmx.c 63 COPTS.pixman-vmx.c= -maltivec 64 CPPFLAGS+= -DUSE_VMX 65 MKDEPFLAGS+= -maltivec 66 .endif 67 68 .if ${MACHINE_ARCH} == "earm" || ${MACHINE_ARCH} == "earmhf" 69 # ARM SIMD 70 SRCS+= pixman-arm-simd.c \ 71 pixman-arm-simd-asm.S \ 72 pixman-arm-simd-asm-scaled.S 73 CPPFLAGS+= -DUSE_ARM_SIMD 74 # ARM NEON 75 SRCS+= pixman-arm-neon.c \ 76 pixman-arm-neon-asm.S \ 77 pixman-arm-neon-asm-bilinear.S 78 CPPFLAGS+= -DUSE_ARM_NEON 79 # ARM iwMMX 80 #SRCS+= pixman-mmx.c 81 #COPTS.pixman-mmx.c= -mcpu=iwmmxt 82 #CPPFLAGS+= -DUSE_ARM_IWMMXT 83 .endif 84 85 .if ${MACHINE} == "evbmips" 86 # Loongson MMI 87 SRCS+= pixman-mmx.c 88 CPPFLAGS+= -DUSE_LOONGSON_MMI 89 # SIMD instructions use floatpoint registers so we need to enable their use 90 COPTS.pixman-mmx.c= -march=loongson2f -mhard-float 91 .endif 92 93 INCS= pixman.h pixman-version.h 94 INCSDIR=${X11INCDIR}/pixman-1 95 96 CPPFLAGS+= -DHAVE_CONFIG_H \ 97 -I${X11SRCDIR.pixman}/../include \ 98 -I${X11SRCDIR.pixman}/../combine \ 99 -I${X11SRCDIR.pixman}/pixman 100 101 # With pixman 0.28.3, HAVE_PTHREAD_SETSPECIFIC is much faster than TLS 102 CPPFLAGS+= -DHAVE_PTHREAD_SETSPECIFIC 103 #CPPFLAGS+= -DTLS=__thread 104 105 LIBDPLIBS= m ${.CURDIR}/../../../../../lib/libm 106 107 PKGCONFIG= pixman-1 108 PKGDIST= pixman 109 110 .include <bsd.x11.mk> 111 .include <bsd.lib.mk> 112