Skip to content

[Windows][melodic] Fix ASSIMP libraries path for Windows build#101

Merged
henningkayser merged 2 commits intomoveit:melodic-develfrom
ms-iot:windows_port_assimp_fix
Apr 2, 2019
Merged

[Windows][melodic] Fix ASSIMP libraries path for Windows build#101
henningkayser merged 2 commits intomoveit:melodic-develfrom
ms-iot:windows_port_assimp_fix

Conversation

@seanyen
Copy link
Copy Markdown
Contributor

@seanyen seanyen commented Apr 1, 2019

This change is another iteration based on #99.

@seanyen
Copy link
Copy Markdown
Contributor Author

seanyen commented Apr 1, 2019

@rhaschke Sorry I wasn't able to find time to iterate on #99 and here is a version based on your change to make it work on Windows build.

Copy link
Copy Markdown
Contributor

@rhaschke rhaschke left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like I missed to add PC. Please try this instead of your addition.

@seanyen
Copy link
Copy Markdown
Contributor Author

seanyen commented Apr 1, 2019

@rhaschke Hi, it turned out on Windows build, assimp is discovered by using CMake config file so the pkg-config code path is not really getting exercised. Anyway, I am pushing a new change which should accommodate both. Let me know what you think.

@rhaschke
Copy link
Copy Markdown
Contributor

rhaschke commented Apr 1, 2019

Ok, if Windows detects assimp via a cmake config, what is the actual problem. Shouldn't this work out of the box?

@seanyen
Copy link
Copy Markdown
Contributor Author

seanyen commented Apr 1, 2019

On Windows build, we are using assimp v4.1 (the same like Ubuntu bionic using) and just as many libraries they are producing the CMake config intead of pkg-config for Windows build. And from assimp, its CMake Config is like this: https://github.com/assimp/assimp/blob/v4.1.0/assimp-config.cmake.in#L42-L51

As you can see, the ${ASSIMP_LIBRARIES} is defined to be just as the library name like assimp-vc140-mt and the library directory is defined in another CMake variable ${ASSIMP_LIBRARY_DIRS}. However, ${ASSIMP_LIBRARY_DIRS} was not in the target's link directory, so duing linking stage, it cannot find where the library actually is.

Copy link
Copy Markdown
Contributor

@rhaschke rhaschke left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I added a comment. Otherwise lgtm.

Co-Authored-By: seanyen <seanyen@microsoft.com>
@seanyen
Copy link
Copy Markdown
Contributor Author

seanyen commented Apr 2, 2019

@rhaschke Thanks. The comments are added.

Copy link
Copy Markdown
Member

@henningkayser henningkayser left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me!
The kinetic build timed out on Travis so let's wait for the new run to finish.

@henningkayser henningkayser merged commit b1bcd7c into moveit:melodic-devel Apr 2, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants