File: Makefile

package info (click to toggle)
aeolus 0.8.1-1
  • links: PTS
  • area: main
  • in suites: lenny
  • size: 492 kB
  • ctags: 1,426
  • sloc: cpp: 8,564; makefile: 59
file content (85 lines) | stat: -rw-r--r-- 2,803 bytes parent folder | download
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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
#  Copyright (C) 2003-2008 Fons Adriaensen <fons@kokkinizita.net>
#
#  This program is free software; you can redistribute it and/or modify
#  it under the terms of the GNU General Public License as published by
#  the Free Software Foundation; either version 2 of the License, or
#  (at your option) any later version.
#
#  This program is distributed in the hope that it will be useful,
#  but WITHOUT ANY WARRANTY; without even the implied warranty of
#  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
#  GNU General Public License for more details.

#  You should have received a copy of the GNU General Public License
#  along with this program; if not, write to the Free Software
#  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.


PREFIX = /usr/local
SUFFIX := $(shell uname -m | sed -e 's/^unknown/$//' -e 's/^i.86/$//' -e 's/^x86_64/$/64/')
LIBDIR = lib$(SUFFIX)
VERSION = 0.8.1
DISTDIR = aeolus-$(VERSION)
CPPFLAGS += -O3 -Wall -MMD -MP -DVERSION=\"$(VERSION)\" -DLIBDIR=\"$(PREFIX)/$(LIBDIR)\"
#CPPFLAGS += -march=pentium4

all:	aeolus aeolus_x11.so aeolus_txt.so


AEOLUS_O =	main.o audio.o model.o slave.o imidi.o addsynth.o scales.o \
		reverb.o asection.o division.o rankwave.o rngen.o exp2ap.o lfqueue.o
aeolus:	LDLIBS += -lclalsadrv -lclthreads -lpthread -ljack -lasound -lpthread -lrt
aeolus: LDFLAGS += -L$(PREFIX)/$(LIBDIR)
aeolus:	$(AEOLUS_O)
	g++ $(LDFLAGS) -o $@ $(AEOLUS_O) $(LDLIBS)

addsynth.o:	CPPFLAGS += -fpic -D_REENTRANT
$(AEOLUS_O):
-include $(AEOLUS_O:%.o=%.d)


XIFACE_O =	styles.o mainwin.o midiwin.o audiowin.o instrwin.o editwin.o midimatrix.o \
		multislider.o functionwin.o xiface.o addsynth.o
aeolus_x11.so:	CPPFLAGS += -fpic -D_REENTRANT -I/usr/X11R6/include -I/usr/include/freetype2
aeolus_x11.so:	LDLIBS += -lclthreads -lclxclient -lXft -lX11
aeolus_x11.so:	LDFLAGS += -shared -L$(PREFIX)/$(LIBDIR) -L/usr/X11R6/$(LIBDIR)
aeolus_x11.so: $(XIFACE_O) $(LIBCLX)
	g++ $(LDFLAGS) -o $@ $(XIFACE_O) $(LDLIBS)

$(XIFACE_O):
-include $(XIFACE_O:%.o=%.d)



TIFACE_O =	tiface.o
aeolus_txt.so:	CPPFLAGS += -fpic -D_REENTRANT
aeolus_txt.so:	LDLIBS += -lclthreads
aeolus_txt.so:	LDFLAGS += -shared -L$(PREFIX)/$(LIBDIR)
aeolus_txt.so: $(TIFACE_O)
	g++ $(LDFLAGS) -o $@ $(TIFACE_O) $(LDLIBS)

$(TIFACE_O):
-include $(TIFACE_O:%.o=%.d)



install:	aeolus aeolus_x11.so aeolus_txt.so 
	/usr/bin/install -d $(PREFIX)/$(LIBDIR)
	/usr/bin/install -m 755 aeolus $(PREFIX)/bin
	/usr/bin/install -m 755 aeolus_x11.so $(PREFIX)/$(LIBDIR)
	/usr/bin/install -m 755 aeolus_txt.so $(PREFIX)/$(LIBDIR)
	/sbin/ldconfig $(PREFIX)/$(LIBDIR)

clean:
	/bin/rm -f *~ *.o *.d *.a *.so aeolus


tarball:
	cd ..; \
	/bin/rm -f -r $(DISTDIR)*; \
	svn export aeolus $(DISTDIR); \
	tar cvf $(DISTDIR).tar $(DISTDIR); \
	bzip2 $(DISTDIR).tar; \
	/bin/rm -f -r $(DISTDIR);