# Copyright 2024 Collabora Ltd.
# SPDX-License-Identifier: Zlib

all:

CXXFLAGS += -std=c++17
PKG_CONFIG ?= pkg-config

all: test_native_d3d9
all: test_native_d3d11

test_native_d3d9: %: %.cpp Makefile
	$(CXX) $(CXXFLAGS) $(LDFLAGS) -o$@ \
		$< \
		-DDXVK_WSI_SDL2 \
		`$(PKG_CONFIG) --cflags --libs dxvk-d3d9 sdl2`

test_native_d3d11: %: %.cpp Makefile
	$(CXX) $(CXXFLAGS) $(LDFLAGS) -o$@ \
		$< \
		-DDXVK_WSI_SDL3 \
		`$(PKG_CONFIG) --cflags --libs dxvk-d3d11 sdl3`
