View Issue Details

IDProjectCategoryView StatusLast Update
0001500bareos-coreGeneralpublic2023-10-11 16:20
Reportermdc Assigned Tobruno-at-bareos  
PrioritynormalSeverityblockReproducibilityalways
Status closedResolutionsuspended 
Platformx86_64OSWindowsOS VersionWin10
Product Version21.1.6 
Summary0001500: Build on Windows using the MSVC fails, because of invalid compiler flags
DescriptionThe cmake config part runs fine, but the compile part fails because of invalid compiler options.
At the summary page of the cmake run, the invalid compiler flags are show:
C Compiler: C:/Program Files/Microsoft Visual Studio/2022/Community/VC/Tools/MSVC/14.34.31933/bin/Hostx64/x64/cl.exe 19.34.31937.0
C++ Compiler: C:/Program Files/Microsoft Visual Studio/2022/Community/VC/Tools/MSVC/14.34.31933/bin/Hostx64/x64/cl.exe 19.34.31937.0
C Compiler flags: /DWIN32 /D_WINDOWS /W3 -Werror -Wall
C++ Compiler flags: /DWIN32 /D_WINDOWS /W3 /GR /EHsc -Werror -Wall -m64 -mwin32 -mthreads
Linker flags: /machine:x64 /machine:x64 /machine:x64 /machine:x64

The build it self fails with:
[ 1%] Building CXX object core/src/lib/CMakeFiles/version-obj.dir/version.cc.obj
cl : Befehlszeile error D8021 : Ungültiges numerisches Argument /Werror.
NMAKE : fatal error U1077: ""C:\Program Files\CMake\bin\cmake.exe"": Rückgabe-Code "0x2"
Stop.
NMAKE : fatal error U1077: ""C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.34.31933\bin\HostX64\x64\nmake.exe"": Rückgabe-Code "0x2"
Stop.
NMAKE : fatal error U1077: ""C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.34.31933\bin\HostX64\x64\nmake.exe"": Rückgabe-Code "0x2"
Stop.


Steps To ReproduceCall:
cmake -B bauen -DENABLE_PYTHON=OFF -DENABLE_JANSSON=OFF -DENABLE_BCONSOLE=OFF -Dclient-only=ON -DCMAKE_PREFIX_PATH="c:\zlib" -DOPENSSL_ROOT_DIR="c:\openssl"
cmake --build bauen
Additional InformationUsing Visual Studio Community 2022.

As I understand the Microsoft compiler don't know the "gcc Wxxx" options.
TagsNo tags attached.

Activities

bruno-at-bareos

bruno-at-bareos

2023-09-04 16:30

manager   ~0005365

So work are in progress to make possible to build Bareos with Microsoft Visual CPP.
It is still uncertain this will be done for 23.
bruno-at-bareos

bruno-at-bareos

2023-10-11 16:20

manager   ~0005461

The build of Bareos with MSVC will happen during development of release 24 starting in November 2023.

Issue History

Date Modified Username Field Change
2022-12-19 13:35 mdc New Issue
2023-09-04 16:30 bruno-at-bareos Assigned To => bruno-at-bareos
2023-09-04 16:30 bruno-at-bareos Status new => acknowledged
2023-09-04 16:30 bruno-at-bareos Note Added: 0005365
2023-10-11 16:20 bruno-at-bareos Status acknowledged => closed
2023-10-11 16:20 bruno-at-bareos Resolution open => suspended
2023-10-11 16:20 bruno-at-bareos Note Added: 0005461