No Clang component for MSVC found

Question:

I’m using anaconda Nuitka packages to obfuscate my python script PASS.py
I’ve done below steps:

  1. installed Microsoft visual studio community edition 2022 with python development and Desktop development with C++

  2. installed individual components:
    enter image description here
    enter image description here

  3. I have also installed microsoft_build_tools_2015_update_3_x86_x64 and visual_2015_redistributable_update_3_x86

  4. added to path system variable: clang.exe, clang++.exe and clang-cl.exe,
    in my system there are in:

    C:Program FilesMicrosoft Visual Studio2022CommunityVCToolsLlvmbin
    C:Program FilesMicrosoft Visual Studio2022CommunityVCToolsLlvmx64bin
    C:UsersDaliaanaconda3pkgsclang-14.0.6-h44fa016_0Librarybin

  5. on anaconda prompt, I run below command

    python -m nuitka –clang –follow-imports PASS.py

it shows below message:

 Nuitka-Options:INFO: Used command line options: --clang --follow-imports PASS.py
    Nuitka:INFO: Starting Python compilation with Nuitka '0.6.16' on Python '3.9' commercial None.
    Nuitka:INFO: Completed Python level compilation and optimization.
    Nuitka:INFO: Generating source code for C backend compiler.
    Nuitka:INFO: Running data composer tool for optimal constant value handling.
    Nuitka:INFO: Running C level backend compilation via Scons.
    TypeError: not all arguments converted during string formatting:
      File "C:UsersDaliaANACON~1libSITE-P~1nuitkabuildBackend.scons", line 334:
        addClangClPathFromMSVC(env=env, target_arch=target_arch)
      File "C:UsersDaliaanaconda3libsite-packagesnuitkabuildSconsUtils.py", line 315:
        scons_details_logger.info("No Clang component for MSVC found." % clang_dir)
Asked By: Dalia Mokhtar

||

Answers:

I found the solution:
just write cmd without "–clang"

python -m nuitka --follow-imports PASS.py
Answered By: Dalia Mokhtar
Categories: questions Tags: , , , ,
Answers are sorted by their score. The answer accepted by the question owner as the best is marked with
at the top-right corner.