Update reachover makefiles for MesaLib 7.11.2.

With the new GL shader compiler, glsl-compile is no longer needed as
a tool, but the shader compiler is now duplicated in several
libraries, so (XXX) external/mit/xorg/tools/glsl should be turned
into a proper library that libGL and libmesa can link against.
This commit is contained in:
riastradh 2014-07-09 20:22:55 +00:00
parent 3b57daad13
commit f31abfff58
18 changed files with 275 additions and 252 deletions

View File

@ -1,4 +1,4 @@
# $NetBSD: dri.mk,v 1.12 2012/03/10 20:52:30 tron Exp $
# $NetBSD: dri.mk,v 1.13 2014/07/09 20:22:55 riastradh Exp $
# XXX DRI_LIB_DEPS
@ -8,15 +8,15 @@ LIBISMODULE= yes
SHLIB_MAJOR= 0
CPPFLAGS+= -I${X11SRCDIR.MesaLib}/src/mesa/main \
-I${X11SRCDIR.MesaLib}/src/mesa/glapi \
-I${X11SRCDIR.MesaLib}/src/mesa/shader \
-I${X11SRCDIR.MesaLib}/src/mesa/drivers/dri/common \
-I${X11SRCDIR.MesaLib}/src/mesa/drivers/dri/${MODULE}/server \
-I${X11SRCDIR.MesaLib}/src/mesa \
-I${X11SRCDIR.MesaLib}/include \
-I${DESTDIR}${X11INCDIR}/libdrm \
-I${DESTDIR}${X11INCDIR}/X11
CPPFLAGS+= \
-I${X11SRCDIR.MesaLib}/src/mesa/drivers/dri/common \
-I${X11SRCDIR.MesaLib}/src/mesa/drivers/dri/${MODULE}/server \
-I${X11SRCDIR.MesaLib}/include \
-I${X11SRCDIR.MesaLib}/src/mapi \
-I${X11SRCDIR.MesaLib}/src/mesa \
-I${X11SRCDIR.MesaLib}/src/egl/main \
-I${X11SRCDIR.MesaLib}/src/egl/drivers/dri \
-I${DESTDIR}${X11INCDIR}/libdrm
CPPFLAGS+= -D_NETBSD_SOURCE -DPTHREADS -DUSE_EXTERNAL_DXTN_LIB=1 \
-DIN_DRI_DRIVER -DGLX_DIRECT_RENDERING \
@ -30,10 +30,9 @@ CPPFLAGS+= -Wno-stack-protector
.PATH: ${X11SRCDIR.MesaLib}/src/mesa/drivers/dri/common \
${X11SRCDIR.MesaLib}/src/mesa/drivers/common
.if (${MODULE} == "swrast")
SRCS+= driverfuncs.c utils.c
SRCS+= drisw_util.c driverfuncs.c utils.c
.else
SRCS+= dri_util.c drirenderbuffer.c driverfuncs.c texmem.c
SRCS+= dri_metaops.c
SRCS+= utils.c vblank.c xmlconfig.c
.endif

View File

@ -1,4 +1,4 @@
# $NetBSD: Makefile,v 1.11 2011/08/11 23:15:36 joerg Exp $
# $NetBSD: Makefile,v 1.12 2014/07/09 20:22:55 riastradh Exp $
MODULE= i915
@ -19,6 +19,7 @@ SRCS= \
intel_batchbuffer.c \
intel_clear.c \
intel_extensions.c \
intel_extensions_es.c \
intel_mipmap_tree.c \
intel_tex_layout.c \
intel_tex_image.c \
@ -56,8 +57,6 @@ CPPFLAGS+= -DI915 -DDRM_VBLANK_FLIP=DRM_VBLANK_FLIP
LIBDPLIBS+= drm_intel ${.CURDIR}/../../libdrm_intel
COPTS.intel_context.c+= -Wno-error # XXX
COPTS.intel_tex.c+= -Wno-error # XXX
CWARNFLAGS.clang+= -Wno-tautological-compare -Wno-format \
-Wno-constant-logical-operand

View File

@ -1,4 +1,4 @@
# $NetBSD: Makefile,v 1.14 2012/03/22 23:46:27 joerg Exp $
# $NetBSD: Makefile,v 1.15 2014/07/09 20:22:55 riastradh Exp $
MODULE= i965
@ -17,6 +17,7 @@ SRCS= \
intel_context.c \
intel_decode.c \
intel_extensions.c \
intel_extensions_es.c \
intel_fbo.c \
intel_mipmap_tree.c \
intel_regions.c \
@ -58,6 +59,7 @@ SRCS= \
brw_gs_emit.c \
brw_gs_state.c \
brw_misc_state.c \
brw_optimize.c \
brw_program.c \
brw_queryobj.c \
brw_sf.c \
@ -82,7 +84,6 @@ SRCS= \
brw_wm_emit.c \
brw_wm_fp.c \
brw_wm_iz.c \
brw_wm_glsl.c \
brw_wm_pass0.c \
brw_wm_pass1.c \
brw_wm_pass2.c \
@ -99,14 +100,32 @@ SRCS= \
gen6_urb.c \
gen6_viewport_state.c \
gen6_vs_state.c \
gen6_wm_state.c
gen6_wm_state.c \
gen7_cc_state.c \
gen7_clip_state.c \
gen7_disable.c \
gen7_misc_state.c \
gen7_sampler_state.c \
gen7_sf_state.c \
gen7_urb.c \
gen7_viewport_state.c \
gen7_vs_state.c \
gen7_wm_state.c \
gen7_wm_surface_state.c
SRCS+= \
brw_cubemap_normalize.cpp \
brw_fs.cpp \
brw_fs_emit.cpp \
brw_fs_visitor.cpp \
brw_fs_channel_expressions.cpp \
brw_fs_reg_allocate.cpp \
brw_fs_schedule_instructions.cpp \
brw_fs_vector_splitting.cpp \
brw_shader.cpp
COPTS.brw_draw_upload.c= -Wno-error
CWARNFLAGS.clang+= -Wno-format -Wno-switch
LIBDPLIBS+= drm_intel ${.CURDIR}/../../libdrm_intel
COPTS.intel_context.c+= -Wno-error # XXX
COPTS.intel_tex.c+= -Wno-error # XXX
.include "${.CURDIR}/../dri.mk"

View File

@ -1,23 +1,21 @@
# $NetBSD: Makefile,v 1.11 2013/02/09 17:18:01 christos Exp $
# $NetBSD: Makefile,v 1.12 2014/07/09 20:22:55 riastradh Exp $
.include <bsd.own.mk>
_LIB_PREFIX= lib
LIB= mesa_dri
LIBISMODULE= yes
LIBISCXX= yes
SHLIB_MAJOR= 0
MESA_SRC_MODULES= glapi main math vbo tnl shader swrast slang ss common
CPPFLAGS+= -I${X11SRCDIR.MesaLib}/src/mesa/main \
-I${X11SRCDIR.MesaLib}/src/mesa/glapi \
-I${X11SRCDIR.MesaLib}/src/mesa/shader \
-I${X11SRCDIR.MesaLib}/src/mesa/drivers/dri/common \
-I${X11SRCDIR.MesaLib}/src/mesa \
-I${X11SRCDIR.MesaLib}/include \
-I${DESTDIR}${X11INCDIR}/X11
MESA_SRC_MODULES= main math vbo tnl program swrast ss common
CPPFLAGS+= \
-I${X11SRCDIR.MesaLib}/include \
-I${X11SRCDIR.MesaLib}/src/glsl \
-I${X11SRCDIR.MesaLib}/src/mesa \
-I${X11SRCDIR.MesaLib}/src/mapi
CPPFLAGS+= ${X11FLAGS.THREADLIB} \
-DPTHREADS -D_NETBSD_SOURCE -DUSE_EXTERNAL_DXTN_LIB=1 \
@ -28,7 +26,7 @@ CFLAGS+= -pthread
.include "../../libOSMesa/libmesa.mk"
.include "../../../tools/glsl/Makefile.glslsrcs"
SRCS+= ${SRCS.pp} ${SRCS.cl}
SRCS+= ${SRCS.glsl}
.include <bsd.x11.mk>

View File

@ -1,4 +1,4 @@
# $NetBSD: Makefile,v 1.4 2011/08/11 23:15:37 joerg Exp $
# $NetBSD: Makefile,v 1.5 2014/07/09 20:22:55 riastradh Exp $
MODULE= r128
@ -6,7 +6,6 @@ SRCS= r128_context.c r128_lock.c r128_state.c r128_texstate.c r128_dd.c \
r128_screen.c r128_tex.c r128_tris.c r128_ioctl.c r128_span.c \
r128_texmem.c
COPTS.r128_span.c= -Wno-error # XXX const
CWARNFLAGS.clang+= -Wno-constant-logical-operand
.include "${.CURDIR}/../dri.mk"

View File

@ -1,4 +1,4 @@
# $NetBSD: Makefile,v 1.8 2011/08/11 23:15:37 joerg Exp $
# $NetBSD: Makefile,v 1.9 2014/07/09 20:22:55 riastradh Exp $
MODULE= r200
@ -30,7 +30,6 @@ SRCS= \
r200_state.c \
r200_state_init.c \
r200_cmdbuf.c \
r200_pixel.c \
r200_tex.c \
r200_texstate.c \
r200_tcl.c \
@ -48,13 +47,6 @@ SRCS+= \
LIBDPLIBS+= drm_radeon ${.CURDIR}/../../libdrm_radeon
# XXX
.if ${MACHINE_ARCH} == "sparc64"
COPTS.r200_tcl.c= -Wno-error
.endif
COPTS.radeon_screen.c= -Wno-error # XXX const
CWARNFLAGS.clang+= -Wno-format -Wno-constant-logical-operand \
-Wno-empty-body

View File

@ -1,4 +1,4 @@
# $NetBSD: Makefile,v 1.8 2011/08/11 23:15:37 joerg Exp $
# $NetBSD: Makefile,v 1.9 2014/07/09 20:22:55 riastradh Exp $
MODULE= r300
@ -10,7 +10,8 @@ CPPFLAGS+= -DHAVE_LIBDRM_RADEON
CPPFLAGS+= -I${X11SRCDIR.MesaLib}/src/mesa/drivers/dri/r300 \
-I${X11SRCDIR.MesaLib}/src/mesa/drivers/dri/r300/compiler \
-I${X11SRCDIR.MesaLib}/src/mesa/drivers/dri/radeon \
-I${X11SRCDIR.MesaLib}/src/mesa/drivers/dri/radeon/server
-I${X11SRCDIR.MesaLib}/src/mesa/drivers/dri/radeon/server \
-I${X11SRCDIR.MesaLib}/src/glsl
DRI_EXTRA_PATHS= ${X11SRCDIR.MesaLib}/src/mesa/drivers/dri/radeon \
${X11SRCDIR.MesaLib}/src/mesa/drivers/dri/r300/compiler
@ -77,15 +78,8 @@ SRCS+= \
LIBDPLIBS+= drm_radeon ${.CURDIR}/../../libdrm_radeon
# ../common/mm.c \
# ../common/vblank.c \
# ../common/xmlconfig.c \
# ../common/dri_util.c \
COPTS.radeon_screen.c= -Wno-error # XXX const
# uses C99 variable decl scoping
CFLAGS+= -std=c99
CFLAGS+= -std=c99
CWARNFLAGS.clang+= -Wno-empty-body -Wno-format -Wno-constant-conversion \
-Wno-constant-logical-operand

View File

@ -1,4 +1,4 @@
# $NetBSD: Makefile,v 1.4 2011/08/11 23:15:37 joerg Exp $
# $NetBSD: Makefile,v 1.5 2014/07/09 20:22:55 riastradh Exp $
MODULE= r600
@ -55,9 +55,6 @@ SRCS+= \
LIBDPLIBS+= drm_radeon ${.CURDIR}/../../libdrm_radeon
COPTS.radeon_screen.c= -Wno-error # XXX const
COPTS.r700_assembler.c= -Wno-error # XXX pointer casts
CWARNFLAGS.clang+= -Wno-constant-logical-operand -Wno-empty-body \
-Wno-format

View File

@ -1,4 +1,4 @@
# $NetBSD: Makefile,v 1.8 2011/08/11 23:15:37 joerg Exp $
# $NetBSD: Makefile,v 1.9 2014/07/09 20:22:55 riastradh Exp $
MODULE= radeon
@ -10,6 +10,7 @@ CPPFLAGS+= -I${X11SRCDIR.MesaLib}/src/mesa/drivers/dri/radeon
SRCS= \
radeon_blit.c \
radeon_bo_legacy.c \
radeon_buffer_objects.c \
radeon_common_context.c \
radeon_common.c \
radeon_cs_legacy.c \
@ -18,21 +19,27 @@ SRCS= \
radeon_fbo.c \
radeon_lock.c \
radeon_mipmap_tree.c \
radeon_pixel_read.c \
radeon_queryobj.c \
radeon_span.c \
radeon_texture.c \
radeon_tex_copy.c \
radeon_tex_getimage.c \
radeon_tile.c
SRCS+= \
radeon_context.c \
radeon_ioctl.c \
radeon_screen.c \
radeon_state.c \
radeon_state_init.c \
radeon_tex.c \
radeon_tex_copy.c \
radeon_texstate.c \
radeon_tcl.c \
radeon_swtcl.c \
radeon_maos.c \
radeon_sanity.c \
radeon_blit.c
SRCS+= \
radeon_cs_space_drm.c \
@ -41,13 +48,6 @@ SRCS+= \
LIBDPLIBS+= drm_radeon ${.CURDIR}/../../libdrm_radeon
# XXX
.if ${MACHINE_ARCH} == "sparc64"
COPTS.radeon_tcl.c= -Wno-error
.endif
COPTS.radeon_screen.c= -Wno-error # XXX const
CWARNFLAGS.clang+= -Wno-constant-logical-operand -Wno-empty-body \
-Wno-format

View File

@ -1,4 +1,4 @@
# $NetBSD: Makefile,v 1.3 2008/09/26 07:15:53 rtr Exp $
# $NetBSD: Makefile,v 1.4 2014/07/09 20:22:55 riastradh Exp $
MODULE= s3v
@ -6,7 +6,4 @@ SRCS= s3v_context.c s3v_dd.c s3v_inithw.c s3v_lock.c s3v_render.c \
s3v_screen.c s3v_span.c s3v_state.c s3v_tex.c s3v_texmem.c \
s3v_texstate.c s3v_tris.c s3v_vb.c s3v_xmesa.c
COPTS.s3v_tris.c= -Wno-error
COPTS.s3v_texmem.c= -Wno-error
.include "${.CURDIR}/../dri.mk"

View File

@ -1,4 +1,4 @@
# $NetBSD: Makefile,v 1.1 2009/06/16 00:26:11 mrg Exp $
# $NetBSD: Makefile,v 1.2 2014/07/09 20:22:55 riastradh Exp $
MODULE= swrast
@ -9,6 +9,4 @@ SRCS= \
swrast.c \
swrast_span.c
COPTS.swrast.c= -Wno-error # XXX const
.include "${.CURDIR}/../dri.mk"

View File

@ -1,4 +1,4 @@
# $NetBSD: Makefile,v 1.4 2011/08/11 23:15:37 joerg Exp $
# $NetBSD: Makefile,v 1.5 2014/07/09 20:22:56 riastradh Exp $
MODULE= tdfx
@ -6,7 +6,6 @@ SRCS= tdfx_context.c tdfx_dd.c tdfx_lock.c tdfx_pixels.c tdfx_render.c \
tdfx_screen.c tdfx_span.c tdfx_state.c tdfx_tex.c tdfx_texman.c \
tdfx_texstate.c tdfx_tris.c tdfx_vb.c
COPTS.tdfx_screen.c= -Wno-error # XXX const
CWARNFLAGS.clang+= -Wno-constant-logical-operand \
-Wno-tautological-compare

View File

@ -1,25 +1,23 @@
# $NetBSD: Makefile,v 1.18 2012/03/22 23:46:27 joerg Exp $
# $NetBSD: Makefile,v 1.19 2014/07/09 20:22:56 riastradh Exp $
.include <bsd.own.mk>
LIB= GL
LIBISCXX= yes
SUBDIR= internal
# glx
.PATH: ${X11SRCDIR.MesaLib}/src/glx
SRCS.glx= glcontextmodes.c clientattrib.c compsize.c eval.c glxcmds.c \
glxext.c glxextensions.c indirect.c indirect_init.c \
indirect_size.c indirect_window_pos.c \
SRCS.glx= clientattrib.c compsize.c eval.c glxconfig.c glxcmds.c \
glxext.c glxextensions.c indirect_glx.c indirect.c \
indirect_init.c indirect_size.c indirect_window_pos.c \
indirect_transpose_matrix.c indirect_vertex_array.c \
indirect_vertex_program.c pixel.c pixelstore.c render2.c \
renderpix.c single2.c singlepix.c vertarr.c xfont.c \
glx_pbuffer.c glx_query.c \
glxcurrent.c indirect_texture_compression.c
.PATH: ${X11SRCDIR.MesaLib}/src/mesa/glapi
SRCS.glx+= glapi.c glapi_dispatch.c glapi_getproc.c glapi_nop.c glthread.c
# XXX see TODO
#.if ${MACHINE_ARCH} == "i386"
#.PATH: ${X11SRCDIR.MesaLib}/src/mesa/x86
@ -38,12 +36,18 @@ CPPFLAGS.${fn}=-DDEFAULT_DRIVER_DIR=\"${X11USRLIBDIR}/modules/dri\"
.endfor
.endif
MESA_SRC_MODULES= main math vbo tnl shader swrast slang glapi common \
osmesa ss
# MAPI stuff.
.PATH: ${X11SRCDIR.MesaLib}/src/mapi/mapi
SRCS.mapi= \
u_current.c \
u_execmem.c \
u_thread.c
# XXX Why don't we just link against libmesa?
MESA_SRC_MODULES= main math vbo tnl program swrast glapi common ss
.include "../libOSMesa/libmesa.mk"
.PATH: ${X11SRCDIR.MesaLib}/src/glw
.PATH: ${X11SRCDIR.MesaLib}/include/GL
.PATH: ${X11SRCDIR.MesaLib}/src/mesa/drivers/x11
@ -52,25 +56,27 @@ INCS= GLwDrawA.h GLwDrawAP.h GLwMDrawA.h GLwMDrawAP.h gl.h gl_mangle.h \
xmesa_xf86.h
INCSDIR=${X11INCDIR}/GL
SRCS+= ${SRCS.dri} ${SRCS.glx}
# XXX Create a separate libglsl rather than copying this...
.include "../../tools/glsl/Makefile.glslsrcs"
SRCS+= ${SRCS.pp} ${SRCS.cl}
SRCS+= ${SRCS.dri} ${SRCS.glx} ${SRCS.glsl} ${SRCS.mapi}
CPPFLAGS+= -I${DESTDIR}${X11INCDIR}/GL \
-I${DESTDIR}${X11INCDIR}/X11 \
-I${DESTDIR}${X11INCDIR}/X11/extensions \
-I${DESTDIR}${X11INCDIR}/libdrm \
-I${X11SRCDIR.MesaLib}/include \
-I${X11SRCDIR.MesaLib}/include/GL/internal \
-I${X11SRCDIR.MesaLib}/src/mesa/main \
-I${X11SRCDIR.MesaLib}/src/mesa/glapi \
-I${X11SRCDIR.MesaLib}/src/mesa \
${X11FLAGS.THREADLIB}
CPPFLAGS+= \
-I${X11SRCDIR.MesaLib}/include \
-I${X11SRCDIR.MesaLib}/include/GL/internal \
-I${X11SRCDIR.MesaLib}/src/mesa \
-I${X11SRCDIR.MesaLib}/src/mapi \
-I${X11SRCDIR.MesaLib}/src/mapi/glapi \
-I${DESTDIR}${X11INCDIR}/libdrm \
-I${DESTDIR}${X11INCDIR}/GL \
-I${DESTDIR}${X11INCDIR}/X11 \
-I${DESTDIR}${X11INCDIR}/X11/extensions
# XXX ?
# -I${X11SRCDIR.dri2proto}/src/mesa \
CPPFLAGS+= ${X11FLAGS.THREADLIB}
CFLAGS+= -fno-strict-aliasing -fvisibility=hidden -pthread
CPPFLAGS+= -DUSE_SSE_SYSCTL_DETECTION \
-D__GLX_ALIGN64 \
@ -86,7 +92,8 @@ CPPFLAGS+= -DUSE_SSE_SYSCTL_DETECTION \
-DHZ=100 \
-DHAVE_ALIAS \
-DXF86VIDMODE \
-UIN_DRI_DRIVER
-UIN_DRI_DRIVER \
-DMAPI_MODE_UTIL
LIBDPLIBS= Xext ${.CURDIR}/../libXext \
X11 ${.CURDIR}/../libX11/dynamic \
@ -96,12 +103,6 @@ LIBDPLIBS= Xext ${.CURDIR}/../libXext \
drm ${.CURDIR}/../libdrm \
m ${.CURDIR}/../../../../../lib/libm
# XXX XXX
COPTS.dri_glx.c= -Wno-error
COPTS.dri2_glx.c= -Wno-error
COPTS.drisw_glx.c= -Wno-error
COPTS.glxext.c= -Wno-error
COPTS.indirect_vertex_program.c= -Wno-error
MKLINT=no
PKGCONFIG= gl

View File

@ -1,11 +1,10 @@
# $NetBSD: Makefile,v 1.7 2012/03/22 23:46:27 joerg Exp $
# $NetBSD: Makefile,v 1.8 2014/07/09 20:22:56 riastradh Exp $
.include <bsd.own.mk>
LIB= OSMesa
MESA_SRC_MODULES= main math vbo tnl shader swrast slang glapi common \
osmesa ss
MESA_SRC_MODULES= main math vbo tnl program swrast glapi common osmesa ss
.PATH: ${X11SRCDIR.MesaLib}/include/GL
INCS= osmesa.h

View File

@ -1,19 +1,29 @@
# $NetBSD: libmesa.mk,v 1.7 2011/03/13 04:48:53 mrg Exp $
# $NetBSD: libmesa.mk,v 1.8 2014/07/09 20:22:56 riastradh Exp $
#
# Consumer of this Makefile should set MESA_SRC_MODULES.
INCLUDES.all= . glapi main
INCLUDES.all= mapi mesa mesa/main
# The source file lists derived from src/mesa/sources.mak and
# src/mapi/glapi/sources.mak. Please keep the organization in line
# with those files.
# Main sources
PATHS.main= main
INCLUDES.main= shader
PATHS.main= mesa/main
INCLUDES.main= glsl
SRCS.main= \
api_exec_es1.c \
api_exec_es2.c
SRCS.main+= \
api_arrayelt.c \
api_exec.c \
api_loopback.c \
api_noop.c \
api_validate.c \
accum.c \
arbprogram.c \
atifragshader.c \
attrib.c \
arrayobj.c \
blend.c \
@ -32,6 +42,7 @@ SRCS.main= \
dlist.c \
dlopen.c \
drawpix.c \
drawtex.c \
enable.c \
enums.c \
MESAeval.c \
@ -56,59 +67,62 @@ SRCS.main= \
mipmap.c \
mm.c \
multisample.c \
nvprogram.c \
pack.c \
pbo.c \
MESApixel.c \
MESApixelstore.c \
pixeltransfer.c \
points.c \
polygon.c \
queryobj.c \
querymatrix.c \
rastpos.c \
rbadaptors.c \
readpix.c \
remap.c \
renderbuffer.c \
samplerobj.c \
scissor.c \
shaders.c \
shaderapi.c \
shaderobj.c \
shared.c \
state.c \
stencil.c \
syncobj.c \
texcompress.c \
texcompress_rgtc.c \
texcompress_s3tc.c \
texcompress_fxt1.c \
texenv.c \
texenvprogram.c \
texfetch.c \
texformat.c \
texgen.c \
texgetimage.c \
teximage.c \
texobj.c \
texpal.c \
texparam.c \
texrender.c \
texstate.c \
texstore.c \
texturebarrier.c \
transformfeedback.c \
uniforms.c \
varray.c \
version.c \
viewport.c \
vtxfmt.c
SRCS.main+= \
ff_fragment_shader.cpp
# XXX avoid source name clashes with glx
.PATH: ${X11SRCDIR.MesaLib}/src/mesa/main
BUILDSYMLINKS= ${X11SRCDIR.MesaLib}/src/mesa/main/pixel.c MESApixel.c \
${X11SRCDIR.MesaLib}/src/mesa/main/pixelstore.c MESApixelstore.c \
${X11SRCDIR.MesaLib}/src/mesa/main/eval.c MESAeval.c
# GL API sources
PATHS.glapi= glapi main
SRCS.glapi= \
glapi.c \
glapi_dispatch.c \
glapi_getproc.c \
glapi_nop.c \
glthread.c
# Math sources
PATHS.math= math
PATHS.math= mesa/math
SRCS.math= \
m_debug_clip.c \
m_debug_norm.c \
@ -122,8 +136,7 @@ SRCS.math+= \
m_xform.c
# Software raster sources
PATHS.swrast= swrast swrast_setup
INCLUDES.swrast= shader
PATHS.swrast= mesa/swrast
SRCS.swrast= \
s_aaline.c \
s_aatriangle.c \
@ -150,18 +163,18 @@ SRCS.swrast= \
s_stencil.c \
s_texcombine.c \
s_texfilter.c \
s_texrender.c \
s_triangle.c \
s_zoom.c
# swrast_setup
.PATH: ${X11SRCDIR.MesaLib}/src/mesa/swrast_setup
PATHS.ss= mesa/swrast_setup
SRCS.ss= \
ss_context.c \
ss_triangle.c
# TNL sources
PATHS.tnl= tnl
INCLUDES.tnl= shader
PATHS.tnl= mesa/tnl
SRCS.tnl= \
t_context.c \
t_pipeline.c \
@ -172,7 +185,6 @@ SRCS.tnl= \
t_vb_texgen.c \
t_vb_texmat.c \
t_vb_vertex.c \
t_vb_cull.c \
t_vb_fog.c \
t_vb_light.c \
t_vb_normals.c \
@ -183,7 +195,7 @@ SRCS.tnl= \
t_vertex_generic.c
# VBO sources
PATHS.vbo= vbo
PATHS.vbo= mesa/vbo
SRCS.vbo= \
vbo_context.c \
vbo_exec.c \
@ -200,21 +212,15 @@ SRCS.vbo= \
vbo_save_draw.c \
vbo_save_loopback.c
COPTS.vbo_save_draw.c= -Wno-error
# statetracker
# Shader sources
PATHS.shader= shader
INCLUDES.shader= shader/slang
SRCS.shader= \
# Program sources
PATHS.program= mesa/program
SRCS.program= \
arbprogparse.c \
arbprogram.c \
atifragshader.c \
hash_table.c \
lex.yy.c \
nvfragparse.c \
nvprogram.c \
nvvertparse.c \
program.c \
program_parse.tab.c \
@ -230,33 +236,14 @@ SRCS.shader= \
prog_statevars.c \
prog_uniform.c \
programopt.c \
symbol_table.c \
shader_api.c
register_allocate.c \
symbol_table.c
# Shader language sources
PATHS.slang= shader/slang
INCLUDES.slang= shader
SRCS.slang= \
slang_builtin.c \
slang_codegen.c \
slang_compile.c \
slang_compile_function.c \
slang_compile_operation.c \
slang_compile_struct.c \
slang_compile_variable.c \
slang_emit.c \
slang_ir.c \
slang_label.c \
slang_link.c \
slang_log.c \
slang_mem.c \
slang_print.c \
slang_simplify.c \
slang_storage.c \
slang_typeinfo.c \
slang_vartable.c \
slang_utility.c
SRCS.program+= \
ir_to_mesa.cpp \
sampler.cpp
# Unused parts of mesa/sources.mak.
.if 0
ASM_C_SOURCES = \
x86/common_x86.c \
@ -287,53 +274,65 @@ X86_SOURCES = \
x86/sse_normal.S \
x86/read_rgba_span_x86.S
X86_API = \
x86/glapi_x86.S
X86-64_SOURCES = \
x86-64/xform4.S
X86-64_API = \
x86-64/glapi_x86-64.S
SPARC_SOURCES = \
sparc/clip.S \
sparc/norm.S \
sparc/xform.S
SPARC_API = \
sparc/glapi_sparc.S
.endif
# Common driver sources
PATHS.common= drivers/common
INCLUDES.common= shader
PATHS.common= mesa/drivers/common
SRCS.common= \
driverfuncs.c \
meta.c
# OSMesa driver sources
PATHS.osmesa= drivers/osmesa
INCLUDES.osmesa= shader
PATHS.osmesa= mesa/drivers/osmesa
SRCS.osmesa= \
osmesa.c
# GLAPI sources
PATHS.glapi= mapi/glapi
SRCS.glapi = \
glapi_dispatch.c \
glapi_entrypoint.c \
glapi_gentable.c \
glapi_getproc.c \
glapi_nop.c \
glthread.c \
glapi.c
# Unused parts of mapi/glapi/sources.mak.
.if 0
X86_API = \
glapi_x86.S
X86-64_API = \
glapi_x86-64.S
SPARC_API = \
glapi_sparc.S
.endif
.for _mod_ in ${MESA_SRC_MODULES}
SRCS+= ${SRCS.${_mod_}}
. for _path_ in ${PATHS.${_mod_}}
.PATH: ${X11SRCDIR.MesaLib}/src/mesa/${_path_}
.PATH: ${X11SRCDIR.MesaLib}/src/${_path_}
. endfor
. for _path_ in ${INCLUDES.${_mod_}}
CPPFLAGS+= -I${X11SRCDIR.MesaLib}/src/mesa/${_path_}
CPPFLAGS+= -I${X11SRCDIR.MesaLib}/src/${_path_}
. endfor
.endfor
.for _path_ in ${INCLUDES.all}
CPPFLAGS+= -I${X11SRCDIR.MesaLib}/src/mesa/${_path_}
CPPFLAGS+= -I${X11SRCDIR.MesaLib}/src/${_path_}
.endfor
LIBDPLIBS= m ${NETBSDSRCDIR}/lib/libm
@ -342,49 +341,8 @@ LIBDPLIBS= m ${NETBSDSRCDIR}/lib/libm
.include "../../tools/glsl/Makefile.glsl"
CPPFLAGS+= -I.
CPPFLAGS+= -I${X11SRCDIR.MesaLib}/include
# XXXX
HEADERS.slang= library/slang_120_core_gc.h \
library/slang_builtin_120_common_gc.h \
library/slang_builtin_120_fragment_gc.h \
library/slang_common_builtin_gc.h \
library/slang_core_gc.h \
library/slang_fragment_builtin_gc.h \
library/slang_vertex_builtin_gc.h
${SRCS.slang}: ${HEADERS.slang}
library/slang_120_core_gc.h: slang_120_core.gc
-@mkdir -p library
$(GLSL) fragment $> library/slang_120_core_gc.h
library/slang_builtin_120_common_gc.h: slang_builtin_120_common.gc
-@mkdir -p library
$(GLSL) fragment $> library/slang_builtin_120_common_gc.h
library/slang_builtin_120_fragment_gc.h: slang_builtin_120_fragment.gc
-@mkdir -p library
$(GLSL) fragment $> library/slang_builtin_120_fragment_gc.h
library/slang_common_builtin_gc.h: slang_common_builtin.gc
-@mkdir -p library
$(GLSL) fragment $> library/slang_common_builtin_gc.h
library/slang_core_gc.h: slang_core.gc
-@mkdir -p library
$(GLSL) fragment $> library/slang_core_gc.h
library/slang_fragment_builtin_gc.h: slang_fragment_builtin.gc
-@mkdir -p library
$(GLSL) fragment $> library/slang_fragment_builtin_gc.h
library/slang_vertex_builtin_gc.h: slang_vertex_builtin.gc
-@mkdir -p library
$(GLSL) vertex $> library/slang_vertex_builtin_gc.h
.PATH: ${X11SRCDIR.MesaLib}/src/mesa/shader/slang/library
CLEANFILES+= ${HEADERS.slang}
cleandir: cleanmesa
cleanmesa: .PHONY
-@if [ -d library ]; then rmdir library; fi

View File

@ -1,4 +1,4 @@
# $NetBSD: Makefile,v 1.5 2014/03/17 08:01:18 mrg Exp $
# $NetBSD: Makefile,v 1.6 2014/07/09 20:22:56 riastradh Exp $
.include <bsd.own.mk>
@ -17,8 +17,6 @@ SRCS= radeon_bo.c \
CPPFLAGS+= -I${DESTDIR}${X11INCDIR}/libdrm
CPPFLAGS+= -I${DESTDIR}${X11INCDIR}/X11 -I${X11SRCDIR.drm}
COPTS.radeon_cs_gem.c+= -Wno-error # XXX
LIBDPLIBS= drm ${.CURDIR}/../libdrm
PKGCONFIG= libdrm_radeon

View File

@ -1,4 +1,4 @@
# $NetBSD: Makefile,v 1.3 2010/07/19 05:34:27 mrg Exp $
# $NetBSD: Makefile,v 1.4 2014/07/09 20:22:56 riastradh Exp $
.include <bsd.own.mk>
@ -11,7 +11,7 @@ SUBDIR+= makestrs .WAIT
# XXX pswrap/gen_matypes -- missing
SUBDIR+=bdftopcf fc-cache ucs2any glsl
SUBDIR+=bdftopcf fc-cache ucs2any
SUBDIR+=makekeys mkfontscale .WAIT xkbcomp
.include <bsd.subdir.mk>

View File

@ -1,24 +1,100 @@
# $NetBSD: Makefile.glslsrcs,v 1.1 2010/07/19 05:34:28 mrg Exp $
# $NetBSD: Makefile.glslsrcs,v 1.2 2014/07/09 20:22:56 riastradh Exp $
SRCS.pp= \
sl_pp_context.c \
sl_pp_define.c \
sl_pp_dict.c \
sl_pp_error.c \
sl_pp_expression.c \
sl_pp_extension.c \
sl_pp_if.c \
sl_pp_line.c \
sl_pp_macro.c \
sl_pp_pragma.c \
sl_pp_process.c \
sl_pp_purify.c \
sl_pp_token.c \
sl_pp_token_util.c \
sl_pp_version.c
# Derived loosely from src/glsl/Makefile.
SRCS.cl= \
sl_cl_parse.c
# XXX Now that we don't need glsl-compile as a tool, this should just
# be made into a library instead.
.PATH: ${X11SRCDIR.MesaLib}/src/glsl/pp
.PATH: ${X11SRCDIR.MesaLib}/src/glsl/cl
.PATH: ${X11SRCDIR.MesaLib}/src/glsl
.PATH: ${X11SRCDIR.MesaLib}/src/glsl/glcpp
CPPFLAGS+= -I${X11SRCDIR.MesaLib}/include
CPPFLAGS+= -I${X11SRCDIR.MesaLib}/src/glsl
CPPFLAGS+= -I${X11SRCDIR.MesaLib}/src/mapi
CPPFLAGS+= -I${X11SRCDIR.MesaLib}/src/mesa
SRCS.glsl.libglcpp= \
glcpp-lex.c \
glcpp-parse.c \
pp.c
SRCS.glsl.glcpp= \
${SRCS.glsl.libglcpp} \
strtod.c \
glcpp.c
SRCS.glsl.c= \
strtod.c \
ralloc.c \
${SRCS.glsl.libglcpp}
SRCS.glsl.cxx= \
ast_expr.cpp \
ast_function.cpp \
ast_to_hir.cpp \
ast_type.cpp \
glsl_lexer.cpp \
glsl_parser.cpp \
glsl_parser_extras.cpp \
glsl_types.cpp \
glsl_symbol_table.cpp \
hir_field_selection.cpp \
ir_basic_block.cpp \
ir_clone.cpp \
ir_constant_expression.cpp \
ir.cpp \
ir_expression_flattening.cpp \
ir_function_can_inline.cpp \
ir_function_detect_recursion.cpp \
ir_function.cpp \
ir_hierarchical_visitor.cpp \
ir_hv_accept.cpp \
ir_import_prototypes.cpp \
ir_print_visitor.cpp \
ir_reader.cpp \
ir_rvalue_visitor.cpp \
ir_set_program_inouts.cpp \
ir_validate.cpp \
ir_variable.cpp \
ir_variable_refcount.cpp \
linker.cpp \
link_functions.cpp \
loop_analysis.cpp \
loop_controls.cpp \
loop_unroll.cpp \
lower_discard.cpp \
lower_if_to_cond_assign.cpp \
lower_instructions.cpp \
lower_jumps.cpp \
lower_mat_op_to_vec.cpp \
lower_noise.cpp \
lower_texture_projection.cpp \
lower_variable_index_to_cond_assign.cpp \
lower_vec_index_to_cond_assign.cpp \
lower_vec_index_to_swizzle.cpp \
lower_vector.cpp \
opt_algebraic.cpp \
opt_constant_folding.cpp \
opt_constant_propagation.cpp \
opt_constant_variable.cpp \
opt_copy_propagation.cpp \
opt_copy_propagation_elements.cpp \
opt_dead_code.cpp \
opt_dead_code_local.cpp \
opt_dead_functions.cpp \
opt_discard_simplification.cpp \
opt_function_inlining.cpp \
opt_if_simplification.cpp \
opt_noop_swizzle.cpp \
opt_redundant_jumps.cpp \
opt_structure_splitting.cpp \
opt_swizzle_swizzle.cpp \
opt_tree_grafting.cpp \
s_expression.cpp
SRCS.glsl= \
${SRCS.glsl.c} \
${SRCS.glsl.cxx}
SRCS.glsl+= \
builtin_function.cpp