-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmake.m
More file actions
22 lines (22 loc) · 888 Bytes
/
make.m
File metadata and controls
22 lines (22 loc) · 888 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
% This make.m is for MATLAB and OCTAVE under Windows, Mac, and Unix
function make()
try
% This part is for OCTAVE
if (exist ('OCTAVE_VERSION', 'builtin'))
mex libsvmread.c
mex libsvmwrite.c
mex -I.. svmtrain.c ../svm.cpp svm_model_matlab.c
mex -I.. svmpredict.c ../svm.cpp svm_model_matlab.c
% This part is for MATLAB
% Add -largeArrayDims on 64-bit machines of MATLAB
else
mex CFLAGS="\$CFLAGS -std=c99" -largeArrayDims libsvmread.c
mex CFLAGS="\$CFLAGS -std=c99" -largeArrayDims libsvmwrite.c
mex CFLAGS="\$CFLAGS -std=c99" -I.. -largeArrayDims svmtrain.c ../svm.cpp svm_model_matlab.c
mex CFLAGS="\$CFLAGS -std=c99" -I.. -largeArrayDims svmpredict.c ../svm.cpp svm_model_matlab.c
end
catch err
fprintf('Error: %s failed (line %d)\n', err.stack(1).file, err.stack(1).line);
disp(err.message);
fprintf('=> Please check README for detailed instructions.\n');
end