C1083 Fatal Error everywhere, but not in Visual Studio

Никита Лисицын 0 Reputation points

Every time I try to build a project (new blank) or just install something with pip install, I encounter the error C1083 No such file or directory.

I've tried completely reinstalling Visual Studio, installing all SDK variants and now I'm out of ideas.

A high-level, general-purpose programming language, created as an extension of the C programming language, that has object-oriented, generic, and functional features in addition to facilities for low-level memory manipulation.
3,563 questions
0 comments No comments
{count} votes

3 answers

Sort by: Most helpful
  1. Hui Liu-MSFT 44,186 Reputation points Microsoft Vendor

    Hi,@Никита Лисицын. Welcome Microsoft Q&A.

    The C1083 error in Visual Studio typically occurs when the compiler is unable to locate a specific header file or a necessary file for the build process.

    Here are some steps to help you resolve the C1083 error:

    Header File Paths:

    Ensure that the header file you're trying to include is in a directory that is part of the include directories list in your project settings.

    Check that the path to the header file doesn't contain any typos or errors.

    Ensure that the directory containing the header file is included using the /I compiler option if it's not in a standard system directory.

    Library Paths:

    If the error is related to a library file, check that the library directory is included in your project settings.

    Verify that the library file exists in the specified directory.

    Typographical Errors: Double-check your code for typographical errors, such as misspelled filenames or incorrect case sensitivity.

    Include Statements:

    Make sure you're using the correct #include directive to include the header file. For system headers, use angle brackets (#include <header.h>), and for user-defined headers, use double-quotes (#include "header .h").

    Ensure there are no circular dependencies between header files.

    File Locations:

    Verify that the file is actually located where you expect it to be.

    Clean and Rebuild:

    Sometimes, temporary build files can cause issues. Try cleaning the project and then rebuilding it.

    Environment Variables:

    Check your system's PATH environment variable to make sure it includes the paths to the necessary compilers, SDKs, and libraries.

    If you still have questions, please feel free to let me know. The problem would be better solved if more details (steps and code to reproduce the problem) are described.

    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

  2. Никита Лисицын 0 Reputation points

    I followed the advice of this reply and the error went away, but a bunch of others appeared. I'm probably on the right track, but I didn't get my paths right.

  3. Никита Лисицын 0 Reputation points

    I solved the problem (at least when installing python modules) as follows:

    1. I added the path into the environmental variables.
    C:\Windows Kits\10\bin\10.0.22621.0\x64
    1. I also created 2 variables
    set INCLUDE=C:\Windows Kits\10\Include\10.0.22621.0\ucrt;C:\Windows Kits\10\Include\10.0.22621.0\shared


    set LIB=C:\Windows Kits\10\Lib\10.0.22621.0\um\x64;C:\Windows Kits\10\Lib\10.0.22621.0\ucrt\x64

    For some reason neither VS Developer Command Promt and vcvarsall.bat does nothing in my case.