Skip to content

Fix clang-cl MSVC frontend received GNU flag on assembling #294

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

Merged
merged 1 commit into from
Apr 17, 2025

Conversation

Challanger524
Copy link
Contributor

@Challanger524 Challanger524 commented Feb 22, 2025

PR for #293

Put if (GNU/Clang) into the MASM's else clause since Clang-CL validates positive at CMAKE_CXX_COMPILER_ID STREQUAL "Clang" while also having MSVC frontend for compile options and utilising ML masm assembler.

UPD: clang-cl /quiet support has been dropped due to inability to know real version for sure.
Side (weird) fix for /quiet flag being passed on MSVC_VERSION: 1936 despite Visual Studio Enterprise 2019 Version 16.11.35:

Dropping context
  • Visual Studio Enterprise 2019 Version 16.11.35
  • (Microsoft (R) Macro Assembler (x64) Version 14.29.30154.0)
  • message(STATUS "MSVC_VERSION: ${MSVC_VERSION}") = -- MSVC_VERSION: 1936 report
  • despite doc says that: /quiet Suppresses 'Assembling' message. Available in Visual Studio 17.6 and later.
    Looks like CMake gives wrong MSVC_VERSION for clang-cl.

Tested

On MS Windows with CMake with next compilers: MSVC, msys2/mingw64/GCC, msys2/clang64/Clang, Clang-CL (chocolatey install)

@Challanger524
Copy link
Contributor Author

Challanger524 commented Feb 22, 2025

@marakew can you copy patch to your boost::context and validate?

@marakew
Copy link

marakew commented Feb 22, 2025

seems works

@Challanger524 Challanger524 marked this pull request as ready for review February 22, 2025 17:10
@Challanger524 Challanger524 marked this pull request as draft February 22, 2025 17:50
@Challanger524 Challanger524 force-pushed the fix_clang-cl_masm_combo branch from 5f6f4b5 to 628cefe Compare February 22, 2025 18:38
@Challanger524 Challanger524 marked this pull request as ready for review February 22, 2025 18:40
@Challanger524 Challanger524 marked this pull request as draft February 22, 2025 18:44
@Challanger524 Challanger524 marked this pull request as ready for review February 23, 2025 14:41
@marakew
Copy link

marakew commented Apr 15, 2025

@olk how about merge ?

@olk olk merged commit ef39a89 into boostorg:develop Apr 17, 2025
20 of 23 checks passed
@olk
Copy link
Member

olk commented Apr 17, 2025

ty

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.

3 participants