Mercurial > hg > plml
annotate cpp/Makefile @ 6:d3b9cbaee77b
Added Makefile to install Matlab components.
author | samer |
---|---|
date | Thu, 19 Jan 2012 14:28:39 +0000 |
parents | 9b16fbec2f33 |
children | 193d582746e5 |
rev | line source |
---|---|
samer@0 | 1 # This will not work as a stand-alone make file - it must be |
samer@0 | 2 # called recursively from the make file in the directory above. |
samer@0 | 3 |
samer@0 | 4 TARGET=plml.$(SO) |
samer@0 | 5 INCML=$(MATLAB)/extern/include |
samer@0 | 6 LIBML=$(MATLAB)/bin/$(MLARCH) |
samer@3 | 7 PLLDFLAGS=-c++ g++-4.2 $(INCLUDES) -I$(INCML) -Wall |
samer@0 | 8 |
samer@0 | 9 .SUFFIXES: .cpp .o .so .dylib |
samer@0 | 10 |
samer@0 | 11 main: $(TARGET) |
samer@0 | 12 |
samer@0 | 13 clean: |
samer@0 | 14 rm $(TARGET) |
samer@0 | 15 |
samer@0 | 16 .cpp.so: |
samer@0 | 17 $(PLLD) -v $(PLLDFLAGS) -L$(LIBML) -shared $(MLLIBS) -o $@ $< |
samer@0 | 18 strip -x $@ |
samer@0 | 19 |
samer@0 | 20 .cpp.dylib: |
samer@0 | 21 $(PLLD) -v $(PLLDFLAGS) -L$(LIBML) -shared $(MLLIBS) -o $@ $< |
samer@0 | 22 strip -x $@ |
samer@0 | 23 |
samer@0 | 24 install: |
samer@0 | 25 install -d $(INSTALL_LIB_TO) |
samer@0 | 26 install $(INSTALL_FLAGS) $(TARGET) $(INSTALL_LIB_TO) |
samer@0 | 27 |