Hi there, I’d like to run Unreal Editor on my machine which is running Fedora 34, everything is fine when I was running ./Setup.sh and ./GenerateProjectFiles.sh, but after I started to run the make command, I got this error :
Performing 7 actions (8 in parallel)
[1/7] Compile Module.ShaderCompilerCommon.cpp
In file included from /home//文件/Unreal Engine/UnrealEngine-ue5-early-access/Engine/Intermediate/Build/Linux/B4D820EA/ShaderCompileWorker/Development/ShaderCompilerCommon/Module.ShaderCompilerCommon.cpp:6:
In file included from /home//文件/Unreal Engine/UnrealEngine-ue5-early-access/Engine/Source/Developer/ShaderCompilerCommon/Private/HlslUtils.cpp:11:
In file included from Developer/ShaderCompilerCommon/Public/ShaderCompilerCommon.h:6:
In file included from Runtime/RenderCore/Public/UniformBuffer.h:9:
In file included from Runtime/RenderCore/Public/ShaderParameterMacros.h:10:
In file included from Runtime/RenderCore/Public/ShaderParameterMetadata.h:12:
In file included from Runtime/RHI/Public/RHI.h:2390:
/home//文件/Unreal Engine/UnrealEngine-ue5-early-access/Engine/Source/Runtime/RHI/Public/RHIResources.h:2910:5: error: expected class member or base class name
, ArraySize(InArraySize)
^
/home//文件/Unreal Engine/UnrealEngine-ue5-early-access/Engine/Source/Developer/ShaderCompilerCommon/Private/HlslLexer.cpp:13:26: note: expanded from macro 'ArraySize'
#define ArraySize(array) (sizeof(ArraySizeHelper(array)))
^
1 error generated.
make: *** [Makefile:763:ShaderCompileWorker] Error 6
Is there anyone who knows how to deal with this problem?
I’ve just searched google, but it doesn’t help.
could you please try compiling some parts to see if it succeeds, thus making sure that everything is working.
make ARGS=“-clean” UnrealLightmass && make UnrealLightmass
make ARGS=“-clean” ShaderCompileWorker && make ShaderCompileWorker
if any of the above steps fails could you link more log with something like to pastebin.
I too have a fedora 34 setup on another ue5 branch.
Also for every cpu thread you should have around 2gb of ram.
Try these also:
do you have full folder permissions the source directory
I finally change source code of HlslLexer.cpp. because of the stupid compiler.image|568x330
The initialize function of FRHITextureCreateInfo that init “ArraySize” member.
I just wander why does this compiler will treat class member as macro.
I have the exact same issue, but I don’t understand how to fix it. I went to HlslLexer.cpp and try few things but none of them work… would you mind explaining to me how you fixed it? (I am using Debian 11)
Running command : Engine/Binaries/DotNET/UnrealBuildTool/UnrealBuildTool ShaderCompileWorker Linux Development
Linux using Manual SDK v17_clang-10.0.1-centos7
Using 'git status' to determine working set for adaptive non-unity build (/xxx/UnrealEngine-5.0.0-early-access-1).
Building ShaderCompileWorker...
Performing 7 actions (16 in parallel)
[1/7] Compile Module.ShaderCompilerCommon.cpp
In file included from /xxx/UnrealEngine-5.0.0-early-access-1/Engine/Intermediate/Build/Linux/B4D820EA/ShaderCompileWorker/Development/ShaderCompilerCommon/Module.ShaderCompilerCommon.cpp:6:
In file included from /xxx/UnrealEngine-5.0.0-early-access-1/Engine/Source/Developer/ShaderCompilerCommon/Private/HlslUtils.cpp:11:
In file included from Developer/ShaderCompilerCommon/Public/ShaderCompilerCommon.h:6:
In file included from Runtime/RenderCore/Public/UniformBuffer.h:9:
In file included from Runtime/RenderCore/Public/ShaderParameterMacros.h:10:
In file included from Runtime/RenderCore/Public/ShaderParameterMetadata.h:12:
In file included from Runtime/RHI/Public/RHI.h:2390:
/xxx/UnrealEngine-5.0.0-early-access-1/Engine/Source/Runtime/RHI/Public/RHIResources.h:2910:5: error: expected class member or base class name
, ArraySize(InArraySize)
^
/xxx/UnrealEngine-5.0.0-early-access-1/Engine/Source/Developer/ShaderCompilerCommon/Private/HlslLexer.cpp:15:26: note: expanded from macro 'ArraySize'
#define ArraySize(array) (sizeof(ArraySizeHelper(array)))
^
1 error generated.
make: *** [Makefile:763 : ShaderCompileWorker] Erreur 6
Compile Module.DirectLink.cpp
In file included from .../UnrealEngine-ue5-early-access/Engine/Plugins/Experimental/GeometryProcessing/Intermediate/Build/Linux/B4D820EA/UnrealEditor/Development/GeometryAlgorithms/Module.GeometryAlgorithms.cpp:27:
.../UnrealEngine-ue5-early-access/Engine/Plugins/Experimental/GeometryProcessing/Source/GeometryAlgorithms/Private/ThirdParty/GTEngine/Mathematics/GteTetrahedronKey.cpp:78:27: error: explicit specialization of 'TetrahedronKey' after instantiation
TetrahedronKey<true>::TetrahedronKey(int v0, int v1, int v2, int v3)
^
.../UnrealEngine-ue5-early-access/Engine/Plugins/Experimental/GeometryProcessing/Source/GeometryAlgorithms/Private/ThirdParty/GTEngine/Mathematics/GteTSManifoldMesh.cpp:73:26: note: implicit instantiation first required here
TetrahedronKey<true> skey(v0, v1, v2, v3);
^
[871/2990] Compile Module.DMXProtocol.gen.cpp
[872/2990] Compile Module.MaterialBaking.gen.cpp
[873/2990] Compile Module.DatasmithContent.cpp
1 error generated.
Got it working, i used InstalledBuild instead of normal make and it worked, not sure whats the difference. Looks like it gona work on ue5-main branch also.
My script: