forked from ibphoenix/tomsfastmath
makefile: rework a bit
This commit is contained in:
parent
03334b30b4
commit
0b1ad14d7b
41
makefile
41
makefile
@ -97,9 +97,11 @@ install: $(LIBNAME)
|
|||||||
install -g $(GROUP) -o $(USER) $(LIBNAME) $(DESTDIR)$(LIBPATH)
|
install -g $(GROUP) -o $(USER) $(LIBNAME) $(DESTDIR)$(LIBPATH)
|
||||||
install -g $(GROUP) -o $(USER) $(HEADERS) $(DESTDIR)$(INCPATH)
|
install -g $(GROUP) -o $(USER) $(HEADERS) $(DESTDIR)$(INCPATH)
|
||||||
|
|
||||||
mtest/mtest: mtest/mtest.o
|
.PHONY: mtest
|
||||||
cd mtest ; CC=$(CC) CFLAGS="$(CFLAGS) -I../" MAKE=${MAKE} ${MAKE} mtest
|
mtest: $(LIBNAME)
|
||||||
|
cd mtest; CC="$(CC)" CFLAGS="$(CFLAGS) -I../" MAKE=${MAKE} ${MAKE} mtest
|
||||||
|
|
||||||
|
.PHONY: test
|
||||||
test: $(LIBNAME) demo/test.o
|
test: $(LIBNAME) demo/test.o
|
||||||
$(CC) $(CFLAGS) demo/test.o $(LIBNAME) $(PROF) -o test
|
$(CC) $(CFLAGS) demo/test.o $(LIBNAME) $(PROF) -o test
|
||||||
|
|
||||||
@ -107,10 +109,10 @@ timing: $(LIBNAME) demo/test.o
|
|||||||
$(CC) $(CFLAGS) demo/test.o $(LIBNAME) $(PROF) -o test
|
$(CC) $(CFLAGS) demo/test.o $(LIBNAME) $(PROF) -o test
|
||||||
|
|
||||||
profiled:
|
profiled:
|
||||||
CC=$(CC) PREFIX="${PREFIX} CFLAGS="${CFLAGS} -fprofile-generate" MAKE=${MAKE} ${MAKE} timing
|
CC="$(CC)" PREFIX="${PREFIX} CFLAGS="${CFLAGS} -fprofile-generate" MAKE=${MAKE} ${MAKE} timing
|
||||||
./test
|
./test
|
||||||
rm -f `find . -type f | grep "[.]o" | xargs`
|
rm -f `find . -type f -name "*.o" | xargs`
|
||||||
rm -f `find . -type f | grep "[.]a" | xargs`
|
rm -f `find . -type f -name "*.a" | xargs`
|
||||||
rm -f test
|
rm -f test
|
||||||
CC=$(CC) PREFIX="${PREFIX} CFLAGS="${CFLAGS} -fprofile-use" MAKE=${MAKE} ${MAKE} timing
|
CC=$(CC) PREFIX="${PREFIX} CFLAGS="${CFLAGS} -fprofile-use" MAKE=${MAKE} ${MAKE} timing
|
||||||
|
|
||||||
@ -135,20 +137,21 @@ docs: docdvi
|
|||||||
#This rule cleans the source tree of all compiled code, not including the pdf
|
#This rule cleans the source tree of all compiled code, not including the pdf
|
||||||
#documentation.
|
#documentation.
|
||||||
clean:
|
clean:
|
||||||
rm -f `find . -type f | grep "[.]o" | xargs`
|
rm -f `find . -type f -name "*.o" | xargs`
|
||||||
rm -f `find . -type f | grep "[.]lo" | xargs`
|
rm -f `find . -type f -name "*.lo" | xargs`
|
||||||
rm -f `find . -type f | grep "[.]a" | xargs`
|
rm -f `find . -type f -name "*.a" | xargs`
|
||||||
rm -f `find . -type f | grep "[.]la" | xargs`
|
rm -f `find . -type f -name "*.la" | xargs`
|
||||||
rm -f `find . -type f | grep "[.]obj" | xargs`
|
rm -f `find . -type f -name "*.obj" | xargs`
|
||||||
rm -f `find . -type f | grep "[.]lib" | xargs`
|
rm -f `find . -type f -name "*.lib" | xargs`
|
||||||
rm -f `find . -type f | grep "[.]exe" | xargs`
|
rm -f `find . -type f -name "*.exe" | xargs`
|
||||||
rm -f `find . -type f | grep "[.]gcda" | xargs`
|
rm -f `find . -type f -name "*.gcov" | xargs`
|
||||||
rm -f `find . -type f | grep "[.]gcno" | xargs`
|
rm -f `find . -type f -name "*.gcda" | xargs`
|
||||||
rm -f `find . -type f | grep "[.]il" | xargs`
|
rm -f `find . -type f -name "*.gcno" | xargs`
|
||||||
rm -f `find . -type f | grep "[.]dyn" | xargs`
|
rm -f `find . -type f -name "*.il" | xargs`
|
||||||
rm -f `find . -type f | grep "[.]dpi" | xargs`
|
rm -f `find . -type f -name "*.dyn" | xargs`
|
||||||
rm -rf `find . -type d | grep "[.]libs" | xargs`
|
rm -f `find . -type f -name "*.dpi" | xargs`
|
||||||
rm -f tfm.aux tfm.dvi tfm.idx tfm.ilg tfm.ind tfm.lof tfm.log tfm.toc test mtest/mtest
|
rm -rf `find . -type d -name "*.libs" | xargs`
|
||||||
|
rm -f tfm.aux tfm.dvi tfm.idx tfm.ilg tfm.ind tfm.lof tfm.log tfm.toc test test.exe
|
||||||
cd mtest; MAKE=${MAKE} ${MAKE} clean
|
cd mtest; MAKE=${MAKE} ${MAKE} clean
|
||||||
|
|
||||||
no_oops: clean
|
no_oops: clean
|
||||||
|
Loading…
Reference in New Issue
Block a user