Dingjun Chen - 2023-08-28

Hi, guys,

Could someone tell me how to fix the following errors? I tried to install PLplot library on Windows with CMake 3.27.3. During configuration, there are some head files that cannot be found. I use the GNU c/c++ compilers:
C:\msys64\ucrt64\bin\gcc.exe
C:\msys64\ucrt64\bin\g++.exe
C:/msys64/mingw64/bin/gfortran.exe

What caused such errors? please tell me how to fix these errors.

The following is the CMake log file and you may find details on errors below.

I look forward to your help!

Best regards,

Dingjun

Determining if the DIR symbol is defined as in AC_HEADER_DIRENT failed with the following output:
Change Dir: 'C:/Users/Dingjun.Chen/plplot-5.15.0 .tar/plplot_build/CMakeFiles/CMakeTmp'

Run Build Command(s): "C:/Program Files/Microsoft Visual Studio/2022/Community/MSBuild/Current/Bin/amd64/MSBuild.exe" cmTC_24779.vcxproj /p:Configuration=Debug /p:Platform=x64 /p:VisualStudioVersion=17.0 /v:n
MSBuild version 17.7.2+d6990bcfa for .NET Framework
Build started 2023-08-28 9:08:28 AM.

Project "C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\cmTC_24779.vcxproj" on node 1 (default targets).
PrepareForBuild:
Creating directory "cmTC_24779.dir\Debug\".
Creating directory "C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\Debug\".
Creating directory "cmTC_24779.dir\Debug\cmTC_24779.tlog\".
InitializeBuildStatus:
Creating "cmTC_24779.dir\Debug\cmTC_24779.tlog\unsuccessfulbuild" because "AlwaysCreate" was specified.
Touching "cmTC_24779.dir\Debug\cmTC_24779.tlog\unsuccessfulbuild".
ClCompile:
C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.37.32822\bin\HostX64\x64\CL.exe /c /Zi /W3 /WX- /diagnostics:column /Od /Ob0 /D _MBCS /D WIN32 /D _WINDOWS /D "CMAKE_INTDIR=\"Debug\"" /Gm- /RTC1 /MDd /GS /fp:precise /Zc:wchar_t /Zc:forScope /Zc:inline /Fo"cmTC_24779.dir\Debug\" /Fd"cmTC_24779.dir\Debug\vc143.pdb" /external:W3 /Gd /TC /errorReport:queue "C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\CheckDIRSymbolExists.c"
Microsoft (R) C/C++ Optimizing Compiler Version 19.37.32822 for x64
Copyright (C) Microsoft Corporation. All rights reserved.
cl /c /Zi /W3 /WX- /diagnostics:column /Od /Ob0 /D _MBCS /D WIN32 /D _WINDOWS /D "CMAKE_INTDIR=\"Debug\"" /Gm- /RTC1 /MDd /GS /fp:precise /Zc:wchar_t /Zc:forScope /Zc:inline /Fo"cmTC_24779.dir\Debug\" /Fd"cmTC_24779.dir\Debug\vc143.pdb" /external:W3 /Gd /TC /errorReport:queue "C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\CheckDIRSymbolExists.c"
CheckDIRSymbolExists.c
C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\CheckDIRSymbolExists.c(3,10): fatal error C1083: Cannot open include file: 'dirent.h': No such file or directory [C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\cmTC_24779.vcxproj]
Done Building Project "C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\cmTC_24779.vcxproj" (default targets) -- FAILED.

Build FAILED.

"C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\cmTC_24779.vcxproj" (default target) (1) ->
(ClCompile target) ->
C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\CheckDIRSymbolExists.c(3,10): fatal error C1083: Cannot open include file: 'dirent.h': No such file or directory [C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\cmTC_24779.vcxproj]

0 Warning(s)
1 Error(s)

Time Elapsed 00:00:00.63

File C:/Users/Dingjun.Chen/plplot-5.15.0 .tar/plplot_build/CMakeFiles/CMakeTmp/CheckDIRSymbolExists.c:
/ /

include <sys types.h=""></sys>

include <dirent.h></dirent.h>

int main()
{if ((DIR *) 0) return 0;}

Determining if the DIR symbol is defined as in AC_HEADER_DIRENT failed with the following output:
Change Dir: 'C:/Users/Dingjun.Chen/plplot-5.15.0 .tar/plplot_build/CMakeFiles/CMakeTmp'

Run Build Command(s): "C:/Program Files/Microsoft Visual Studio/2022/Community/MSBuild/Current/Bin/amd64/MSBuild.exe" cmTC_503d7.vcxproj /p:Configuration=Debug /p:Platform=x64 /p:VisualStudioVersion=17.0 /v:n
MSBuild version 17.7.2+d6990bcfa for .NET Framework
Build started 2023-08-28 9:08:29 AM.

Project "C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\cmTC_503d7.vcxproj" on node 1 (default targets).
PrepareForBuild:
Creating directory "cmTC_503d7.dir\Debug\".
Creating directory "C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\Debug\".
Creating directory "cmTC_503d7.dir\Debug\cmTC_503d7.tlog\".
InitializeBuildStatus:
Creating "cmTC_503d7.dir\Debug\cmTC_503d7.tlog\unsuccessfulbuild" because "AlwaysCreate" was specified.
Touching "cmTC_503d7.dir\Debug\cmTC_503d7.tlog\unsuccessfulbuild".
ClCompile:
C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.37.32822\bin\HostX64\x64\CL.exe /c /Zi /W3 /WX- /diagnostics:column /Od /Ob0 /D _MBCS /D WIN32 /D _WINDOWS /D "CMAKE_INTDIR=\"Debug\"" /Gm- /RTC1 /MDd /GS /fp:precise /Zc:wchar_t /Zc:forScope /Zc:inline /Fo"cmTC_503d7.dir\Debug\" /Fd"cmTC_503d7.dir\Debug\vc143.pdb" /external:W3 /Gd /TC /errorReport:queue "C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\CheckDIRSymbolExists.c"
Microsoft (R) C/C++ Optimizing Compiler Version 19.37.32822 for x64
Copyright (C) Microsoft Corporation. All rights reserved.
CheckDIRSymbolExists.c
cl /c /Zi /W3 /WX- /diagnostics:column /Od /Ob0 /D _MBCS /D WIN32 /D _WINDOWS /D "CMAKE_INTDIR=\"Debug\"" /Gm- /RTC1 /MDd /GS /fp:precise /Zc:wchar_t /Zc:forScope /Zc:inline /Fo"cmTC_503d7.dir\Debug\" /Fd"cmTC_503d7.dir\Debug\vc143.pdb" /external:W3 /Gd /TC /errorReport:queue "C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\CheckDIRSymbolExists.c"
C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\CheckDIRSymbolExists.c(3,10): fatal error C1083: Cannot open include file: 'sys/ndir.h': No such file or directory [C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\cmTC_503d7.vcxproj]
Done Building Project "C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\cmTC_503d7.vcxproj" (default targets) -- FAILED.

Build FAILED.

"C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\cmTC_503d7.vcxproj" (default target) (1) ->
(ClCompile target) ->
C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\CheckDIRSymbolExists.c(3,10): fatal error C1083: Cannot open include file: 'sys/ndir.h': No such file or directory [C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\cmTC_503d7.vcxproj]

0 Warning(s)
1 Error(s)

Time Elapsed 00:00:00.59

File C:/Users/Dingjun.Chen/plplot-5.15.0 .tar/plplot_build/CMakeFiles/CMakeTmp/CheckDIRSymbolExists.c:
/ /

include <sys types.h=""></sys>

include <sys ndir.h=""></sys>

int main()
{if ((DIR *) 0) return 0;}

Determining if the DIR symbol is defined as in AC_HEADER_DIRENT failed with the following output:
Change Dir: 'C:/Users/Dingjun.Chen/plplot-5.15.0 .tar/plplot_build/CMakeFiles/CMakeTmp'

Run Build Command(s): "C:/Program Files/Microsoft Visual Studio/2022/Community/MSBuild/Current/Bin/amd64/MSBuild.exe" cmTC_cd85d.vcxproj /p:Configuration=Debug /p:Platform=x64 /p:VisualStudioVersion=17.0 /v:n
MSBuild version 17.7.2+d6990bcfa for .NET Framework
Build started 2023-08-28 9:08:30 AM.

Project "C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\cmTC_cd85d.vcxproj" on node 1 (default targets).
PrepareForBuild:
Creating directory "cmTC_cd85d.dir\Debug\".
Creating directory "C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\Debug\".
Creating directory "cmTC_cd85d.dir\Debug\cmTC_cd85d.tlog\".
InitializeBuildStatus:
Creating "cmTC_cd85d.dir\Debug\cmTC_cd85d.tlog\unsuccessfulbuild" because "AlwaysCreate" was specified.
Touching "cmTC_cd85d.dir\Debug\cmTC_cd85d.tlog\unsuccessfulbuild".
ClCompile:
C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.37.32822\bin\HostX64\x64\CL.exe /c /Zi /W3 /WX- /diagnostics:column /Od /Ob0 /D _MBCS /D WIN32 /D _WINDOWS /D "CMAKE_INTDIR=\"Debug\"" /Gm- /RTC1 /MDd /GS /fp:precise /Zc:wchar_t /Zc:forScope /Zc:inline /Fo"cmTC_cd85d.dir\Debug\" /Fd"cmTC_cd85d.dir\Debug\vc143.pdb" /external:W3 /Gd /TC /errorReport:queue "C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\CheckDIRSymbolExists.c"
Microsoft (R) C/C++ Optimizing Compiler Version 19.37.32822 for x64
CheckDIRSymbolExists.c
Copyright (C) Microsoft Corporation. All rights reserved.
cl /c /Zi /W3 /WX- /diagnostics:column /Od /Ob0 /D _MBCS /D WIN32 /D _WINDOWS /D "CMAKE_INTDIR=\"Debug\"" /Gm- /RTC1 /MDd /GS /fp:precise /Zc:wchar_t /Zc:forScope /Zc:inline /Fo"cmTC_cd85d.dir\Debug\" /Fd"cmTC_cd85d.dir\Debug\vc143.pdb" /external:W3 /Gd /TC /errorReport:queue "C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\CheckDIRSymbolExists.c"
C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\CheckDIRSymbolExists.c(3,10): fatal error C1083: Cannot open include file: 'sys/dir.h': No such file or directory [C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\cmTC_cd85d.vcxproj]
Done Building Project "C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\cmTC_cd85d.vcxproj" (default targets) -- FAILED.

Build FAILED.

"C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\cmTC_cd85d.vcxproj" (default target) (1) ->
(ClCompile target) ->
C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\CheckDIRSymbolExists.c(3,10): fatal error C1083: Cannot open include file: 'sys/dir.h': No such file or directory [C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\cmTC_cd85d.vcxproj]

0 Warning(s)
1 Error(s)

Time Elapsed 00:00:00.59

File C:/Users/Dingjun.Chen/plplot-5.15.0 .tar/plplot_build/CMakeFiles/CMakeTmp/CheckDIRSymbolExists.c:
/ /

include <sys types.h=""></sys>

include <sys dir.h=""></sys>

int main()
{if ((DIR *) 0) return 0;}

Determining if the DIR symbol is defined as in AC_HEADER_DIRENT failed with the following output:
Change Dir: 'C:/Users/Dingjun.Chen/plplot-5.15.0 .tar/plplot_build/CMakeFiles/CMakeTmp'

Run Build Command(s): "C:/Program Files/Microsoft Visual Studio/2022/Community/MSBuild/Current/Bin/amd64/MSBuild.exe" cmTC_2d104.vcxproj /p:Configuration=Debug /p:Platform=x64 /p:VisualStudioVersion=17.0 /v:n
MSBuild version 17.7.2+d6990bcfa for .NET Framework
Build started 2023-08-28 9:08:31 AM.

Project "C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\cmTC_2d104.vcxproj" on node 1 (default targets).
PrepareForBuild:
Creating directory "cmTC_2d104.dir\Debug\".
Creating directory "C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\Debug\".
Creating directory "cmTC_2d104.dir\Debug\cmTC_2d104.tlog\".
InitializeBuildStatus:
Creating "cmTC_2d104.dir\Debug\cmTC_2d104.tlog\unsuccessfulbuild" because "AlwaysCreate" was specified.
Touching "cmTC_2d104.dir\Debug\cmTC_2d104.tlog\unsuccessfulbuild".
ClCompile:
C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.37.32822\bin\HostX64\x64\CL.exe /c /Zi /W3 /WX- /diagnostics:column /Od /Ob0 /D _MBCS /D WIN32 /D _WINDOWS /D "CMAKE_INTDIR=\"Debug\"" /Gm- /RTC1 /MDd /GS /fp:precise /Zc:wchar_t /Zc:forScope /Zc:inline /Fo"cmTC_2d104.dir\Debug\" /Fd"cmTC_2d104.dir\Debug\vc143.pdb" /external:W3 /Gd /TC /errorReport:queue "C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\CheckDIRSymbolExists.c"
Microsoft (R) C/C++ Optimizing Compiler Version 19.37.32822 for x64
Copyright (C) Microsoft Corporation. All rights reserved.
cl /c /Zi /W3 /WX- /diagnostics:column /Od /Ob0 /D _MBCS /D WIN32 /D _WINDOWS /D "CMAKE_INTDIR=\"Debug\"" /Gm- /RTC1 /MDd /GS /fp:precise /Zc:wchar_t /Zc:forScope /Zc:inline /Fo"cmTC_2d104.dir\Debug\" /Fd"cmTC_2d104.dir\Debug\vc143.pdb" /external:W3 /Gd /TC /errorReport:queue "C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\CheckDIRSymbolExists.c"
CheckDIRSymbolExists.c
C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\CheckDIRSymbolExists.c(3,10): fatal error C1083: Cannot open include file: 'ndir.h': No such file or directory [C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\cmTC_2d104.vcxproj]
Done Building Project "C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\cmTC_2d104.vcxproj" (default targets) -- FAILED.

Build FAILED.

"C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\cmTC_2d104.vcxproj" (default target) (1) ->
(ClCompile target) ->
C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\CheckDIRSymbolExists.c(3,10): fatal error C1083: Cannot open include file: 'ndir.h': No such file or directory [C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\cmTC_2d104.vcxproj]

0 Warning(s)
1 Error(s)

Time Elapsed 00:00:00.57

File C:/Users/Dingjun.Chen/plplot-5.15.0 .tar/plplot_build/CMakeFiles/CMakeTmp/CheckDIRSymbolExists.c:
/ /

include <sys types.h=""></sys>

include <ndir.h></ndir.h>

int main()
{if ((DIR *) 0) return 0;}

Determining whether C compiler is NaN aware failed with the following output:
Change Dir: 'C:/Users/Dingjun.Chen/plplot-5.15.0 .tar/plplot_build/CMakeFiles/CMakeTmp'

Run Build Command(s): "C:/Program Files/Microsoft Visual Studio/2022/Community/MSBuild/Current/Bin/amd64/MSBuild.exe" cmTC_567b0.vcxproj /p:Configuration=Debug /p:Platform=x64 /p:VisualStudioVersion=17.0 /v:n
MSBuild version 17.7.2+d6990bcfa for .NET Framework
Build started 2023-08-28 9:09:20 AM.

Project "C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\cmTC_567b0.vcxproj" on node 1 (default targets).
PrepareForBuild:
Creating directory "cmTC_567b0.dir\Debug\".
Creating directory "C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\Debug\".
Creating directory "cmTC_567b0.dir\Debug\cmTC_567b0.tlog\".
InitializeBuildStatus:
Creating "cmTC_567b0.dir\Debug\cmTC_567b0.tlog\unsuccessfulbuild" because "AlwaysCreate" was specified.
Touching "cmTC_567b0.dir\Debug\cmTC_567b0.tlog\unsuccessfulbuild".
ClCompile:
C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.37.32822\bin\HostX64\x64\CL.exe /c /I"C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot-5.15.0\lib\csa" /Zi /W3 /WX- /diagnostics:column /Od /Ob0 /D _MBCS /D WIN32 /D _WINDOWS /D "CMAKE_INTDIR=\"Debug\"" /Gm- /RTC1 /MDd /GS /fp:precise /Zc:wchar_t /Zc:forScope /Zc:inline /Fo"cmTC_567b0.dir\Debug\" /Fd"cmTC_567b0.dir\Debug\vc143.pdb" /external:W3 /Gd /TC /errorReport:queue "C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot-5.15.0\cmake\modules\TestNaNAware.c"
Microsoft (R) C/C++ Optimizing Compiler Version 19.37.32822 for x64
Copyright (C) Microsoft Corporation. All rights reserved.
cl /c /I"C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot-5.15.0\lib\csa" /Zi /W3 /WX- /diagnostics:column /Od /Ob0 /D _MBCS /D WIN32 /D _WINDOWS /D "CMAKE_INTDIR=\"Debug\"" /Gm- /RTC1 /MDd /GS /fp:precise /Zc:wchar_t /Zc:forScope /Zc:inline /Fo"cmTC_567b0.dir\Debug\" /Fd"cmTC_567b0.dir\Debug\vc143.pdb" /external:W3 /Gd /TC /errorReport:queue "C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot-5.15.0\cmake\modules\TestNaNAware.c"
TestNaNAware.c
C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.37.32822\include\yvals_core.h(28): STL1003: Unexpected compiler, expected C++ compiler.
C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.37.32822\include\yvals_core.h(29,1): fatal error C1189: #error: Error in C++ Standard Library usage [C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\cmTC_567b0.vcxproj]
Done Building Project "C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\cmTC_567b0.vcxproj" (default targets) -- FAILED.

Build FAILED.

"C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\cmTC_567b0.vcxproj" (default target) (1) ->
(ClCompile target) ->
C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.37.32822\include\yvals_core.h(29,1): fatal error C1189: #error: Error in C++ Standard Library usage [C:\Users\Dingjun.Chen\plplot-5.15.0 .tar\plplot_build\CMakeFiles\CMakeTmp\cmTC_567b0.vcxproj]

0 Warning(s)
1 Error(s)

Time Elapsed 00:00:00.78