X-Git-Url: https://scm.cri.ensmp.fr/git/Faustine.git/blobdiff_plain/4c9486f4df577e7227a45855745cbd8350cf4097..31089f037dce058e4bfd398bb64091522d9ba4df:/interpretor/lib/Makefile

diff --git a/interpretor/lib/Makefile b/interpretor/lib/Makefile
index 2ee772f..5c8d5ad 100644
--- a/interpretor/lib/Makefile
+++ b/interpretor/lib/Makefile
@@ -9,17 +9,14 @@ all: librairies
 
 librairies : libsndfile libsfocaml
 
-libsndfile::
-	mkdir -p $(DESTDIR)
-	cd $(LIBSNDFILE_SRCDIR) && ./configure --prefix="$(DESTDIR)" --exec_prefix="$(DESTDIR)"
-	cd $(LIBSNDFILE_SRCDIR) && make
-	cd $(LIBSNDFILE_SRCDIR) && make install
-	cd $(LIBSNDFILE_SRCDIR) && make clean
-
-libsfocaml::
+libsndfile:
+	$(MAKE) -C $(LIBSNDFILE_SRCDIR)
+	$(MAKE) -C $(LIBSNDFILE_SRCDIR) install
+
+libsfocaml:
 	cd $(LIBSFOCAML_SRCDIR) && PKG_CONFIG_PATH=$(DESTDIR)/lib/pkgconfig
-	cd $(LIBSFOCAML_SRCDIR) && make depend
-	cd $(LIBSFOCAML_SRCDIR) && make
+	$(MAKE) -C $(LIBSFOCAML_SRCDIR) depend
+	$(MAKE) -C $(LIBSFOCAML_SRCDIR)
 
 .PHONY: clean mrproper help libsndfile libsfocaml
 
@@ -28,9 +25,9 @@ help :
 	@echo "make clean : remove all object files"
 
 clean:
-	@(cd $(LIBSNDFILE_SRCDIR) && $(MAKE) clean)
 	@(rm -f *~)
 
 mrproper: clean
 	rm -rf $(DESTDIR)
-	@(cd $(LIBSFOCAML_SRCDIR) && $(MAKE) clean)
+	@($(MAKE) -C $(LIBSNDFILE_SRCDIR) clean)
+	@($(MAKE) -C $(LIBSFOCAML_SRCDIR) clean)