summaryrefslogtreecommitdiffstats
path: root/build
diff options
context:
space:
mode:
authorWillem Jan Palenstijn <Willem.Jan.Palenstijn@cwi.nl>2016-11-22 09:45:51 +0100
committerWillem Jan Palenstijn <Willem.Jan.Palenstijn@cwi.nl>2016-11-22 09:45:51 +0100
commitbb01a88b5176c13c6881489887ec789dd10849a0 (patch)
tree164bf569d41d0bb516a0c5a78d6558a032efcdb1 /build
parent7e10c16eee71c608a1dba1dd2fec8471567f6b61 (diff)
downloadastra-bb01a88b5176c13c6881489887ec789dd10849a0.tar.gz
astra-bb01a88b5176c13c6881489887ec789dd10849a0.tar.bz2
astra-bb01a88b5176c13c6881489887ec789dd10849a0.tar.xz
astra-bb01a88b5176c13c6881489887ec789dd10849a0.zip
Build astra_mex_plugin for octave
Diffstat (limited to 'build')
-rw-r--r--build/linux/Makefile.in23
1 files changed, 18 insertions, 5 deletions
diff --git a/build/linux/Makefile.in b/build/linux/Makefile.in
index 1c7088e..ecc3903 100644
--- a/build/linux/Makefile.in
+++ b/build/linux/Makefile.in
@@ -117,6 +117,12 @@ OCTFLAGS=-DASTRA_CUDA
else
OCTFLAGS=
endif
+ifeq ($(python),yes)
+OCTPYLIBS=-l$(PYLIBVER)
+else
+OCTPYLIBS=
+endif
+
endif
DEPDIR=.deps
@@ -270,10 +276,6 @@ MATLAB_MEX=\
matlab/mex/astra_mex_data3d_c.$(MEXSUFFIX) \
matlab/mex/astra_mex_direct_c.$(MEXSUFFIX)
-ifeq ($(python),yes)
-MATLAB_MEX+=matlab/mex/astra_mex_plugin_c.$(MEXSUFFIX)
-endif
-
OCTAVE_CXX_OBJECTS=\
matlab/mex/octave_support.o
@@ -288,6 +290,12 @@ OCTAVE_MEX=\
matlab/mex/astra_mex_data3d_c.mex \
matlab/mex/astra_mex_direct_c.mex
+ifeq ($(python),yes)
+MATLAB_MEX+=matlab/mex/astra_mex_plugin_c.$(MEXSUFFIX)
+OCTAVE_MEX+=matlab/mex/astra_mex_plugin_c.mex
+endif
+
+
OBJECT_DIRS = src/ tests/ cuda/2d/ cuda/3d/ matlab/mex/ ./
DEPDIRS = $(addsuffix $(DEPDIR),$(OBJECT_DIRS))
-include $(wildcard $(addsuffix /*.d,$(DEPDIRS)))
@@ -323,7 +331,12 @@ ifeq ($(octave),yes)
oct: $(OCTAVE_MEX)
%.mex: %.o $(MATLAB_CXX_OBJECTS) $(OCTAVE_CXX_OBJECTS) libastra.la
- mkoctfile --mex $(OCTFLAGS) $(OCTLDFLAGS) $(LIBS) -L.libs -lastra --output $* $*.o $(MATLAB_CXX_OBJECTS) $(OCTAVE_CXX_OBJECTS)
+ mkoctfile --mex $(OCTFLAGS) $(OCTLDFLAGS) $(LIBS) -lastra --output $* $*.o $(MATLAB_CXX_OBJECTS) $(OCTAVE_CXX_OBJECTS)
+
+ifeq ($(python),yes)
+matlab/mex/astra_mex_plugin_c.mex: matlab/mex/astra_mex_plugin_c.o $(MATLAB_CXX_OBJECTS) $(OCTAVE_CXX_OBJECTS) libastra.la
+ mkoctfile --mex $(OCTFLAGS) $(OCTLDFLAGS) $(LIBS) $(OCTPYLIBS) -lastra --output matlab/mex/astra_mex_plugin_c $< $(MATLAB_CXX_OBJECTS) $(OCTAVE_CXX_OBJECTS)
+endif
endif
libastra.la: $(ALL_OBJECTS)