[go: up one dir, main page]

Menu

[d6a55f]: / Makefile.mingw  Maximize  Restore  History

Download this file

36 lines (25 with data), 820 Bytes

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
# GNU Makefile for vispatch windows binaries using GCC (MinGW).
CC ?= gcc
WINDRES ?= windres
OBJECTS:= utilslib.o \
strlcat.o \
strlcpy.o \
vispatch.o \
vispatch.res
OPTIMIZATIONS= -O2
CFLAGS = -g -Wall -W -Wshadow -DWIN32_LEAN_AND_MEAN $(OPTIMIZATIONS)
LDFLAGS= -mconsole
all: vispatch.exe
.c.o:
$(CC) $(CFLAGS) -c $*.c
# the program name is vispatch.exe and "patch" keyword is red-flagged
# by Windows Vista and newer to trigger UAC for X86 applications.
# So we need a manifest to set requestedExecutionLevel as "asInvoker"
# and uiAccess as "false". Not needed for AMD64, but doesn't hurt,
# either.
vispatch.res: vispatch.rc vispatch.exe.manifest
$(WINDRES) -DWIN32_LEAN_AND_MEAN --output-format=coff -o $@ $<
vispatch.exe: $(OBJECTS)
$(CC) -o $@ $(OBJECTS) $(LDFLAGS)
clean:
rm -f *.o *.res *.d