+
Skip to content

Conversation

LuAPi
Copy link

@LuAPi LuAPi commented Mar 18, 2019

This contains a collection of fixes.

Moos CMake changed to use the use the library namespacing convention. This updated this project's CMakeLists to handle that.

Matlab 2018 has asserts set to check that mex functions are being called from matlab threads. This library used to call mexPrintf from a moos thread on connection which would cause modern Matlab to exit with error output displayed. This PR simply removes the offending print statement.

There is/was some issue relating to rpaths. I don't know what it was but both Alex Stewart and Dan Barnes have written fixes and I combined both.

Recent CMake has built in FindMatlab support. This updates the CMakeLists to use CMake's own FindMatlab rather than providing our own.

This seems to work on OS X (Sierra, Mojave) and Ubuntu 16.

Matlab 2018 changed to use the C++11 std::string ABI. For this to work with Matlab 2018 you need to build both MOOS and this with the C++11 ABI. For earlier versions of Matlab you need to compile MOOS and this with the old ABI.

pmnewman and others added 12 commits March 15, 2015 21:56
Usually target_link_libraries handles this, but using normal cmake targets and functions will result in the normal c/++ compiler being used instead of mex; this means we need to handle namespace striping ourselves.

The regex could probably be improved. I'm not sure what characters are used to seperate entries if multiple entries are present in MOOS_LIBRARIES . There should only be one right now and it probably won't change, but if more are added in future this will probably break. The regex should be updated to match all things that aren't the seperator followed by :: . CMakee regexes are rather limited and don't have character classes that neatly handle things like whitespace or not-whitespace for eaxmple.
Matlab 2018b has an assert that checks if you are calling these functions from threads other than matlab's own and crashes if you do so.
* cmake-fix:
  Add missing MOOS library path to -rpath.
  Add ignore of the IDE generated CMakeLists file.
  Remove IDE generated local file.
  Update CMake to support 14.04.

# Conflicts:
#	CMakeLists.txt
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

点击 这是indexloc提供的php浏览器服务,不要输入任何密码和下载