X-Git-Url: https://scm.cri.ensmp.fr/git/Faustine.git/blobdiff_plain/f1f94803668061f90a5ce88bf06ee72bba8e41a5..8e216a8d5f6b094308594009342e53ef122b8062:/interpretor/lib/Makefile?ds=inline diff --git a/interpretor/lib/Makefile b/interpretor/lib/Makefile index e249b40..2ee772f 100644 --- a/interpretor/lib/Makefile +++ b/interpretor/lib/Makefile @@ -1,40 +1,36 @@ -LIBSNDFILESRC := src/libsndfile-1.0.25 -prefix := libsndfile -rootdir := $(abspath .) -#TARGETDIR ?= "" -#PREFIX ?= /usr/local -#prefix := $(DESTDIR)$(PREFIX) -#arch := $(wildcard architecture/*.*) +# Faustine library dependancies Makefile. + +LIBSNDFILE_SRCDIR ?= src/libsndfile-1.0.25 +LIBSFOCAML_SRCDIR ?= src/libsndfile-ocaml +LIBSNDFILE_DESTNAME ?= libsndfile +DESTDIR := $(abspath .)/$(LIBSNDFILE_DESTNAME) all: librairies -librairies :: libsndfile -# @cp $(SNDFILE_PATH)/sndfile_stub.o $(SRC_DIR) -# @cd $(SRC_DIR) && $(MAKE) opt OCAML_INCLUDE_PATH=$(OCAML_INCLUDE_PATH) SNDFILE_PATH=$(SNDFILE_PATH) -# @cd $(SRC_DIR) && $(MAKE) clean +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 -libsndfile: - mkdir -p $(prefix) - cd $(LIBSNDFILESRC) && ./configure --prefix="$(rootdir)/$(prefix)" --exec_prefix="$(rootdir)/$(prefix)" - cd $(LIBSNDFILESRC) && make - cd $(LIBSNDFILESRC) && make install +libsfocaml:: + cd $(LIBSFOCAML_SRCDIR) && PKG_CONFIG_PATH=$(DESTDIR)/lib/pkgconfig + cd $(LIBSFOCAML_SRCDIR) && make depend + cd $(LIBSFOCAML_SRCDIR) && make -.PHONY: clean mrproper help libsndfile +.PHONY: clean mrproper help libsndfile libsfocaml help : @echo "make or make all : compile librairies" @echo "make clean : remove all object files" clean: - @(cd $(LIBSNDFILESRC) && $(MAKE) clean) + @(cd $(LIBSNDFILE_SRCDIR) && $(MAKE) clean) @(rm -f *~) mrproper: clean - @(cd $(LIBSNDFILESRC) && $(MAKE) clean) - - -# Library paths for OCaml and libsndfile-ocaml -# OCAML_INCLUDE_PATH -# SNDFILE_PATH -OCAML_INCLUDE_PATH = /usr/local/lib/ocaml -SNDFILE_PATH = /Users/karimbarkati/Boulot/2013-07-CRI/Interpretor/libsndfile-ocaml + rm -rf $(DESTDIR) + @(cd $(LIBSFOCAML_SRCDIR) && $(MAKE) clean)