diff --git a/Clothoids.prj b/Clothoids.prj index af6c9143..a9de3fb9 100644 --- a/Clothoids.prj +++ b/Clothoids.prj @@ -1,143 +1,142 @@ - - - Clothoids - Enrico Bertolazzi - enrico.bertolazzi@unitn.it - Unversità degli Studi di Trento - Clothoids, a library for clothoids computation and more - A library for clothoids computation and more. - ${PROJECT_ROOT}/toolbox/logo.png - 2.0.3 - ${PROJECT_ROOT}/Clothoids.mltbx - - - - - b42d3f6f-9769-4fb7-a2da-cae5046d9f9f - % List files contained in your toolbox folder that you would like to exclude -% from packaging. Excludes should be listed relative to the toolbox folder. -% Some examples of how to specify excludes are provided below: -% -% A single file in the toolbox folder: -% .svn -% -% A single file in a subfolder of the toolbox folder: -% example/.svn -% -% All files in a subfolder of the toolbox folder: -% example/* -% -% All files of a certain name in all subfolders of the toolbox folder: -% **/.svn -% -% All files matching a pattern in all subfolders of the toolbox folder: -% **/*.bak -% -populate_toolbox.rb -setup.m -.DS_Store - true - - - - - ${PROJECT_ROOT}/toolbox/info.xml - ${PROJECT_ROOT}/toolbox/doc/GettingStarted.mlx - - - false - - - - - - false - true - true - true - true - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - ${PROJECT_ROOT}/toolbox - - - ${PROJECT_ROOT}/toolbox/.vscode - ${PROJECT_ROOT}/toolbox/CompileClothoidsLib.m - ${PROJECT_ROOT}/toolbox/bin - ${PROJECT_ROOT}/toolbox/demos.xml - ${PROJECT_ROOT}/toolbox/doc - ${PROJECT_ROOT}/toolbox/helptoc.xml - ${PROJECT_ROOT}/toolbox/html - ${PROJECT_ROOT}/toolbox/info.xml - ${PROJECT_ROOT}/toolbox/lib - ${PROJECT_ROOT}/toolbox/license.txt - ${PROJECT_ROOT}/toolbox/logo.png - ${PROJECT_ROOT}/toolbox/src - ${PROJECT_ROOT}/toolbox/src_mex - ${PROJECT_ROOT}/toolbox/tests - - - - - - /Users/enrico/Ricerca/develop/C++/pins-mechatronix/LibSources/submodules/Clothoids/Clothoids.mltbx - - - - /Applications/MATLAB_R2020b.app - - - - true - true - false - false - false - false - false - false - 10.15.7 - false - true - maci64 - true - - + + + Clothoids + + + Unversità degli Studi di Trento + Clothoids, a library for clothoids computation and more + A library for clothoids computation and more. + ${PROJECT_ROOT}/toolbox/logo.png + 2.0.3 + ${PROJECT_ROOT}/Clothoids.mltbx + + + + + b42d3f6f-9769-4fb7-a2da-cae5046d9f9f + % List files contained in your toolbox folder that you would like to exclude +% from packaging. Excludes should be listed relative to the toolbox folder. +% Some examples of how to specify excludes are provided below: +% +% A single file in the toolbox folder: +% .svn +% +% A single file in a subfolder of the toolbox folder: +% example/.svn +% +% All files in a subfolder of the toolbox folder: +% example/* +% +% All files of a certain name in all subfolders of the toolbox folder: +% **/.svn +% +% All files matching a pattern in all subfolders of the toolbox folder: +% **/*.bak +% +populate_toolbox.rb +setup.m +.DS_Store + true + + + + + ${PROJECT_ROOT}/toolbox/info.xml + ${PROJECT_ROOT}/toolbox/doc/GettingStarted.mlx + + + false + + + + + + false + true + true + true + true + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ${PROJECT_ROOT}/toolbox + + + ${PROJECT_ROOT}/toolbox/CompileClothoidsLib.m + ${PROJECT_ROOT}/toolbox/bin + ${PROJECT_ROOT}/toolbox/demos.xml + ${PROJECT_ROOT}/toolbox/doc + ${PROJECT_ROOT}/toolbox/helptoc.xml + ${PROJECT_ROOT}/toolbox/html + ${PROJECT_ROOT}/toolbox/info.xml + ${PROJECT_ROOT}/toolbox/lib + ${PROJECT_ROOT}/toolbox/license.txt + ${PROJECT_ROOT}/toolbox/logo.png + ${PROJECT_ROOT}/toolbox/src + ${PROJECT_ROOT}/toolbox/src_mex + ${PROJECT_ROOT}/toolbox/tests + + + + + + /home/enrico/pins-mechatronix/LibSources/submodules/Clothoids/Clothoids.mltbx + + + + /usr/local/MATLAB/R2020a + + + + true + false + false + false + false + false + true + false + 5.4.0-56-generic + false + true + glnxa64 + true + + \ No newline at end of file diff --git a/toolbox/CompileClothoidsLib.m b/toolbox/CompileClothoidsLib.m index 4b63dc37..889bfbca 100644 --- a/toolbox/CompileClothoidsLib.m +++ b/toolbox/CompileClothoidsLib.m @@ -60,15 +60,15 @@ elseif ispc end -for k=1:length(NAMES) - N=NAMES{k}; - disp('---------------------------------------------------------'); - fprintf(1,'Compiling: %s\n',N) - CMD = [CMDBASE ' -c src_mex/mex_' N '.cc' ]; - disp('---------------------------------------------------------'); - disp(CMD); - eval(CMD); -end +%for k=1:length(NAMES) +% N=NAMES{k}; +% disp('---------------------------------------------------------'); +% fprintf(1,'Compiling: %s\n',N) +% CMD = [CMDBASE ' -c src_mex/mex_' N '.cc' ]; +% disp('---------------------------------------------------------'); +% disp(CMD); +% eval(CMD); +%end LIB_OBJS = ''; for k=1:length(LIB_NAMES) @@ -85,23 +85,17 @@ eval(CMD); end -[~,mexLoaded] = inmem('-completenames'); - for k=1:length(NAMES) N=NAMES{k}; disp('---------------------------------------------------------'); - fprintf(1,'Linking: %s\n',N); + fprintf(1,'Compiling: %s\n',N); CMD = [ 'while mislocked(''' N '''); munlock(''' N '''); end;']; eval(CMD); - CMD = [ 'mex -Isrc -output bin/', N, ' -largeArrayDims mex_']; - if ispc - CMD = [ CMD, N, '.obj ', LIB_OBJS ]; - else - CMD = [ CMD, N, '.o ', LIB_OBJS ]; - end - + CMD = [ 'mex -Isrc -output bin/', N ]; + CMD = [ CMD, ' -largeArrayDims src_mex/mex_', N ]; + CMD = [ CMD, '.cc ', LIB_OBJS ]; if ismac CMD = [CMD, ' CXXFLAGS="\$CXXFLAGS -Wall -O2 -g"']; @@ -114,7 +108,7 @@ CMD = [ CMD, ... ' CXXFLAGS="\$CXXFLAGS -Wall -O2 -g"' ... ' LDFLAGS="\$LDFLAGS -static-libgcc -static-libstdc++"' ... - ' LINKLIBS="-L\$MATLABROOT/bin/\$ARCH -L\$MATLABROOT/extern/bin/\$ARCH -lMatlabDataArray -lmx -lmex -lmat -lm "' ... + ' LINKLIBS="-ldl -L\$MATLABROOT/bin/\$ARCH -L\$MATLABROOT/extern/bin/\$ARCH -lMatlabDataArray -lmx -lmex -lmat -lm "' ... ]; elseif ispc end @@ -124,9 +118,9 @@ end if isunix - delete *.o; -elseif ispc - delete *.obj; + delete *.o +else + delete *.obj end cd(old_dir); diff --git a/toolbox/src_mex/mex_BiarcListMexWrapper.cc b/toolbox/src_mex/mex_BiarcListMexWrapper.cc index 9fd584a1..ef5ef7f6 100644 --- a/toolbox/src_mex/mex_BiarcListMexWrapper.cc +++ b/toolbox/src_mex/mex_BiarcListMexWrapper.cc @@ -356,10 +356,10 @@ namespace G2lib { int nrhs, mxArray const *prhs[] ) { - #define CMD "BiarcListMexWrapper('findST1',OBJ,x,y[,ibegin,iend]): " + #define CMD "BiarcListMexWrapper('findST1',OBJ,x,y): " MEX_ASSERT2( - nrhs == 4 || nrhs == 6, - CMD "expected 4 or 6 inputs, nrhs = {}\n", nrhs + nrhs == 4, + CMD "expected 4 inputs, nrhs = {}\n", nrhs ); MEX_ASSERT2( nlhs == 3, @@ -389,17 +389,6 @@ namespace G2lib { nrx, ncx, nry, ncy ); - int64_t ibegin = 0; - int64_t iend = ptr->numSegment()-1; - if ( nrhs == 6 ) { - ibegin = getInt( - arg_in_4, CMD "`ibegin` expected to be a scalar integer" - ); - iend = getInt( - arg_in_5, CMD "`iend` expected to be a scalar integer" - ); - } - real_type * s = createMatrixValue( arg_out_0, nrx, ncx ); real_type * t = createMatrixValue( arg_out_1, nrx, ncx ); real_type * idx = createMatrixValue( arg_out_2, nrx, ncx ); diff --git a/toolbox/src_mex/mex_ClothoidListMexWrapper.cc b/toolbox/src_mex/mex_ClothoidListMexWrapper.cc index f07aa59d..c5b0df6a 100644 --- a/toolbox/src_mex/mex_ClothoidListMexWrapper.cc +++ b/toolbox/src_mex/mex_ClothoidListMexWrapper.cc @@ -797,10 +797,10 @@ namespace G2lib { int nrhs, mxArray const *prhs[] ) { - #define CMD "ClothoidListMexWrapper('findST1',OBJ,x,y[,ibegin,iend]): " + #define CMD "ClothoidListMexWrapper('findST1',OBJ,x,y): " MEX_ASSERT2( - nrhs == 4 || nrhs == 6, - CMD "expected 4 or 6 inputs, nrhs = {}\n", nrhs + nrhs == 4, + CMD "expected 4 inputs, nrhs = {}\n", nrhs ); MEX_ASSERT2( nlhs == 3, @@ -830,17 +830,6 @@ namespace G2lib { nrx, ncx, nry, ncy ); - int64_t ibegin = 0; - int64_t iend = ptr->numSegment()-1; - if ( nrhs == 6 ) { - ibegin = getInt( - arg_in_4, CMD "`ibegin` expected to be a scalar integer" - ); - iend = getInt( - arg_in_5, CMD "`iend` expected to be a scalar integer" - ); - } - real_type * s = createMatrixValue( arg_out_0, nrx, ncx ); real_type * t = createMatrixValue( arg_out_1, nrx, ncx ); real_type * idx = createMatrixValue( arg_out_2, nrx, ncx ); diff --git a/toolbox/src_mex/mex_ClothoidSplineG2MexWrapper.cc b/toolbox/src_mex/mex_ClothoidSplineG2MexWrapper.cc index fcc38392..a012524e 100644 --- a/toolbox/src_mex/mex_ClothoidSplineG2MexWrapper.cc +++ b/toolbox/src_mex/mex_ClothoidSplineG2MexWrapper.cc @@ -218,7 +218,7 @@ namespace G2lib { mwSize ntheta; real_type const * theta = getVectorPointer( arg_in_2, ntheta, CMD "Error in reading theta" ); MEX_ASSERT2( - ntheta == ptr->numPnts(), + ntheta == static_cast(ptr->numPnts()), CMD "length(theta) = {} must be {}\n", ntheta, ptr->numPnts() ); real_type f; @@ -247,7 +247,7 @@ namespace G2lib { mwSize ntheta; real_type const * theta = getVectorPointer( arg_in_2, ntheta, CMD "Error in reading theta" ); MEX_ASSERT2( - ntheta == ptr->numPnts(), + ntheta == static_cast(ptr->numPnts()), CMD "length(theta) = {} must be {}\n", ntheta, ptr->numPnts() ); double * g = createMatrixValue( arg_out_0, ntheta, 1 ); @@ -276,7 +276,7 @@ namespace G2lib { mwSize ntheta; real_type const * theta = getVectorPointer( arg_in_2, ntheta, CMD "Error in reading theta" ); MEX_ASSERT2( - ntheta == ptr->numPnts(), + ntheta == static_cast(ptr->numPnts()), CMD "length(theta) = {} must be {}\n", ntheta, ptr->numPnts() ); double * c = createMatrixValue( arg_out_0, ptr->numConstraints(), 1 ); @@ -305,7 +305,7 @@ namespace G2lib { mwSize ntheta; real_type const * theta = getVectorPointer( arg_in_2, ntheta, CMD "Error in reading theta" ); MEX_ASSERT2( - ntheta == ptr->numPnts(), + ntheta == static_cast(ptr->numPnts()), CMD "length(theta) = {} must be {}\n", ntheta, ptr->numPnts() );