--- rpl/Makefile.am 2013/02/23 12:39:44 1.60 +++ rpl/Makefile.am 2013/03/04 09:48:19 1.63 @@ -25,21 +25,30 @@ licences: cp -f $(top_builddir)/COPYING $(srcdir) $(MAKE) -C src $@ -toolsdistclean: +purge: for i in @NCURSES@ @READLINE@ @UNITS@ @GSL@ @GPP@ @GNUPLOT_COMPILATION@ \ @FILE@ @ICONV@ @SQLITE@ @SIGSEGV@ @BUILD_OPENMOTIF@; \ do \ rm -rf $(srcdir)/tools/$$i; \ + rm -rf $(top_builddir)/tools/$$i; \ done; - rm -f $(top_builddir)/tools/openmotif.lib - rm -rf $(top_builddir)/tools/@OPENSSL@ - -toolsclean: - for i in @NCURSES@ @READLINE@ @UNITS@ @GSL@ @GPP@ @GNUPLOT_COMPILATION@ \ - @FILE@ @ICONV@ @SQLITE@ @SIGSEGV@ @BUILD_OPENMOTIF@; \ + for i in @GMP@ @MPFR@ @NTL@ @COCOA@ @PARI@ @GIAC@; \ do \ - $(MAKE) -C $(top_builddir)/tools/$$i $(AM_MAKEFLAGS) clean); \ + if [ -d $(srcdir)/rplcas/$$i ]; then \ + rm -rf $(srcdir)/rplcas/$$i; \ + fi; \ + if [ -d $(top_builddir)/rplcas/$$i ]; then \ + rm -rf $(top_builddir)/rplcas/$$i; \ + fi; \ done; + for i in bin lib include share; \ + do \ + if [ -d $(top_builddir)/rplcas/$$i ]; then \ + rm -rf $(top_builddir)/rplcas/$$i; \ + fi; \ + done; + rm -f $(top_builddir)/tools/openmotif.lib + rm -rf $(top_builddir)/tools/@OPENSSL@ $(top_builddir)/tools/@NCURSES@/lib/@LIB_PREFIX@ncurses.a: for i in $(shell find tools/@NCURSES@ -name Makefile \ @@ -219,13 +228,15 @@ $(top_builddir)/tools/@GPP@/src/gpp$(EXE $(MAKE) -C $(top_builddir)/tools/@GPP@ $(AM_MAKEFLAGS) $(top_builddir)/tools/@UNITS@/units$(EXEEXT): - if [ $$subdir = @UNITS@ -a @OS@ = OpenBSD ]; then \ + if [ @OS@ = OpenBSD ]; then \ TMP=tmp.units; \ sed -e 's/^DEFS = -DUNITSFILE/DEFS = -Dmalloc=malloc -DUNITSFILE/g' \ @UNITS@/Makefile > $$TMP; \ mv -f $$TMP @UNITS@/Makefile; \ fi; \ - cp -f $(srcdir)/tools/@UNITS@/units_cur $(top_builddir)/tools/@UNITS@ + if [ x$(srcdir) != x$(top_builddir) ]; then \ + cp -f $(srcdir)/tools/@UNITS@/units_cur $(top_builddir)/tools/@UNITS@; \ + fi $(MAKE) -C $(top_builddir)/tools/@UNITS@ $(AM_MAKEFLAGS) .NOTPARALLEL: $(top_builddir)/tools/@FILE@/src/rplfile$(EXEEXT) \