-
Notifications
You must be signed in to change notification settings - Fork 3
/
mex_CUDA_glnxa64.xml
73 lines (68 loc) · 2.82 KB
/
mex_CUDA_glnxa64.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
<?xml version="1.0" encoding="UTF-8" ?>
<!-- Copyright 2013 The MathWorks, Inc. -->
<config
Name="nvcc"
ShortName="nvcc"
Manufacturer="NVIDIA"
Version=""
Language="CUDA"
Priority="A"
Location="$NVCC" >
<Details
CompilerExecutable="$CXX"
CompilerDefines="$DEFINES"
CompilerFlags="$CXXFLAGS"
OptimizationFlags="$CXXOPTIMFLAGS"
DebugFlags="$CXXDEBUGFLAGS"
IncludeFlags="$INCLUDE"
LinkerLibraries="$LINKLIBS"
LinkerOptimizationFlags="$LDOPTIMFLAGS"
LinkerDebugFlags="$LDDEBUGFLAGS"
CompilerDefineFormatter="-D%s"
LinkerLibrarySwitchFormatter="-l%s"
LinkerPathFormatter="-L%s"
/>
<vars
CMDLINE1="$CXX -c $DEFINES $INCLUDE $NVCCFLAGS $CXXFLAGS $OPTIM $SRC -o $OBJ"
CMDLINE2="$LDXX $LDFLAGS $LDTYPE $LINKOPTIM $LINKEXPORT $OBJS $CXXLIBS $LINKLIBS -o $EXE"
CMDLINE3="rm -f $OBJ"
CXX="$NVCC"
DEFINES="--compiler-options=-D_GNU_SOURCE,$MATLABMEX"
MATLABMEX="-DMATLAB_MEX_FILE"
NVCCFLAGS=" -gencode arch=compute_60,code=sm_60 -gencode arch=compute_61,code=sm_61 $NVCC_FLAGS"
CXXFLAGS="--compiler-options=-ansi,-fexceptions,-fPIC,-fno-omit-frame-pointer,-pthread"
INCLUDE="-I"$MATLABROOT/extern/include" -I"$MATLABROOT/simulink/include" -I"$MATLABROOT/toolbox/distcomp/gpu/extern/include/""
CXXOPTIMFLAGS="-O -DNDEBUG"
CXXDEBUGFLAGS="-g"
LDXX="$GCC"
LDFLAGS="-pthread -Wl,--no-undefined "
LDTYPE="-shared"
LINKEXPORT="-Wl,--version-script,"$MATLABROOT/extern/lib/$ARCH/mexFunction.map""
LINKLIBS="-Wl,-rpath-link,$MATLABROOT/bin/$ARCH -L"$MATLABROOT/bin/$ARCH" -lmx -lmex -lmat -lm -lcudart -L"/usr/local/cuda/lib64""
LDDEBUGFLAGS="-g"
OBJEXT=".o"
LDEXT=".mexa64">
</vars>
<client>
</client>
<locationFinder>
<NVCC>
<or>
<and>
<envVarExists name="MW_NVCC_PATH" />
<dirExists name="$$" />
<fileExists name="$$/nvcc" />
</and>
<cmdReturns name="which nvcc" />
<fileExists name="/usr/local/cuda/bin/nvcc" />
</or>
</NVCC>
<GCC>
<cmdReturns name="which g++" />
</GCC>
<CPPLIB_DIR>
<cmdReturns name="g++ -print-file-name=libstdc++.so"
diagnostic="GCC appears to be installed, but supporting C++ libraries were not found. You must first install the gcc-c++ package, or similiar, to complete this action."/>
</CPPLIB_DIR>
</locationFinder>
</config>