Search Issue Tracker

Won't Fix

Votes

1

Found in

2023.1.0a1

Issue ID

UUM-1132

Regression

No

[Web] Project doesn't build when a version file is included

--

-

When a VERSION file with a version number in it is added to the root directory of a project, and then built to WebGL, the build breaks.

Steps to reproduce:
1. Create a 3D project (or URP, probably any type).
2. Add a VERSION file to the root directory of the project that has a version number inside.
3. Switch to WebGL and Build

Expected Result:
The project builds successfully.

Actual Result:
The project does not build and build errors show up in the console (70 errors)

Note: the native macOS build is successfully

The errors are of this form:
Building Library/Bee/artifacts/WebGL/il2cpp/master_WebGL_wasm/5z9b_stem0.lump.o failed with output:
In file included from Library/Bee/artifacts/WebGL/il2cpp/master_WebGL_wasm/w90z_System0.lump.cpp:2:
In file included from /Applications/Unity/Hub/Editor/2022.1.0f1/Unity.app/Contents/il2cpp/libil2cpp/icalls/mscorlib/System.Text/EncodingHelper.cpp:3:
In file included from /Applications/Unity/Hub/Editor/2022.1.0f1/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/emscripten/cache/sysroot/include/c++/v1/string:504:
In file included from /Applications/Unity/Hub/Editor/2022.1.0f1/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/emscripten/cache/sysroot/include/c++/v1/string_view:175:
In file included from /Applications/Unity/Hub/Editor/2022.1.0f1/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/emscripten/cache/sysroot/include/c++/v1/__string:57:
In file included from /Applications/Unity/Hub/Editor/2022.1.0f1/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/emscripten/cache/sysroot/include/c++/v1/algorithm:639:
In file included from /Applications/Unity/Hub/Editor/2022.1.0f1/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/emscripten/cache/sysroot/include/c++/v1/initializer_list:46:
In file included from /Applications/Unity/Hub/Editor/2022.1.0f1/PlaybackEngines/WebGLSupport/BuildTools/Emscripten/emscripten/cache/sysroot/include/c++/v1/cstddef:37:
./version:1:1: error: expected unqualified-id
0.32.4

  1. Resolution Note:

    There is a header file named "version" in the C++ standard library. On some platforms, the "version" file in the project is being picked up instead. As a workaround, please change this file name, so that it does not conflict with the same named file in the C++ standard library.

Comments (1)

  1. ianjirka

    Oct 13, 2022 22:41

    I also hit this.

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.