source: trunk/Apps/Graphics/Sources/xynth/Makefile

Last change on this file was 498, checked in by khorben, 8 years ago

Fixed the download URL

File size: 1.9 KB
Line 
1PACKAGE = xynth
2VERSION = 0.8.90
3DESTDIR =
4PREFIX  = /usr/local
5TARGETS = $(PACKAGE)-$(VERSION)/.build-done
6HOST    = `uname -m | tr A-Z a-z`--`uname -s | tr A-Z a-z`
7CPPFLAGS= -nostdinc -isystem $(DESTDIR)$(PREFIX)/include
8CFLAGS  = -ffreestanding
9LDFLAGS = -nostdlib -fPIC -L$(DESTDIR)$(PREFIX)/lib -Wl,-rpath-link,$(DESTDIR)$(PREFIX)/lib -Wl,-lc -Wl,-lm -Wl,-lpthread -Wl,-lsocket -Wl,-lgetopt -Wl,-lgcc -Wl,$(DESTDIR)$(PREFIX)/lib/start.o
10FETCH   = wget --continue
11RM      = rm -f
12TAR     = tar
13TOUCH   = touch
14ARCHIVE = $(PACKAGE)-$(VERSION).tar.bz2
15MIRROR  = http://sourceforge.net/projects/$(PACKAGE)/files/$(PACKAGE)-$(VERSION)
16URL     = $(MIRROR)/$(ARCHIVE)/download
17
18all: $(TARGETS)
19
20configure: $(PACKAGE)-$(VERSION)/.configure-done
21
22download: .download-done
23
24extract: $(PACKAGE)-$(VERSION)/.extract-done
25
26install: $(TARGETS)
27        (cd $(PACKAGE)-$(VERSION) && $(MAKE) V=1 CC="$(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS)" _INSTALLDIR="$(PREFIX)")
28        (cd $(PACKAGE)-$(VERSION) && $(MAKE) V=1 _INSTALLDIR="$(DESTDIR)$(PREFIX)" $@)
29
30patch: $(PACKAGE)-$(VERSION)/.patch-done
31
32uninstall:
33        (cd $(PACKAGE)-$(VERSION) && $(MAKE) $@)
34
35clean:
36        if [ -f $(PACKAGE)-$(VERSION)/Makefile ]; then \
37                (cd $(PACKAGE)-$(VERSION) && $(MAKE) $@); \
38        fi
39        $(RM) $(TARGETS)
40
41distclean:
42        $(RM) .download-done
43        $(RM) -r $(PACKAGE)-$(VERSION)
44
45.download-done:
46        $(FETCH) -O $(ARCHIVE) $(URL)
47        $(TOUCH) $@
48
49$(PACKAGE)-$(VERSION)/.extract-done: .download-done
50        $(TAR) -xjvf $(ARCHIVE)
51        $(TOUCH) $@
52
53$(PACKAGE)-$(VERSION)/.patch-done: $(PACKAGE)-$(VERSION)/.extract-done
54        for i in patches/*; do \
55                [ -f "$$i" ] && patch -p0 < "$$i"; \
56        done; \
57        $(TOUCH) $@
58
59$(PACKAGE)-$(VERSION)/.configure-done: $(PACKAGE)-$(VERSION)/.patch-done
60        $(TOUCH) $@
61
62$(PACKAGE)-$(VERSION)/.build-done: $(PACKAGE)-$(VERSION)/.configure-done
63        (cd $(PACKAGE)-$(VERSION) && $(MAKE) V=1 CC="$(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS)" _INSTALLDIR="$(PREFIX)")
64        $(TOUCH) $@
65
66.PHONY: all clean configure distclean download extract install patch uninstall
Note: See TracBrowser for help on using the repository browser.