cesium-native icon indicating copy to clipboard operation
cesium-native copied to clipboard

Add support for Conan

Open baothientran opened this issue 4 years ago • 31 comments

Fixes #230

This PR removes most of our git submodules and use conan to install most of our third-party libraries

  • Group all of our cmake options into one place for convenience
  • Move target helper functions into a separate cmake module ConfigureTarget.cmake
  • Remove all third-party libraries that already exist in Conan Center
  • Use @jtorresfabra 's ConfigureConan.cmake and find_package() to retrieve third-party libraries from Conan
  • Thanks to @jtorresfabra, the CI can now work with and cache Conan correctly

@kring and @jtorresfabra if possible, can you please take a look at it and let me know if I should update anything

baothientran avatar Jun 04 '21 01:06 baothientran

I convert back to draft because cesium-unreal needs to update the CI too

baothientran avatar Jun 04 '21 01:06 baothientran

Debug builds initiated from Visual Studio Code on Windows no longer work. We get lots of link errors like this:

[build] async++.lib(scheduler.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in TestCreditSystem.obj [C:\Dev\cesium-unreal-samples\Plugins\cesium-unreal\extern\cesium-native\build\CesiumNativeTests\cesium-native-tests.vcxproj]
[build] async++.lib(scheduler.obj) : error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MD_DynamicRelease' doesn't match value 'MDd_DynamicDebug' in TestCreditSystem.obj [C:\Dev\cesium-unreal-samples\Plugins\cesium-unreal\extern\cesium-native\build\CesiumNativeTests\cesium-native-tests.vcxproj]
[build] async++.lib(threadpool_scheduler.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in TestCreditSystem.obj [C:\Dev\cesium-unreal-samples\Plugins\cesium-unreal\extern\cesium-native\build\CesiumNativeTests\cesium-native-tests.vcxproj]
[build] async++.lib(threadpool_scheduler.obj) : error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MD_DynamicRelease' doesn't match value 'MDd_DynamicDebug' in TestCreditSystem.obj [C:\Dev\cesium-unreal-samples\Plugins\cesium-unreal\extern\cesium-native\build\CesiumNativeTests\cesium-native-tests.vcxproj]
[build] draco.lib(options.obj) : error LNK2038: mismatch detected for '_ITERATOR_DEBUG_LEVEL': value '0' doesn't match value '2' in TestCreditSystem.obj [C:\Dev\cesium-unreal-samples\Plugins\cesium-unreal\extern\cesium-native\build\CesiumNativeTests\cesium-native-tests.vcxproj]
[build] draco.lib(options.obj) : error LNK2038: mismatch detected for 'RuntimeLibrary': value 'MD_DynamicRelease' doesn't match value 'MDd_DynamicDebug' in TestCreditSystem.obj [C:\Dev\cesium-unreal-samples\Plugins\cesium-unreal\extern\cesium-native\build\CesiumNativeTests\cesium-native-tests.vcxproj]

The problem is that VS Code doesn't define CMAKE_BUILD_TYPE when generating for Visual Studio, because a single set of project files can build any configuration. So we get a Release build of the third-party libraries, and this can't link against the Debug build of the cesium-native libraries. This will be true in normal use on the Windows command-link as well.

Is there a reasonable way to install both the Debug and Release versions of the third-party libraries at configure time on Windows? That would be the best way to avoid surprises. Failing that, the next best thing is probably to configure VS Code to include the build type, as described in https://github.com/microsoft/vscode-cmake-tools/issues/1298. Command-line (or CMake GUI) users will still need to specify a configuration at configure time, though, contrary to standard practice on Windows.

kring avatar Jun 11 '21 06:06 kring

Even after adding:

    "cmake.configureSettings": {
        "CMAKE_BUILD_TYPE": "${buildType}"
    }

There are warnings a link time due to missing PDBs from all the third party libraries. Does Conan not include PDBs in debug builds? That seems odd, and less than ideal.

kring avatar Jun 11 '21 06:06 kring

Thanks again for your contribution @baothientran!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Aug 17 '21 02:08 cesium-concierge

Thanks again for your contribution @baothientran!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Sep 16 '21 02:09 cesium-concierge

Thanks again for your contribution @baothientran!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Oct 16 '21 02:10 cesium-concierge

Thanks again for your contribution @baothientran!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Nov 15 '21 03:11 cesium-concierge

Is there a reasonable way to install both the Debug and Release versions of the third-party libraries at configure time on Windows?

cmake_find_package_multi has been working well for us in tilers

There are warnings a link time due to missing PDBs from all the third party libraries. Does Conan not include PDBs in debug builds? That seems odd, and less than ideal.

It might depend on how the package was generated. Which is why it would be better to build third party libraries from source on first configuration, which is related to https://github.com/conan-io/conan/issues/7117.

lilleyse avatar Dec 14 '21 23:12 lilleyse

Thanks again for your contribution @baothientran!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Jan 14 '22 03:01 cesium-concierge

Thanks again for your contribution @baothientran!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Feb 13 '22 03:02 cesium-concierge

Thanks again for your contribution @baothientran!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Mar 15 '22 02:03 cesium-concierge

Thanks again for your contribution @baothientran!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Apr 14 '22 02:04 cesium-concierge

Thanks again for your contribution @baothientran!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar May 14 '22 02:05 cesium-concierge

Thanks again for your contribution @baothientran!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Jun 13 '22 02:06 cesium-concierge

Thanks again for your contribution @baothientran!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Jul 13 '22 02:07 cesium-concierge

Thanks again for your contribution @baothientran!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Aug 12 '22 02:08 cesium-concierge

Thanks again for your contribution @baothientran!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Sep 11 '22 02:09 cesium-concierge

Thanks again for your contribution @baothientran!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Oct 11 '22 02:10 cesium-concierge

Thanks again for your contribution @baothientran!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Nov 10 '22 03:11 cesium-concierge

Thanks again for your contribution @baothientran!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Dec 10 '22 03:12 cesium-concierge

Thanks again for your contribution @baothientran!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Jan 09 '23 03:01 cesium-concierge

Thanks again for your contribution @baothientran!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Feb 08 '23 03:02 cesium-concierge

Thanks again for your contribution @baothientran!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Mar 10 '23 03:03 cesium-concierge

Thanks again for your contribution @baothientran!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Apr 09 '23 02:04 cesium-concierge

Thanks again for your contribution @baothientran!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar May 09 '23 02:05 cesium-concierge

Thanks again for your contribution @baothientran!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Jun 08 '23 02:06 cesium-concierge

Thanks again for your contribution @baothientran!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Jul 08 '23 02:07 cesium-concierge

Thanks again for your contribution @baothientran!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Aug 07 '23 02:08 cesium-concierge

Thanks again for your contribution @baothientran!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Sep 06 '23 02:09 cesium-concierge

Thanks again for your contribution @baothientran!

No one has commented on this pull request in 30 days. Maintainers, can you review, merge or close to keep things tidy?

I'm going to re-bump this in 30 days. If you'd like me to stop, just comment with @cesium-concierge stop. If you want me to start again, just delete the comment.

cesium-concierge avatar Oct 06 '23 02:10 cesium-concierge