2016-09-21 00:05:15 -07:00
|
|
|
ACLOCAL_AMFLAGS = -I m4
|
2016-09-21 03:57:24 -07:00
|
|
|
AM_CFLAGS = @VKD3D_CFLAGS@
|
2016-09-21 03:57:24 -07:00
|
|
|
AM_CPPFLAGS = -I$(srcdir)/include -I$(srcdir)/include/dummy -I$(srcdir)/include/private
|
2016-09-21 03:57:24 -07:00
|
|
|
|
|
|
|
widl_headers = \
|
2017-12-15 06:16:21 -08:00
|
|
|
include/vkd3d_d3d12.h \
|
2018-02-09 04:45:09 -08:00
|
|
|
include/vkd3d_d3dcommon.h \
|
2017-12-15 06:16:21 -08:00
|
|
|
include/vkd3d_dxgi.h \
|
|
|
|
include/vkd3d_dxgi1_2.h \
|
|
|
|
include/vkd3d_dxgi1_3.h \
|
|
|
|
include/vkd3d_dxgi1_4.h \
|
|
|
|
include/vkd3d_dxgibase.h \
|
|
|
|
include/vkd3d_dxgiformat.h \
|
|
|
|
include/vkd3d_dxgitype.h
|
2016-09-21 03:57:24 -07:00
|
|
|
|
2016-09-21 03:57:24 -07:00
|
|
|
vkd3d_public_headers = \
|
2016-10-13 03:18:42 -07:00
|
|
|
include/vkd3d.h \
|
2017-12-15 06:16:21 -08:00
|
|
|
include/vkd3d_d3d12.h \
|
2018-02-09 04:45:09 -08:00
|
|
|
include/vkd3d_d3dcommon.h \
|
2017-12-15 06:16:21 -08:00
|
|
|
include/vkd3d_dxgibase.h \
|
|
|
|
include/vkd3d_dxgiformat.h \
|
2016-10-07 04:26:39 -07:00
|
|
|
include/vkd3d_utils.h \
|
2016-09-21 03:57:24 -07:00
|
|
|
include/vkd3d_windows.h
|
|
|
|
|
2017-07-28 06:26:09 -07:00
|
|
|
vkd3d_demos_shaders = \
|
2016-11-02 06:56:13 -07:00
|
|
|
demos/gears.hlsl \
|
2017-07-28 06:26:09 -07:00
|
|
|
demos/gears_ps_flat.h \
|
|
|
|
demos/gears_ps_smooth.h \
|
|
|
|
demos/gears_vs.h \
|
|
|
|
demos/triangle.hlsl \
|
|
|
|
demos/triangle_ps.h \
|
|
|
|
demos/triangle_vs.h
|
2016-10-13 04:50:36 -07:00
|
|
|
|
2016-09-21 03:57:24 -07:00
|
|
|
vkd3d_tests = \
|
2018-01-11 08:03:48 -08:00
|
|
|
tests/vkd3d_api
|
|
|
|
|
|
|
|
vkd3d_cross_tests = \
|
2016-09-21 03:57:24 -07:00
|
|
|
tests/d3d12
|
|
|
|
|
2018-03-29 09:21:47 -07:00
|
|
|
vkd3d_test_headers = \
|
|
|
|
tests/vkd3d_d3d12_test.h
|
|
|
|
|
2016-10-13 04:50:36 -07:00
|
|
|
vkd3d_demos = \
|
2016-11-02 06:56:13 -07:00
|
|
|
demos/gears \
|
2016-10-13 04:50:36 -07:00
|
|
|
demos/triangle
|
|
|
|
|
|
|
|
vkd3d_demos_headers = \
|
|
|
|
demos/demo.h \
|
|
|
|
demos/demo_win32.h \
|
|
|
|
demos/demo_xcb.h
|
|
|
|
|
2016-09-21 03:57:24 -07:00
|
|
|
BUILT_SOURCES = $(widl_headers)
|
|
|
|
|
2018-01-15 04:49:02 -08:00
|
|
|
noinst_LTLIBRARIES = libvkd3d-common.la libvkd3d-shader.la
|
2016-10-07 04:26:39 -07:00
|
|
|
libvkd3d_common_la_SOURCES = \
|
2016-10-13 03:18:42 -07:00
|
|
|
include/private/vkd3d_debug.h \
|
2017-06-19 09:05:53 -07:00
|
|
|
libs/vkd3d-common/debug.c \
|
|
|
|
libs/vkd3d-common/memory.c
|
2016-10-07 04:26:39 -07:00
|
|
|
|
2018-01-15 04:49:02 -08:00
|
|
|
lib_LTLIBRARIES = libvkd3d.la libvkd3d-utils.la
|
2017-06-16 13:38:21 -07:00
|
|
|
|
|
|
|
libvkd3d_shader_la_SOURCES = \
|
|
|
|
include/private/list.h \
|
|
|
|
include/private/rbtree.h \
|
|
|
|
include/private/vkd3d_common.h \
|
|
|
|
include/private/vkd3d_debug.h \
|
|
|
|
include/private/vkd3d_memory.h \
|
2018-01-16 05:02:26 -08:00
|
|
|
include/vkd3d_shader.h \
|
2017-06-16 13:38:21 -07:00
|
|
|
libs/vkd3d-shader/dxbc.c \
|
2017-06-19 09:05:53 -07:00
|
|
|
libs/vkd3d-shader/spirv.c \
|
2018-01-16 05:02:26 -08:00
|
|
|
libs/vkd3d-shader/vkd3d_shader.map \
|
2017-06-16 13:38:21 -07:00
|
|
|
libs/vkd3d-shader/vkd3d_shader_main.c \
|
|
|
|
libs/vkd3d-shader/vkd3d_shader_private.h
|
2018-02-07 12:27:11 -08:00
|
|
|
libvkd3d_shader_la_CFLAGS = @SPIRV_TOOLS_CFLAGS@
|
2018-01-15 04:49:02 -08:00
|
|
|
libvkd3d_shader_la_LIBADD = @SPIRV_TOOLS_LIBS@
|
2018-01-15 04:49:01 -08:00
|
|
|
if HAVE_LD_VERSION_SCRIPT
|
|
|
|
libvkd3d_shader_la_LDFLAGS = -Wl,--version-script=$(srcdir)/libs/vkd3d-shader/vkd3d_shader.map
|
|
|
|
endif
|
2016-10-07 04:26:39 -07:00
|
|
|
|
2016-09-21 03:57:24 -07:00
|
|
|
libvkd3d_la_SOURCES = \
|
2016-10-13 03:18:42 -07:00
|
|
|
include/private/vkd3d_common.h \
|
|
|
|
include/private/vkd3d_debug.h \
|
|
|
|
include/private/vkd3d_memory.h \
|
|
|
|
include/private/vkd3d_test.h \
|
2018-01-16 05:02:26 -08:00
|
|
|
include/vkd3d_d3d12.idl \
|
2018-02-09 04:45:09 -08:00
|
|
|
include/vkd3d_d3dcommon.idl \
|
2018-01-16 05:02:26 -08:00
|
|
|
include/vkd3d_unknown.idl \
|
2016-09-21 05:41:31 -07:00
|
|
|
libs/vkd3d/command.c \
|
2016-09-21 03:57:24 -07:00
|
|
|
libs/vkd3d/device.c \
|
2016-09-26 02:13:30 -07:00
|
|
|
libs/vkd3d/resource.c \
|
2016-09-26 02:13:30 -07:00
|
|
|
libs/vkd3d/state.c \
|
2016-09-21 03:57:24 -07:00
|
|
|
libs/vkd3d/utils.c \
|
2018-01-16 05:02:26 -08:00
|
|
|
libs/vkd3d/vkd3d.map \
|
2016-10-13 03:18:42 -07:00
|
|
|
libs/vkd3d/vkd3d_main.c \
|
|
|
|
libs/vkd3d/vkd3d_private.h \
|
|
|
|
libs/vkd3d/vulkan_procs.h
|
2018-01-17 03:48:14 -08:00
|
|
|
libvkd3d_la_LIBADD = libvkd3d-common.la libvkd3d-shader.la @DL_LIBS@ @PTHREAD_LIBS@
|
2018-01-15 04:49:01 -08:00
|
|
|
if HAVE_LD_VERSION_SCRIPT
|
|
|
|
libvkd3d_la_LDFLAGS = -Wl,--version-script=$(srcdir)/libs/vkd3d/vkd3d.map
|
|
|
|
endif
|
2016-09-21 03:57:24 -07:00
|
|
|
|
2016-10-07 04:26:39 -07:00
|
|
|
libvkd3d_utils_la_SOURCES = \
|
2018-01-16 05:02:26 -08:00
|
|
|
libs/vkd3d-utils/vkd3d_utils.map \
|
2016-10-13 03:18:42 -07:00
|
|
|
libs/vkd3d-utils/vkd3d_utils_main.c \
|
|
|
|
libs/vkd3d-utils/vkd3d_utils_private.h
|
2016-10-07 04:26:39 -07:00
|
|
|
libvkd3d_utils_la_LIBADD = libvkd3d-common.la libvkd3d.la
|
2018-01-15 04:49:01 -08:00
|
|
|
if HAVE_LD_VERSION_SCRIPT
|
|
|
|
libvkd3d_utils_la_LDFLAGS = -Wl,--version-script=$(srcdir)/libs/vkd3d-utils/vkd3d_utils.map
|
|
|
|
endif
|
2016-10-07 04:26:39 -07:00
|
|
|
|
2017-06-19 09:33:39 -07:00
|
|
|
EXTRA_DIST = LICENSE
|
|
|
|
|
2016-09-21 03:57:24 -07:00
|
|
|
pkgconfigdir = $(libdir)/pkgconfig
|
|
|
|
pkginclude_HEADERS = $(vkd3d_public_headers)
|
2017-06-30 04:10:17 -07:00
|
|
|
nodist_pkgconfig_DATA = libvkd3d.pc libvkd3d-utils.pc
|
2017-07-28 06:26:09 -07:00
|
|
|
CLEANFILES = libvkd3d.pc libvkd3d-utils.pc
|
2017-06-30 04:10:17 -07:00
|
|
|
EXTRA_DIST += libs/vkd3d/libvkd3d.pc.in libs/vkd3d-utils/libvkd3d-utils.pc.in
|
2016-09-21 03:57:24 -07:00
|
|
|
|
2018-01-15 04:49:03 -08:00
|
|
|
noinst_PROGRAMS = vkd3d-compiler
|
2017-06-16 13:38:21 -07:00
|
|
|
vkd3d_compiler_SOURCES = programs/vkd3d-compiler/main.c
|
2018-01-15 04:49:02 -08:00
|
|
|
vkd3d_compiler_LDADD = libvkd3d-shader.la libvkd3d-common.la
|
2017-06-16 13:38:21 -07:00
|
|
|
|
2017-07-20 05:51:13 -07:00
|
|
|
LDADD = libvkd3d.la libvkd3d-utils.la
|
2018-01-11 08:03:48 -08:00
|
|
|
check_PROGRAMS = $(vkd3d_tests) $(vkd3d_cross_tests)
|
2016-09-21 03:57:24 -07:00
|
|
|
AM_DEFAULT_SOURCE_EXT = .c
|
2018-01-11 08:03:48 -08:00
|
|
|
TESTS = $(vkd3d_tests) $(vkd3d_cross_tests)
|
2016-10-13 05:08:34 -07:00
|
|
|
tests_d3d12_LDADD = $(LDADD) @PTHREAD_LIBS@
|
2018-01-17 03:48:10 -08:00
|
|
|
tests_vkd3d_api_LDADD = libvkd3d.la @VULKAN_LIBS@
|
2016-09-21 03:57:24 -07:00
|
|
|
|
2017-07-20 05:51:13 -07:00
|
|
|
DEMOS_LDADD = $(LDADD) libvkd3d-shader.la @XCB_LIBS@ @VULKAN_LIBS@
|
2016-11-02 06:56:13 -07:00
|
|
|
DEMOS_CFLAGS = @XCB_CFLAGS@
|
2018-01-15 04:49:03 -08:00
|
|
|
noinst_PROGRAMS += $(vkd3d_demos)
|
2018-03-29 09:21:47 -07:00
|
|
|
EXTRA_DIST += $(vkd3d_test_headers) $(vkd3d_demos_headers)
|
2016-11-02 06:56:13 -07:00
|
|
|
|
|
|
|
demos_gears_CFLAGS = $(DEMOS_CFLAGS)
|
|
|
|
demos_gears_LDADD = $(DEMOS_LDADD) -lm
|
|
|
|
|
|
|
|
demos_triangle_CFLAGS = $(DEMOS_CFLAGS)
|
|
|
|
demos_triangle_LDADD = $(DEMOS_LDADD)
|
2016-10-13 04:50:36 -07:00
|
|
|
|
2016-09-29 03:57:01 -07:00
|
|
|
VKD3D_V_WIDL = $(vkd3d_v_widl_@AM_V@)
|
|
|
|
vkd3d_v_widl_ = $(vkd3d_v_widl_@AM_DEFAULT_V@)
|
|
|
|
vkd3d_v_widl_0 = @echo " WIDL " $@;
|
|
|
|
vkd3d_v_widl_1 =
|
|
|
|
|
2016-09-28 04:38:28 -07:00
|
|
|
EXTRA_DIST += $(widl_headers) $(widl_headers:.h=.idl)
|
2016-09-21 03:57:24 -07:00
|
|
|
$(widl_headers): %.h: %.idl
|
2018-04-13 03:37:43 -07:00
|
|
|
if HAVE_WIDL
|
2016-09-29 03:57:01 -07:00
|
|
|
$(VKD3D_V_WIDL)$(WIDL) -o $@ $<
|
2018-04-13 03:37:44 -07:00
|
|
|
sed -e '/#include <\(rpc.h\|rpcndr.h\)>/d' -i $@
|
2018-04-13 03:37:43 -07:00
|
|
|
else
|
|
|
|
echo "widl is required to generate $<"
|
|
|
|
endif
|
2016-09-21 03:57:24 -07:00
|
|
|
|
2017-07-28 06:26:09 -07:00
|
|
|
EXTRA_DIST += $(vkd3d_demos_shaders)
|
2016-10-13 04:50:36 -07:00
|
|
|
|
2017-06-30 04:10:17 -07:00
|
|
|
libvkd3d-utils.pc: $(srcdir)/libs/vkd3d-utils/libvkd3d-utils.pc.in
|
|
|
|
sed -e 's![@]prefix[@]!$(prefix)!g' \
|
|
|
|
-e 's![@]exec_prefix[@]!$(exec_prefix)!g' \
|
|
|
|
-e 's![@]includedir[@]!$(includedir)!g' \
|
|
|
|
-e 's![@]libdir[@]!$(libdir)!g' \
|
|
|
|
-e 's![@]PACKAGE_VERSION[@]!$(PACKAGE_VERSION)!g' \
|
|
|
|
$< > $@
|
|
|
|
|
2016-09-21 03:57:24 -07:00
|
|
|
libvkd3d.pc: $(srcdir)/libs/vkd3d/libvkd3d.pc.in
|
|
|
|
sed -e 's![@]prefix[@]!$(prefix)!g' \
|
|
|
|
-e 's![@]exec_prefix[@]!$(exec_prefix)!g' \
|
|
|
|
-e 's![@]includedir[@]!$(includedir)!g' \
|
|
|
|
-e 's![@]libdir[@]!$(libdir)!g' \
|
|
|
|
-e 's![@]PACKAGE_VERSION[@]!$(PACKAGE_VERSION)!g' \
|
|
|
|
$< > $@
|
2016-09-21 03:57:24 -07:00
|
|
|
|
|
|
|
## Cross-compile tests
|
|
|
|
cross_implibs = crosslibs/d3d12
|
|
|
|
CROSS_CPPFLAGS = -I$(srcdir)/include -I$(srcdir)/include/private -I$(builddir)/include
|
2016-09-29 10:32:19 -07:00
|
|
|
CROSS_CFLAGS = -g -O2 -Wall -municode ${CROSS_CPPFLAGS}
|
2016-10-22 11:18:42 -07:00
|
|
|
EXTRA_DIST += $(cross_implibs:=.cross32.def) $(cross_implibs:=.cross64.def)
|
2016-09-21 03:57:24 -07:00
|
|
|
|
2018-04-13 03:37:43 -07:00
|
|
|
if HAVE_CROSSTARGET32
|
2016-09-21 03:57:24 -07:00
|
|
|
CROSS32_CC = @CROSSCC32@
|
|
|
|
CROSS32_DLLTOOL = @CROSSTARGET32@-dlltool
|
|
|
|
CROSS32_IMPLIBS = $(cross_implibs:=.cross32.a)
|
2018-01-11 08:03:48 -08:00
|
|
|
CROSS32_EXEFILES = $(vkd3d_cross_tests:=.cross32.exe) $(vkd3d_demos:=.cross32.exe)
|
2016-09-21 03:57:24 -07:00
|
|
|
CROSS32_FILES = $(CROSS32_IMPLIBS) $(CROSS32_EXEFILES)
|
|
|
|
|
|
|
|
CLEANFILES += $(CROSS32_FILES)
|
2016-10-18 10:14:49 -07:00
|
|
|
crosstest32: $(CROSS32_FILES)
|
|
|
|
|
|
|
|
-include tests/$(DEPDIR)/*.cross32.Po
|
2016-10-13 04:50:36 -07:00
|
|
|
-include demos/$(DEPDIR)/*.cross32.Po
|
2016-09-21 03:57:24 -07:00
|
|
|
|
|
|
|
$(CROSS32_IMPLIBS): %.cross32.a: %.cross32.def
|
2016-09-29 03:57:01 -07:00
|
|
|
@${MKDIR_P} crosslibs
|
|
|
|
$(AM_V_GEN)$(CROSS32_DLLTOOL) -k -m i386 --as-flags=-32 -d $< -l $@
|
2016-09-21 03:57:24 -07:00
|
|
|
|
2016-10-18 10:14:49 -07:00
|
|
|
$(CROSS32_EXEFILES): %.cross32.exe: %.c $(CROSS32_IMPLIBS) $(widl_headers)
|
|
|
|
$(AM_V_CCLD)depbase=`echo $@ | sed 's![^/]*$$!$(DEPDIR)/&!;s!\.exe$$!!'`; \
|
2016-10-13 04:50:36 -07:00
|
|
|
$(CROSS32_CC) $(CROSS_CFLAGS) -MT $@ -MD -MP -MF $$depbase.Tpo -o $@ $< $(CROSS32_IMPLIBS) -ldxgi -lgdi32 && \
|
2016-10-18 10:14:49 -07:00
|
|
|
$(am__mv) $$depbase.Tpo $$depbase.Po
|
2016-09-21 03:57:24 -07:00
|
|
|
else
|
|
|
|
crosstest32:
|
|
|
|
endif
|
|
|
|
|
2018-04-13 03:37:43 -07:00
|
|
|
if HAVE_CROSSTARGET64
|
2016-09-21 03:57:24 -07:00
|
|
|
CROSS64_CC = @CROSSCC64@
|
|
|
|
CROSS64_DLLTOOL = @CROSSTARGET64@-dlltool
|
|
|
|
CROSS64_IMPLIBS = $(cross_implibs:=.cross64.a)
|
2018-01-11 08:03:48 -08:00
|
|
|
CROSS64_EXEFILES = $(vkd3d_cross_tests:=.cross64.exe) $(vkd3d_demos:=.cross64.exe)
|
2016-09-21 03:57:24 -07:00
|
|
|
CROSS64_FILES = $(CROSS64_IMPLIBS) $(CROSS64_EXEFILES)
|
|
|
|
|
|
|
|
CLEANFILES += $(CROSS64_FILES)
|
2016-10-18 10:14:49 -07:00
|
|
|
crosstest64: $(CROSS64_FILES)
|
|
|
|
|
|
|
|
-include tests/$(DEPDIR)/*.cross64.Po
|
2016-10-13 04:50:36 -07:00
|
|
|
-include demos/$(DEPDIR)/*.cross64.Po
|
2016-09-21 03:57:24 -07:00
|
|
|
|
|
|
|
$(CROSS64_IMPLIBS): %.cross64.a: %.cross64.def
|
2016-09-29 03:57:01 -07:00
|
|
|
@${MKDIR_P} crosslibs
|
|
|
|
$(AM_V_GEN)$(CROSS64_DLLTOOL) -k -m i386:x86-64 --as-flags=-64 -d $< -l $@
|
2016-09-21 03:57:24 -07:00
|
|
|
|
2016-10-18 10:14:49 -07:00
|
|
|
$(CROSS64_EXEFILES): %.cross64.exe: %.c $(CROSS64_IMPLIBS) $(widl_headers)
|
|
|
|
$(AM_V_CCLD)depbase=`echo $@ | sed 's![^/]*$$!$(DEPDIR)/&!;s!\.exe$$!!'`; \
|
2016-10-13 04:50:36 -07:00
|
|
|
$(CROSS64_CC) $(CROSS_CFLAGS) -MT $@ -MD -MP -MF $$depbase.Tpo -o $@ $< $(CROSS64_IMPLIBS) -ldxgi -lgdi32 && \
|
2016-10-18 10:14:49 -07:00
|
|
|
$(am__mv) $$depbase.Tpo $$depbase.Po
|
2016-09-21 03:57:24 -07:00
|
|
|
else
|
|
|
|
crosstest64:
|
|
|
|
endif
|
|
|
|
|
|
|
|
.PHONY: crosstest crosstest32 crosstest64
|
|
|
|
crosstest: crosstest32 crosstest64
|