Skip to content

Allow building gdal, dae, ffmpeg and obj plugins with /std:c++17 msvc flag #1246

Open
maksim-petukhou wants to merge 2 commits intoopenscenegraph:masterfrom
maksim-petukhou:std-17-fix
Open

Allow building gdal, dae, ffmpeg and obj plugins with /std:c++17 msvc flag #1246
maksim-petukhou wants to merge 2 commits intoopenscenegraph:masterfrom
maksim-petukhou:std-17-fix

Conversation

@maksim-petukhou
Copy link

@maksim-petukhou maksim-petukhou commented Jul 21, 2023

auto_ptr is removed in C++17. This PR fixes gdal and ffmpeg plugin in a similar way than dae plugin was fixed (see 863dee5), but also takes into account that __cplusplus always reports 199711L in msvc when not using special flag /Zc:__cplusplus (see https://learn.microsoft.com/en-us/cpp/build/reference/zc-cplusplus?view=msvc-170#remarks)

ptr_fun is also removed in C++17. That's why I provided C++17 compatible version of strip function for obj plugin.

@maksim-petukhou maksim-petukhou changed the title Allow building gdal plugin in C++17 msvc mode Allow building gdal, dae and ffmpeg plugins with /std:c++17 msvc flag Jul 21, 2023
fix again

fix one more time
fix
@maksim-petukhou maksim-petukhou changed the title Allow building gdal, dae and ffmpeg plugins with /std:c++17 msvc flag Allow building gdal, dae, ffmpeg and obj plugins with /std:c++17 msvc flag Jul 21, 2023
sebhmg added a commit to MiraGeoscience/conan-center-index that referenced this pull request Mar 21, 2026
Backport patches 0007-0011 from conan-center-index commit 0992b51
(conan-io#23704 Migrate/openscenegraph) to the Conan 1 recipe.

Patches added:
- 0007: fix MSVC with std C++17 (std::byte ambiguity with Windows SDK)
  Upstream: openscenegraph/OpenSceneGraph#1055
- 0008: replace std::mem_fun_ref (removed in C++17)
  Upstream: openscenegraph/OpenSceneGraph@8a0114a
- 0009: replace std::auto_ptr in plugins (removed in C++17)
  Upstream: openscenegraph/OpenSceneGraph#1246
- 0010: replace std::ptr_fun in obj plugin (removed in C++17)
  Upstream: openscenegraph/OpenSceneGraph#1246
- 0011: remove deprecated register keyword (deprecated in C++17)
  Upstream: openscenegraph/OpenSceneGraph#1296

Source: conan-center-index@0992b51e2fe337e594f2c57bf6c01ee4d733165a
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.

1 participant