Import C under Windows 10
Ferhat Kurtulmuş
aferust at gmail.com
Wed Apr 15 07:20:44 UTC 2026
On Tuesday, 14 April 2026 at 14:25:29 UTC, DLearner wrote:
> This relates to:
>
> ```
> DMD64 D Compiler v2.112.0
> Copyright (C) 1999-2025 by The D Language Foundation, All
> Rights Reserved written by Walter Bright
>
> ```
>
> While trying to compile and run hello.c (ie trying out Import
> C):
>
> ```
> #include <stdio.h>
> int main()
> {
> printf("Hello world.\n");
> return 0;
> }
>
> ```
>
> I got
>
> ```
> Error: cl.exe not found. Please ensure that Visual Studio Build
> Tools are installed and properly configured.
> ```
> despite repeatedly downloading everything I could find relating
> to Visual Studio 2019.
>
> FWIW, isn't 'cl.exe' MS's _own_ C compiler - I wanted to use
> the C compiler within DMD.
>
> Ideas?
Usually, Windows Command Prompt does not automatically recognize
VS compilers (due to PATH issues). Just run everything in a x64
Native Tools Command Prompt for VS 2019 (or 32 bit).
More information about the Digitalmars-d-learn
mailing list