aboutsummaryrefslogtreecommitdiffstats
path: root/icepack/Makefile
blob: 65d4c9a5fa45a5898580a04b0664556d47cae107 (plain)
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
35
36
37
include ../config.mk
MXEGCC = /usr/local/src/mxe/usr/bin/i686-pc-mingw32-gcc

ifeq ($(STATIC),1)
LDFLAGS += -static
endif

all: icepack$(EXE) iceunpack$(EXE)

icepack$(EXE): icepack.o
	$(CXX) -o $@ $(LDFLAGS) $^ $(LDLIBS)

iceunpack: icepack
	ln -sf icepack iceunpack

iceunpack.exe:
	# no iceunpack.exe, use icepack -u

install: all
	mkdir -p $(DESTDIR)$(PREFIX)/bin
	cp icepack$(EXE) $(DESTDIR)$(PREFIX)/bin/icepack$(EXE)
	ln -sf icepack$(EXE) $(DESTDIR)$(PREFIX)/bin/iceunpack$(EXE)

uninstall:
	rm -f $(DESTDIR)$(PREFIX)/bin/icepack$(EXE)
	rm -f $(DESTDIR)$(PREFIX)/bin/iceunpack$(EXE)

clean:
	rm -f icepack
	rm -f iceunpack
	rm -f icepack.exe
	rm -f *.o *.d

-include *.d

.PHONY: all install uninstall clean