Skip to content
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

Cannot disable RTTI under the Visual Studio backend #13973

Open
kridenberg opened this issue Nov 30, 2024 · 0 comments
Open

Cannot disable RTTI under the Visual Studio backend #13973

kridenberg opened this issue Nov 30, 2024 · 0 comments
Labels
backend:visualstudio Visual Studio project backends

Comments

@kridenberg
Copy link

kridenberg commented Nov 30, 2024

Describe the bug
While trying to generate a project with VS2022 and VS2019 backend I noticed that cpp_rtti does not take any effect for VS backend at all. This is also reproducible with the Clang-CL (clang 19.1.4) compiler as well. Any attempt to attach /GR- option directly does not work (or maybe I do not realise for now how to do it properly)

Additionally, I do not know if this is a bug or a design decision, but the VS backend does not take into account c_std and cpp_std options if there is no file to compile with those compilers. For example, in the attached zip c_std option is not set for the VS backend, because there are no sources to compile with the C compiler.

To Reproduce

  1. Open Developer Command Prompt for VS2022
  2. Execute "meson setup build --backend vs2022" or "CC=clang-cl CXX=clang-cl meson setup build --backend vs2022"

Expected behavior
Options are applied as expected. RTTI is disabled and the C standard is set to the 17 version.

system parameters
Platin native build.
OS: Windows 11
Python: 3.11.9
Meson version: tested on 1.6.99 (latest git at that moment) and 1.6.0 (from pip)

Zip archive with meson.build and source.cpp file:
test.zip

@bruchar1 bruchar1 added the backend:visualstudio Visual Studio project backends label Dec 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backend:visualstudio Visual Studio project backends
Projects
None yet
Development

No branches or pull requests

2 participants