mirror of
https://gitlab.com/hashborgir/d2tweaks-rnd2k.git
synced 2025-10-13 16:34:22 -05:00
Initial commit
This commit is contained in:
33
vendor/minhook/build/MinGW/Makefile
vendored
Normal file
33
vendor/minhook/build/MinGW/Makefile
vendored
Normal file
@@ -0,0 +1,33 @@
|
||||
WINDRES:=$(CROSS_PREFIX)windres
|
||||
DLLTOOL:=$(CROSS_PREFIX)dlltool
|
||||
AR:=$(CROSS_PREFIX)ar
|
||||
CC:=$(CROSS_PREFIX)gcc
|
||||
CCLD:=$(CC)
|
||||
SRCS:=$(wildcard src/*.c src/hde/*.c)
|
||||
OBJS:=$(SRCS:%.c=%.o)
|
||||
DEPS:=$(SRCS:%.c=%.d)
|
||||
INCS:=-Isrc -Iinclude
|
||||
CFLAGS:=-masm=intel -Wall -Werror -std=c11
|
||||
LDFLAGS:=-Wl,-enable-stdcall-fixup -s -static-libgcc
|
||||
|
||||
all: MinHook.dll libMinHook.dll.a libMinHook.a
|
||||
|
||||
-include $(DEPS)
|
||||
|
||||
libMinHook.a: $(OBJS)
|
||||
$(AR) r $@ $^
|
||||
libMinHook.dll.a: MinHook.dll dll_resources/MinHook.def
|
||||
$(DLLTOOL) --dllname MinHook.dll --def dll_resources/MinHook.def --output-lib $@
|
||||
MinHook.dll: $(OBJS) dll_resources/MinHook.res dll_resources/MinHook.def
|
||||
$(CCLD) -o $@ -shared $(LDFLAGS) $^
|
||||
|
||||
.rc.res:
|
||||
$(WINDRES) -o $@ --input-format=rc --output-format=coff $<
|
||||
.c.o:
|
||||
$(CC) -o $@ -c -MMD -MP $(INCS) $(CFLAGS) $<
|
||||
|
||||
clean:
|
||||
rm -f $(OBJS) $(DEPS) MinHook.dll libMinHook.dll.a libMinHook.a dll_resources/MinHook.res
|
||||
|
||||
.PHONY: clean
|
||||
.SUFFIXES: .rc .res
|
Reference in New Issue
Block a user