2 # Fuck the horse it rode in on
3 # and Fuck its little dog Libtool too
6 # Use the below line to build for PowerPC
7 # The PPC build *must* use -maltivec, even if the target is a non-altivec machine
9 #ADD_DEF= -DUGLY_IEEE754_FLOAT32_HACK=1 -maltivec -mcpu=7400
11 # use the below for x86 and most other platforms where 'float' is 32 bit IEEE754
13 #ADD_DEF= -DUGLY_IEEE754_FLOAT32_HACK=1
15 # use the below for anything without IEE754 floats (eg, VAX)
28 SRC
= main.c process.c panel.c plot.c
29 OBJ
= main.o process.o panel.o plot.o
30 GCF
= -DETCDIR
=\\\"$(ETCDIR
)\\\" `pkg-config --cflags gtk+-2.0` -DG_DISABLE_DEPRECATED
-DGDK_DISABLE_DEPRECATED
-DGTK_DISABLE_DEPRECATED
-DGDK_PIXBUF_DISABLE_DEPRECATED
33 $(MAKE
) target CFLAGS
="-O3 -ffast-math -fomit-frame-pointer $(GCF) $(ADD_DEF)"
36 $(MAKE
) target CFLAGS
="-g -Wall -W -Wno-unused-parameter -D__NO_MATH_INLINES $(GCF) $(ADD_DEF)"
39 $(MAKE
) target CFLAGS
="-pg -g -O3 -ffast-math $(GCF) $(ADD_DEF)" LIBS
="-lgprof-helper "
42 rm -f
$(OBJ
) *.d
*.d.
* gmon.out spectrum
45 rm -f spectrum-wisdomrc
48 $(CC
) -M
$(CFLAGS
) $< > $@.
$$$$; sed
's,\($*\)\.o[ :]*,\1.o $@ : ,g' < $@.
$$$$ > $@
; rm -f
$@.
$$$$
51 fftwf-wisdom
-v
-o spectrum-wisdomrc \
54 ifeq ($(MAKECMDGOALS
),target
)
58 target
: $(OBJ
) spectrum-wisdomrc
60 $(LD
) $(OBJ
) $(CFLAGS
) -o spectrum
$(LIBS
) `pkg-config --libs gtk+-2.0` -lpthread
-lfftw3f
-lm
63 $(INSTALL
) -d
-m
0755 $(BINDIR
)
64 $(INSTALL
) -m
0755 spectrum
$(BINDIR
)
65 $(INSTALL
) -d
-m
0755 $(ETCDIR
)
66 $(INSTALL
) -m
0644 spectrum-gtkrc
$(ETCDIR
)
67 $(INSTALL
) -m
0644 spectrum-wisdomrc
$(ETCDIR
)
68 # $(INSTALL) -d -m 0755 $(MANDIR)
69 # $(INSTALL) -d -m 0755 $(MANDIR)/man1
70 # $(INSTALL) -m 0644 spectrum.1 $(MANDIR)/man1