1 # $NetBSD: Makefile,v 1.21 2014/12/18 06:24:30 mrg Exp $
11 .PATH
: ${X11SRCDIR.MesaLib
}/src
/glx
28 MESAindirect_window_pos.c \
29 indirect_texture_compression.c \
30 indirect_transpose_matrix.c \
31 indirect_vertex_array.c \
32 indirect_vertex_program.c \
45 BUILDSYMLINKS
+= ${X11SRCDIR.MesaLib
}/..
/src
/mapi
/glapi
/indirect.c MESAindirect.c
46 BUILDSYMLINKS
+= ${X11SRCDIR.MesaLib
}/..
/src
/mapi
/glapi
/indirect_init.c MESAindirect_init.c
47 BUILDSYMLINKS
+= ${X11SRCDIR.MesaLib
}/..
/src
/mapi
/glapi
/indirect_size.c MESAindirect_size.c
48 BUILDSYMLINKS
+= ${X11SRCDIR.MesaLib
}/src
/glx
/indirect_window_pos.c MESAindirect_window_pos.c
50 .for _f in
${SRCS.glx
}
51 CPPFLAGS.
${_f}= -I
${X11SRCDIR.MesaLib
}/..
/src
/mapi
/glapi
-DGLX_SHARED_GLAPI
55 .PATH
: ${X11SRCDIR.MesaLib
}/src
/mapi
56 .PATH
: ${X11SRCDIR.MesaLib
}/..
/src
/mapi
/glapi
60 .for _f in
${SRCS.glapi
}
61 CPPFLAGS.
${_f}= -DMAPI_MODE_BRIDGE \
62 -DMAPI_ABI_HEADER
=\"glapi_glapi_mapi_tmp.h
\" \
63 -I
${X11SRCDIR.MesaLib
}/src
/mesa
68 #.if ${MACHINE_ARCH} == "i386"
69 #.PATH: ${X11SRCDIR.MesaLib}/src/mesa/x86
70 #SRCS.glx+= glapi_x86.S
71 #CPPFLAGS+= -DUSE_X86_ASM -I${X11SRCDIR.MesaLib}/src/mesa/x86
72 ## -DUSE_X86_ASM $(MMX_DEFS) $(3DNOW_DEFS) $(SSE_DEFS)
87 .for fn in
${SRCS.dri
}
88 CPPFLAGS.
${fn}=-DDEFAULT_DRIVER_DIR
=\"${X11USRLIBDIR}/modules
/dri
\"
92 .
include "../libloader.mk"
94 .PATH
: ${X11SRCDIR.MesaLib
}/src
/glw
95 .PATH
: ${X11SRCDIR.MesaLib
}/include/GL
96 .PATH
: ${X11SRCDIR.MesaLib
}/src
/mesa
/drivers
/x11
97 INCS
= gl.h gl_mangle.h glcorearb.h glext.h \
98 glx.h glx_mangle.h glxext.h \
99 osmesa.h wglext.h wmesa.h
100 INCSDIR
=${X11INCDIR}/GL
103 SRCS
+= ${SRCS.dri
} ${SRCS.glx
} ${SRCS.glapi
}
106 -I
${X11SRCDIR.MesaLib
}/include \
107 -I
${X11SRCDIR.MesaLib
}/include/GL
/internal \
108 -I
${X11SRCDIR.MesaLib
}/src
/loader \
109 -I
${X11SRCDIR.MesaLib
}/src
/mapi \
110 -I
${X11SRCDIR.MesaLib
}/src
/mapi
/glapi \
111 -I
${X11SRCDIR.MesaLib
}/..
/src
/mapi
/glapi \
112 -I
${X11SRCDIR.MesaLib
}/src
/glx \
113 -I
${DESTDIR}${X11INCDIR}/libdrm \
114 -I
${DESTDIR}${X11INCDIR}/GL \
115 -I
${DESTDIR}${X11INCDIR}/X11 \
116 -I
${DESTDIR}${X11INCDIR}/X11
/extensions
118 CPPFLAGS
+= ${X11FLAGS.THREADLIB
}
123 CPPFLAGS
+= -D__GLX_ALIGN64 \
129 -DSTDC_HEADERS
=1 -DHAVE_SYS_TYPES_H
=1 -DHAVE_SYS_STAT_H
=1 \
130 -DHAVE_STDLIB_H
=1 -DHAVE_STRING_H
=1 -DHAVE_MEMORY_H
=1 \
131 -DHAVE_STRINGS_H
=1 -DHAVE_INTTYPES_H
=1 -DHAVE_STDINT_H
=1 \
132 -DHAVE_UNISTD_H
=1 -DHAVE_DLFCN_H
=1 -DHAVE___BUILTIN_BSWAP32
=1 \
133 -DHAVE___BUILTIN_BSWAP64
=1 -DHAVE_DLADDR
=1 -DHAVE_CLOCK_GETTIME
=1 \
134 -DHAVE_POSIX_MEMALIGN
-DHAVE_PTHREAD
=1 -DHAVE_DLOPEN
139 -DHAVE_LIBDRM
-DGLX_USE_DRM \
140 -DGLX_INDIRECT_RENDERING
-DGLX_DIRECT_RENDERING \
141 -DHAVE_ALIAS
-DMESA_EGL_NO_X11_HEADERS
144 -DUSE_EXTERNAL_DXTN_LIB
=1 \
147 CFLAGS
+= -fvisibility
=hidden
-fno-strict-aliasing
-fno-builtin-memcmp
148 .if
!defined
(__MINIX
)
152 DPADD
+= ${LIBMTHREAD}
153 CWARNFLAGS.clang
+= -Wno-\
#warnings
154 .
endif # !defined(__MINIX)
156 LIBDPLIBS
= Xext
${.CURDIR
}/..
/libXext \
157 X11
${.CURDIR
}/..
/libX11
/dynamic \
158 Xxf86vm
${.CURDIR
}/..
/libXxf86vm \
159 Xfixes
${.CURDIR
}/..
/libXfixes \
160 Xdamage
${.CURDIR
}/..
/libXdamage \
161 glapi
${.CURDIR
}/..
/libglapi \
162 drm
${.CURDIR
}/..
/libdrm \
163 X11-xcb
${.CURDIR
}/..
/libX11
/libX11-xcb \
164 xcb-dri2
${.CURDIR
}/..
/libxcb
/dri2 \
165 xcb-glx
${.CURDIR
}/..
/libxcb
/glx \
166 expat
${NETBSDSRCDIR}/external
/mit
/expat
/lib
/libexpat \
167 m
${NETBSDSRCDIR}/lib
/libm
172 PKGDIST.gl
= ${X11SRCDIR.MesaLib
}/src
/mesa
173 .
include "${.CURDIR}/../libGL/mesa-ver.mk"
174 PKGCONFIG_VERSION.gl
= ${MESA_VER}
176 # XXX remove these from bsd.x11.mk
177 # XXX enable GLX TLS? it's enabled in the code, but not here..
178 PKGCONFIG_SED_FLAGS
= \
179 -e
"s,@GL_PC_REQ_PRIV@,x11 xext,; \
181 s,@GL_PC_LIB_PRIV@,-lm -lpthread,; \
182 s,@GL_PC_CFLAGS@,,; \
186 CWARNFLAGS.clang
+= -Wno-tautological-compare
-Wno-format
-Wno-constant-conversion
188 .
include <bsd.x11.mk
>
189 .
include <bsd.lib.mk
>
190 .
include <bsd.subdir.mk
>