compiles OK under MAC OS X

This commit is contained in:
Mark Borgerding 2003-12-15 03:53:14 +00:00
parent 6b23ebb5c1
commit 95a7b856d1
3 changed files with 22 additions and 2 deletions

View File

@ -22,6 +22,14 @@ else
SELFTESTSRC=selftest.c
endif
ifeq "$(DATATYPE)" "float"
# fftw needs to be built with --enable-float to build this lib
FFTWLIB=fftw3f
else
FFTWLIB=fftw3
endif
all: $(BENCHKISS) $(SELFTEST) $(BENCHFFTW) $(TESTREAL)
#CFLAGS=-Wall -O3 -ansi -pedantic -march=pentiumpro -ffast-math -fomit-frame-pointer
@ -38,7 +46,7 @@ $(BENCHKISS): benchkiss.c ../kiss_fft.c pstats.c
$(CC) -o $@ $(CFLAGS) -I.. benchkiss.c $(TYPEFLAGS) ../kiss_fft.c pstats.c -lm
$(BENCHFFTW): benchfftw.c pstats.c
@$(CC) -o $@ $(CFLAGS) -DDATATYPE$(DATATYPE) benchfftw.c pstats.c -lm -lfftw3f -lfftw3 -L /usr/local/lib/ || echo "FFTW not available for comparison"
@$(CC) -o $@ $(CFLAGS) -DDATATYPE$(DATATYPE) benchfftw.c pstats.c -lm -l$(FFTWLIB) -L/usr/local/lib/ || echo "FFTW not available for comparison"
test: all
@echo "======SELF TEST $(DATATYPE)"

View File

@ -28,7 +28,11 @@ static void tms_report()
static void ps_report()
{
char buf[1024];
#ifdef __APPLE__ /* MAC OS X */
sprintf(buf,"ps -o command,majflt,minflt,rss,pagein,vsz -p %d 1>&2",getpid() );
#else /* GNU/Linux */
sprintf(buf,"ps -o comm,majflt,minflt,rss,drs,pagein,sz,trs,vsz %d 1>&2",getpid() );
#endif
system( buf );
}

View File

@ -22,6 +22,14 @@ else
SELFTESTSRC=selftest.c
endif
ifeq "$(DATATYPE)" "float"
# fftw needs to be built with --enable-float to build this lib
FFTWLIB=fftw3f
else
FFTWLIB=fftw3
endif
all: $(BENCHKISS) $(SELFTEST) $(BENCHFFTW) $(TESTREAL)
#CFLAGS=-Wall -O3 -ansi -pedantic -march=pentiumpro -ffast-math -fomit-frame-pointer
@ -38,7 +46,7 @@ $(BENCHKISS): benchkiss.c ../kiss_fft.c pstats.c
$(CC) -o $@ $(CFLAGS) -I.. benchkiss.c $(TYPEFLAGS) ../kiss_fft.c pstats.c -lm
$(BENCHFFTW): benchfftw.c pstats.c
@$(CC) -o $@ $(CFLAGS) -DDATATYPE$(DATATYPE) benchfftw.c pstats.c -lm -lfftw3f -lfftw3 -L /usr/local/lib/ || echo "FFTW not available for comparison"
@$(CC) -o $@ $(CFLAGS) -DDATATYPE$(DATATYPE) benchfftw.c pstats.c -lm -l$(FFTWLIB) -L/usr/local/lib/ || echo "FFTW not available for comparison"
test: all
@echo "======SELF TEST $(DATATYPE)"