Skip to content

Commit

Permalink
tenporaneo
Browse files Browse the repository at this point in the history
  • Loading branch information
ebertolazzi committed Apr 6, 2022
1 parent 721a051 commit d69471f
Show file tree
Hide file tree
Showing 7 changed files with 20 additions and 5 deletions.
Empty file modified toolbox/bin/BaseHermiteMexWrapper.m
100755 → 100644
Empty file.
Empty file modified toolbox/bin/Spline1DMexWrapper.m
100755 → 100644
Empty file.
Empty file modified toolbox/bin/Spline2DMexWrapper.m
100755 → 100644
Empty file.
Empty file modified toolbox/bin/SplineSetMexWrapper.m
100755 → 100644
Empty file.
Empty file modified toolbox/bin/SplineVecMexWrapper.m
100755 → 100644
Empty file.
14 changes: 11 additions & 3 deletions toolbox/lib/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,14 @@ endforeach()

include_directories( ${CMAKE_CURRENT_SOURCE_DIR}/../src ${CMAKE_CURRENT_SOURCE_DIR}/../src/Utils )

if ( (UNIX OR LINUX) AND NOT APPLE )
set(CMAKE_EXE_LINKER_FLAGS "-static-libgcc -static-libstdc++")
set(CMAKE_SHARED_LINKER_FLAGS "-static-libgcc -static-libstdc++")
if ( UNIX OR LINUX )
if ( NOT APPLE )
set(CMAKE_EXE_LINKER_FLAGS "-static-libgcc -static-libstdc++")
set(CMAKE_SHARED_LINKER_FLAGS "-static-libgcc -static-libstdc++")
endif()
else()
#set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -mwindows")
add_definitions(-mwindows)
endif()

set( MEX_LIST BaseHermite Spline1D Spline2D SplineSet SplineVec )
Expand All @@ -37,4 +42,7 @@ foreach( BASE ${MEX_LIST})
"$<TARGET_FILE:${BASE}MexWrapper>"
"${CMAKE_CURRENT_SOURCE_DIR}/../bin"
)

target_link_libraries( ${BASE}MexWrapper ws2_32.lib iphlpapi.lib iphlpapi.lib kernel32.lib winpthread )

endforeach()
11 changes: 9 additions & 2 deletions toolbox/lib/CompileSplinesLib_cmake.m
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,14 @@
end

old_dir = cd(fileparts(which(mfilename)));
system('cmake -Bbuild .');
system('cmake --build build --parallel 8');
%system('rmdir /S build');
if isunix
system('cmake -Bbuild .');
system('cd build; make -j 10; cd ..');
elseif ispc
system('cmake -G "MinGW Makefiles" -DCMAKE_VERBOSE_MAKEFILE:BOOL=ON -Bbuild .');
system('cd build && make -j 10 && cd ..');
end
%system('cmake --build build --parallel 8');
cd(old_dir);

0 comments on commit d69471f

Please sign in to comment.