Open3D
Open3D copied to clipboard
GUI/WebRTC/`ext_civetweb` error on latest MSVC (2022): `invalid numeric argument '/Wextra'`
Checklist
- [X] I have searched for similar issues.
- [X] For Python issues, I have tested with the latest development wheel.
- [X] I have checked the release documentation and the latest documentation (for
mainbranch).
Steps to reproduce the issue
I first cloned Open3D by:
git clone https://github.com/isl-org/Open3D.git
cd Open3D
Then, I build Open3D (on Windows 11 with VS2022, latest MSVC) with:
mkdir build
cd build
cmake -DBUILD_SHARED_LIBS=OFF -DBUILD_CUDA_MODULE=OFF -DBUILD_WEBRTC=ON -DBUILD_GUI=ON ..
# Then Open Visual Studio 2022 and build Open3D (or just the ext_civetweb target).
Error message
[12/148] Performing build step for 'ext_civetweb'
C:\Users\User\Projects\open3d\Open3D\out\build\x64-RelWithDebInfo\Open3D\cl : Command line error D8021: invalid numeric argument '/Wextra'
Open3D, Python and System information
- Operating system: Windows 11 64-bit
- Python version: not applicable
- Open3D version: latest main (8 Apr 2024)
- System architecture: x64
- Is this a remote workstation?: no
- How did you install Open3D?: build from source
- Compiler version (if built from source): Microsoft (R) C/C++ Optimizing Compiler Version 19.39.33523 for x64
Additional information
When building Open3D with GUI/WebRTC, it builds civetweb, which adds a command-line flag -Wextra to the build, but this flag is unknown for the MSVC compiler. It looks like probably previous versions of MSVC silently ignored the unknown compiler flag or just produced a warning, but latest versions of MSVC hard-error on this.