From 6236225ce6bcb9ca09e32afda73fa53f6bf2ac9a Mon Sep 17 00:00:00 2001 From: Zack Buhman Date: Tue, 13 Jan 2026 14:20:03 -0600 Subject: [PATCH] fix Windows build on Windows --- Makefile | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index ad19699..972d564 100644 --- a/Makefile +++ b/Makefile @@ -8,6 +8,7 @@ OPT = -g -Og CXXSTD += -std=gnu++14 +CFLAGS += -march=core2 CFLAGS += -Wall -Werror -Wfatal-errors CFLAGS += -Wno-unused-but-set-variable CFLAGS += -Wno-unknown-pragmas @@ -17,14 +18,16 @@ CFLAGS += -municode WOPT += -municode -FXC ?= C:/Program Files (x86)/Microsoft DirectX SDK (June 2010)/Utilities/bin/x86/fxc.exe - INCLUDE = \ -I./include %.fxo: %.fx +ifeq ($(OS),Windows_NT) + fxc.exe @"shader_$(BUILD_TYPE).rsp" /T fx_4_0 /nologo /Fo $@ $< +else @echo fxc.exe @"shader_$(BUILD_TYPE).rsp" /T fx_4_0 /nologo /Fo $@ $< - @wine "$(FXC)" @"shader_$(BUILD_TYPE).rsp" /T fx_4_0 /nologo /Fo $@ $< + @wine fxc.exe @"shader_$(BUILD_TYPE).rsp" /T fx_4_0 /nologo /Fo $@ $< +endif SHADERS = \ main.fxo \