-
Notifications
You must be signed in to change notification settings - Fork 311
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[CMake] CLEAN/FIX deprecated things (MSVC mainly) #2217
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
fredroy
added
pr: fast merge
Minor change that can be merged without waiting for the 7 review days
pr: status to review
To notify reviewers to review this pull-request
pr: clean
Cleaning the code
pr: do not squash
To merge instead of squash a pull-request
labels
Jun 30, 2021
alxbilger
approved these changes
Jun 30, 2021
guparan
added
pr: status ready
Approved a pull-request, ready to be squashed
and removed
pr: status to review
To notify reviewers to review this pull-request
labels
Jun 30, 2021
guparan
changed the title
[Sofa] Clean, Fix deprecated things (MSVC mainly)
[CMake] CLEAN/FIX deprecated things (MSVC mainly)
Jun 30, 2021
guparan
added a commit
that referenced
this pull request
Jul 1, 2021
* msvc: re-enable deprecated warnings for Sofa modules * msvc: disable deprecated warnings for external projects * msvc: use Sleep instead of deprecated _sleep * unique() for shared_ptr is deprecated (https://en.cppreference.com/w/cpp/memory/shared_ptr/unique) * Update CMakeLists.txt Co-authored-by: Guillaume Paran <guillaume.paran@sofa-framework.org>
fredroy
added a commit
that referenced
this pull request
Jul 5, 2021
* [CMake][Changelog] Bump to 21.06.00 + Update Changelog * Merge pull request #1996 from fredroy/optim_ldl_insimo [SofaSparseSolver] SparseLDLSolver optimizations * [CMake] ADD option to enable/disable compatibility layer (#2216) * [CMake] CLEAN/FIX deprecated things (MSVC mainly) (#2217) * msvc: re-enable deprecated warnings for Sofa modules * msvc: disable deprecated warnings for external projects * msvc: use Sleep instead of deprecated _sleep * unique() for shared_ptr is deprecated (https://en.cppreference.com/w/cpp/memory/shared_ptr/unique) * Update CMakeLists.txt Co-authored-by: Guillaume Paran <guillaume.paran@sofa-framework.org> * [Changelog] Update Changelog * [SofaHelper] FIX PluginRepository order on Windows * [SofaGuiQt] Remove RELOCATABLE attribute * [All] Remove use of compatibility layer (#2179) * re-enable warnings when using compat headers * sofaframework compiles * sofabase compiles * sofagl compiles * modules compiles * gui compiles * tests compiles * image * plugins * linux, plugins... * physicsapi, cuda * remove more uses * compiles without sofa.compat * compiles without sofa.compat with plugins * Fix headlessrecorder * fix geomagic * fix sofaassimp * fix imagetoolbox * Fix compilation crash with masses * Update SofaKernel/modules/Sofa.GL/src/sofa/gl/BasicShapes.h Co-authored-by: Alex Bilger <alxbilger@users.noreply.github.com> * restore compat in cmake * fix compilation * fix sparseldl * [All] FIX deprecated includes "sofa/helper/ArgumentParser.h" # Conflicts: # applications/projects/SofaFlowVR/Main.cpp # applications/projects/runSofa/Main.cpp # applications/tutorials/oneParticle/oneParticle.cpp * [All] FIX deprecated includes "sofa/helper/ArgumentParser.h" (2) Co-authored-by: Alex Bilger <alxbilger@users.noreply.github.com> Co-authored-by: Guillaume Paran <guillaume.paran@sofa-framework.org> * [Changelog] Update Changelog * [tools] Disable more plugins in postinstall scripts * [All] FIX sofa::type::vector propagation * [SofaSimpleFem] Fix rendering options in TetrahedronFEMFF (#2156) * [SofaSimpleFem] Fix rendering options in TetrahedronFEMFF * Add function checking if the value of computeVonMisesStress is valid * minor fix warning in the meantime * Update SofaKernel/modules/SofaSimpleFem/src/SofaSimpleFem/TetrahedronFEMForceField.inl Co-authored-by: Alex Bilger <alxbilger@users.noreply.github.com> * Make isVonMisesStressRenderingOptionValid() function const * [SofaSimpleFem] CLEAN von Mises Stress draw in TetrahedronFEMForceField + ADD showVonMisesStressPerElement Data in TetrahedronFEMForceField * [SofaSimpleFem] FIX TetrahedronFEMForceField * fix compilation * [SofaSimpleFem] FIX TetrahedronFEMForceField::draw * [SofaSimpleFem] Avoid segfault in TetrahedronFEMForceField with method SMALL * [SofaSimpleFem] CLEAN message in TetrahedronFEMForceField::draw * [SofaSimpleFem] CLEAN message in TetrahedronFEMForceField::draw (2) Co-authored-by: Alex Bilger <alxbilger@users.noreply.github.com> Co-authored-by: Guillaume Paran <guillaume.paran@sofa-framework.org> Co-authored-by: Frederick Roy <fredroy@users.noreply.github.com> Co-authored-by: Frederick Roy <frederick.roy@inria.fr> * [Changelog] Update Changelog * [SofaGuiCommon] FIX GuiDataRepository when used by python interpreter * [All] Fix debug compilation (#2223) * fix header in rigidtypes with gcc/clang and debug * fix eulerianfluid with debug compilation * [Changelog] Update Changelog * [CMake] Bump version to 21.12.99 Co-authored-by: Frederick Roy <fredroy@users.noreply.github.com> Co-authored-by: Alex Bilger <alxbilger@users.noreply.github.com> Co-authored-by: Hugo <hugo.talbot@sofa-framework.org> Co-authored-by: Frederick Roy <frederick.roy@inria.fr>
guparan
added a commit
that referenced
this pull request
Jul 5, 2021
* [CMake][Changelog] Bump to 21.06.00 + Update Changelog * Merge pull request #1996 from fredroy/optim_ldl_insimo [SofaSparseSolver] SparseLDLSolver optimizations * [CMake] ADD option to enable/disable compatibility layer (#2216) * [CMake] CLEAN/FIX deprecated things (MSVC mainly) (#2217) * msvc: re-enable deprecated warnings for Sofa modules * msvc: disable deprecated warnings for external projects * msvc: use Sleep instead of deprecated _sleep * unique() for shared_ptr is deprecated (https://en.cppreference.com/w/cpp/memory/shared_ptr/unique) * Update CMakeLists.txt Co-authored-by: Guillaume Paran <guillaume.paran@sofa-framework.org> * [Changelog] Update Changelog * [SofaHelper] FIX PluginRepository order on Windows * [SofaGuiQt] Remove RELOCATABLE attribute * [All] Remove use of compatibility layer (#2179) * re-enable warnings when using compat headers * sofaframework compiles * sofabase compiles * sofagl compiles * modules compiles * gui compiles * tests compiles * image * plugins * linux, plugins... * physicsapi, cuda * remove more uses * compiles without sofa.compat * compiles without sofa.compat with plugins * Fix headlessrecorder * fix geomagic * fix sofaassimp * fix imagetoolbox * Fix compilation crash with masses * Update SofaKernel/modules/Sofa.GL/src/sofa/gl/BasicShapes.h Co-authored-by: Alex Bilger <alxbilger@users.noreply.github.com> * restore compat in cmake * fix compilation * fix sparseldl * [All] FIX deprecated includes "sofa/helper/ArgumentParser.h" # Conflicts: # applications/projects/SofaFlowVR/Main.cpp # applications/projects/runSofa/Main.cpp # applications/tutorials/oneParticle/oneParticle.cpp * [All] FIX deprecated includes "sofa/helper/ArgumentParser.h" (2) Co-authored-by: Alex Bilger <alxbilger@users.noreply.github.com> Co-authored-by: Guillaume Paran <guillaume.paran@sofa-framework.org> * [Changelog] Update Changelog * [tools] Disable more plugins in postinstall scripts * [All] FIX sofa::type::vector propagation * [SofaSimpleFem] Fix rendering options in TetrahedronFEMFF (#2156) * [SofaSimpleFem] Fix rendering options in TetrahedronFEMFF * Add function checking if the value of computeVonMisesStress is valid * minor fix warning in the meantime * Update SofaKernel/modules/SofaSimpleFem/src/SofaSimpleFem/TetrahedronFEMForceField.inl Co-authored-by: Alex Bilger <alxbilger@users.noreply.github.com> * Make isVonMisesStressRenderingOptionValid() function const * [SofaSimpleFem] CLEAN von Mises Stress draw in TetrahedronFEMForceField + ADD showVonMisesStressPerElement Data in TetrahedronFEMForceField * [SofaSimpleFem] FIX TetrahedronFEMForceField * fix compilation * [SofaSimpleFem] FIX TetrahedronFEMForceField::draw * [SofaSimpleFem] Avoid segfault in TetrahedronFEMForceField with method SMALL * [SofaSimpleFem] CLEAN message in TetrahedronFEMForceField::draw * [SofaSimpleFem] CLEAN message in TetrahedronFEMForceField::draw (2) Co-authored-by: Alex Bilger <alxbilger@users.noreply.github.com> Co-authored-by: Guillaume Paran <guillaume.paran@sofa-framework.org> Co-authored-by: Frederick Roy <fredroy@users.noreply.github.com> Co-authored-by: Frederick Roy <frederick.roy@inria.fr> * [Changelog] Update Changelog * [SofaGuiCommon] FIX GuiDataRepository when used by python interpreter * [All] Fix debug compilation (#2223) * fix header in rigidtypes with gcc/clang and debug * fix eulerianfluid with debug compilation * [Changelog] Update Changelog * [CMake] Bump version to 21.12.99 Co-authored-by: Frederick Roy <fredroy@users.noreply.github.com> Co-authored-by: Alex Bilger <alxbilger@users.noreply.github.com> Co-authored-by: Hugo <hugo.talbot@sofa-framework.org> Co-authored-by: Frederick Roy <frederick.roy@inria.fr> # Conflicts: # CMakeLists.txt
alxbilger
pushed a commit
to alxbilger/sofa
that referenced
this pull request
Oct 27, 2023
* msvc: re-enable deprecated warnings for Sofa modules * msvc: disable deprecated warnings for external projects * msvc: use Sleep instead of deprecated _sleep * unique() for shared_ptr is deprecated (https://en.cppreference.com/w/cpp/memory/shared_ptr/unique) * Update CMakeLists.txt Co-authored-by: Guillaume Paran <guillaume.paran@sofa-framework.org>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
pr: clean
Cleaning the code
pr: do not squash
To merge instead of squash a pull-request
pr: fast merge
Minor change that can be merged without waiting for the 7 review days
pr: status ready
Approved a pull-request, ready to be squashed
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
1- MSVC was never throwing deprecation warnings because ... it was disabled with the compiler flags. A bit hard to inform the user that one feature or file is deprecated if he is not warned.
So this PR re-enables 4996 (deprecation) warnings but still disable some msvc-specific deprecation notices (with some preprocessor defines)
2- A contrario, deprecation warnings in extlibs are quite annoying so they should be disabled IMO.
3- enabling deprecation warnings led to two types of deprecation in the SOFA code base:
Replaced with use_count() == 1 but this does not really address the issue of approximation in a multithreaded context.
By submitting this pull request, I acknowledge that
I have read, understand, and agree SOFA Developer Certificate of Origin (DCO).
Reviewers will merge this pull-request only if