vkd3d/Makefile.am

136 lines
3.9 KiB
Makefile
Raw Normal View History

2016-09-21 07:05:15 +00:00
ACLOCAL_AMFLAGS = -I m4
2016-09-21 10:57:24 +00:00
AM_CFLAGS = @VKD3D_CFLAGS@
AM_CPPFLAGS = -I$(srcdir)/include -I$(srcdir)/include/dummy -I$(srcdir)/include/private
2016-09-21 10:57:24 +00:00
widl_headers = \
include/d3d12.h
2016-09-21 10:57:24 +00:00
vkd3d_public_headers = \
include/d3d12.h \
include/dummy/rpc.h \
include/dummy/rpcndr.h \
include/dxgibase.h \
include/vkd3d.h \
include/vkd3d_utils.h \
2016-09-21 10:57:24 +00:00
include/vkd3d_windows.h
vkd3d_tests = \
tests/d3d12
2016-09-21 10:57:24 +00:00
BUILT_SOURCES = $(widl_headers)
CLEANFILES = $(widl_headers)
noinst_LTLIBRARIES = libvkd3d-common.la
libvkd3d_common_la_SOURCES = \
include/private/vkd3d_debug.h \
libs/vkd3d-common/debug.c
2016-10-07 11:26:39 +00:00
lib_LTLIBRARIES = libvkd3d.la libvkd3d-utils.la
2016-09-21 10:57:24 +00:00
libvkd3d_la_SOURCES = \
include/d3d12.idl \
include/private/vkd3d_common.h \
include/private/vkd3d_debug.h \
include/private/vkd3d_memory.h \
include/private/vkd3d_test.h \
include/unknown.idl \
libs/vkd3d/command.c \
libs/vkd3d/device.c \
libs/vkd3d/resource.c \
libs/vkd3d/state.c \
libs/vkd3d/utils.c \
libs/vkd3d/vkd3d_main.c \
libs/vkd3d/vkd3d_private.h \
libs/vkd3d/vulkan_procs.h
libvkd3d_la_LIBADD = libvkd3d-common.la @PTHREAD_LIBS@
2016-09-21 10:57:24 +00:00
2016-10-07 11:26:39 +00:00
libvkd3d_utils_la_SOURCES = \
libs/vkd3d-utils/vkd3d_utils_main.c \
libs/vkd3d-utils/vkd3d_utils_private.h
2016-10-07 11:26:39 +00:00
libvkd3d_utils_la_LIBADD = libvkd3d-common.la libvkd3d.la
2016-09-21 10:57:24 +00:00
pkgconfigdir = $(libdir)/pkgconfig
pkginclude_HEADERS = $(vkd3d_public_headers)
nodist_pkgconfig_DATA = libvkd3d.pc
2016-10-13 10:18:42 +00:00
CLEANFILES += libvkd3d.pc
EXTRA_DIST = libs/vkd3d/libvkd3d.pc.in
2016-09-21 10:57:24 +00:00
2016-10-07 11:26:39 +00:00
LDADD = libvkd3d-utils.la
check_PROGRAMS = $(vkd3d_tests)
AM_DEFAULT_SOURCE_EXT = .c
TESTS = $(vkd3d_tests)
2016-10-13 12:08:34 +00:00
tests_d3d12_LDADD = $(LDADD) @PTHREAD_LIBS@
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-21 10:57:24 +00:00
$(widl_headers): %.h: %.idl
$(VKD3D_V_WIDL)$(WIDL) -o $@ $<
2016-09-21 10:57:24 +00: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' \
$< > $@
## Cross-compile tests
cross_implibs = crosslibs/d3d12
CROSS_CPPFLAGS = -I$(srcdir)/include -I$(srcdir)/include/private -I$(builddir)/include
2016-09-29 17:32:19 +00:00
CROSS_CFLAGS = -g -O2 -Wall -municode ${CROSS_CPPFLAGS}
EXTRA_DIST += $(cross_implibs:=.cross32.def) $(cross_implibs:=.cross64.def)
if HAS_CROSSTARGET32
CROSS32_CC = @CROSSCC32@
CROSS32_DLLTOOL = @CROSSTARGET32@-dlltool
CROSS32_IMPLIBS = $(cross_implibs:=.cross32.a)
CROSS32_EXEFILES = $(vkd3d_tests:=.cross32.exe)
CROSS32_FILES = $(CROSS32_IMPLIBS) $(CROSS32_EXEFILES)
CLEANFILES += $(CROSS32_FILES)
crosstest32: $(CROSS32_FILES)
-include tests/$(DEPDIR)/*.cross32.Po
$(CROSS32_IMPLIBS): %.cross32.a: %.cross32.def
@${MKDIR_P} crosslibs
$(AM_V_GEN)$(CROSS32_DLLTOOL) -k -m i386 --as-flags=-32 -d $< -l $@
$(CROSS32_EXEFILES): %.cross32.exe: %.c $(CROSS32_IMPLIBS) $(widl_headers)
$(AM_V_CCLD)depbase=`echo $@ | sed 's![^/]*$$!$(DEPDIR)/&!;s!\.exe$$!!'`; \
$(CROSS32_CC) $(CROSS_CFLAGS) -MT $@ -MD -MP -MF $$depbase.Tpo -o $@ $< $(CROSS32_IMPLIBS) && \
$(am__mv) $$depbase.Tpo $$depbase.Po
else
crosstest32:
endif
if HAS_CROSSTARGET64
CROSS64_CC = @CROSSCC64@
CROSS64_DLLTOOL = @CROSSTARGET64@-dlltool
CROSS64_IMPLIBS = $(cross_implibs:=.cross64.a)
CROSS64_EXEFILES = $(vkd3d_tests:=.cross64.exe)
CROSS64_FILES = $(CROSS64_IMPLIBS) $(CROSS64_EXEFILES)
CLEANFILES += $(CROSS64_FILES)
crosstest64: $(CROSS64_FILES)
-include tests/$(DEPDIR)/*.cross64.Po
$(CROSS64_IMPLIBS): %.cross64.a: %.cross64.def
@${MKDIR_P} crosslibs
$(AM_V_GEN)$(CROSS64_DLLTOOL) -k -m i386:x86-64 --as-flags=-64 -d $< -l $@
$(CROSS64_EXEFILES): %.cross64.exe: %.c $(CROSS64_IMPLIBS) $(widl_headers)
$(AM_V_CCLD)depbase=`echo $@ | sed 's![^/]*$$!$(DEPDIR)/&!;s!\.exe$$!!'`; \
$(CROSS64_CC) $(CROSS_CFLAGS) -MT $@ -MD -MP -MF $$depbase.Tpo -o $@ $< $(CROSS64_IMPLIBS) && \
$(am__mv) $$depbase.Tpo $$depbase.Po
else
crosstest64:
endif
.PHONY: crosstest crosstest32 crosstest64
crosstest: crosstest32 crosstest64