Unreal Engine unable to build

Hi i am trying to build UnrealEngine-4.10
i have clang35 from aur and latest mono6 and dotnet
I did ./Setup.sh everything went fine then messed up for clnag but however got clang35 from aur the only left dependency is mono3 idk if this is the reason of error or not .
But i ran ./GenerateProjectFiles.sh then make i know its not make but i want all library including debug and rather selecting all i ran make

after running make i got errors and here are the whole mess i did

╭─gunit at gunit in /home2/UnrealEngine-4.10
╰─λ ./GenerateProjectFiles.sh

Setting up Unreal Engine 4 project files...

+ xbuild Source/Programs/UnrealBuildTool/UnrealBuildTool.csproj /verbosity:quiet /nologo /p:TargetFrameworkVersion=v4.0 /p:Configuration=Development
+ mono Binaries/DotNET/UnrealBuildTool.exe -makefile -kdevelopfile -qmakefile -cmakefile -codelitefile
Using clang version '3.5.2' (string), 3 (major), 5 (minor), 2 (patch)
Generating data for project indexing... 100%
Generating data for project indexing... 100%
Generating data for project indexing... 100%
Generating data for project indexing... 100%
Writing project files... 100%
+ set +x
╭─gunit at gunit in /home2/UnrealEngine-4.10
╰─λ make
bash "/home2/UnrealEngine-4.10"/Engine/Build/BatchFiles/Linux/Build.sh CrashReportClient Linux Development  
Building CrashReportClient...
Using clang version '3.5.2' (string), 3 (major), 5 (minor), 2 (patch)
Creating makefile for CrashReportClient (no existing makefile)
Performing full C++ include scan (no include cache file)
Building UnrealHeaderTool...
Using clang version '3.5.2' (string), 3 (major), 5 (minor), 2 (patch)
Creating makefile for UnrealHeaderTool (no existing makefile)
Performing 21 actions (2 in parallel)
[1/21] Compile CorePrivatePCH.h
[2/21] Compile Module.Json.cpp
In file included from /home2/UnrealEngine-4.10/Engine/Intermediate/Build/Linux/x86_64-unknown-linux-gnu/UnrealHeaderTool/Development/Json/Module.Json.cpp:2:
In file included from /home2/UnrealEngine-4.10/Engine/Source/Runtime/Json/Private/JsonModule.cpp:3:
In file included from Runtime/Json/Private/JsonPrivatePCH.h:5:
In file included from Runtime/Json/Public/Json.h:9:
In file included from Runtime/Core/Public/Core.h:16:
In file included from Runtime/Core/Public/HAL/PlatformIncludes.h:53:
In file included from Runtime/Core/Public/Linux/LinuxPlatformIncludes.h:10:
Runtime/Core/Public/Linux/LinuxSystemIncludes.h:32:10: fatal error: 'sys/sysctl.h' file not found
#include <sys/sysctl.h>
         ^
In file included from /home2/UnrealEngine-4.10/Engine/Intermediate/Build/Linux/x86_64-unknown-linux-gnu/UnrealHeaderTool/Development/Core/CorePrivatePCH.h:4:
In file included from /home2/UnrealEngine-4.10/Engine/Source/Runtime/Core/Private/CorePrivatePCH.h:16:
In file included from Runtime/Core/Public/HAL/PlatformIncludes.h:53:
In file included from Runtime/Core/Public/Linux/LinuxPlatformIncludes.h:10:
Runtime/Core/Public/Linux/LinuxSystemIncludes.h:32:10: fatal error: 'sys/sysctl.h' file not found
#include <sys/sysctl.h>
         ^
1 error generated.
[3/21] Compile Module.Projects.cpp
1 error generated.
In file included from /home2/UnrealEngine-4.10/Engine/Intermediate/Build/Linux/x86_64-unknown-linux-gnu/UnrealHeaderTool/Development/Projects/Module.Projects.cpp:2:
In file included from /home2/UnrealEngine-4.10/Engine/Source/Runtime/Projects/Private/ProjectsPrivatePCH.h:6:
In file included from Runtime/Projects/Public/Projects.h:9:
In file included from Runtime/Core/Public/Core.h:16:
In file included from Runtime/Core/Public/HAL/PlatformIncludes.h:53:
In file included from Runtime/Core/Public/Linux/LinuxPlatformIncludes.h:10:
Runtime/Core/Public/Linux/LinuxSystemIncludes.h:32:10: fatal error: 'sys/sysctl.h' file not found
#include <sys/sysctl.h>
         ^
[4/21] Compile Module.CoreUObject.1_of_4.cpp
In file included from /home2/UnrealEngine-4.10/Engine/Intermediate/Build/Linux/x86_64-unknown-linux-gnu/UnrealHeaderTool/Development/CoreUObject/Module.CoreUObject.1_of_4.cpp:2:
In file included from /home2/UnrealEngine-4.10/Engine/Source/Runtime/CoreUObject/Private/CoreUObjectPrivate.h:10:
In file included from Runtime/Core/Public/Core.h:16:
In file included from Runtime/Core/Public/HAL/PlatformIncludes.h:53:
In file included from Runtime/Core/Public/Linux/LinuxPlatformIncludes.h:10:
Runtime/Core/Public/Linux/LinuxSystemIncludes.h:32:10: fatal error: 'sys/sysctl.h' file not found
#include <sys/sysctl.h>
         ^
1 error generated.
[5/21] Compile Module.CoreUObject.2_of_4.cpp
In file included from /home2/UnrealEngine-4.10/Engine/Intermediate/Build/Linux/x86_64-unknown-linux-gnu/UnrealHeaderTool/Development/CoreUObject/Module.CoreUObject.2_of_4.cpp:2:
In file included from /home2/UnrealEngine-4.10/Engine/Source/Runtime/CoreUObject/Private/CoreUObjectPrivate.h:10:
In file included from Runtime/Core/Public/Core.h:16:
In file included from Runtime/Core/Public/HAL/PlatformIncludes.h:53:
In file included from Runtime/Core/Public/Linux/LinuxPlatformIncludes.h:10:
Runtime/Core/Public/Linux/LinuxSystemIncludes.h:32:10: fatal error: 'sys/sysctl.h' file not found
#include <sys/sysctl.h>
         ^
1 error generated.
[6/21] Compile Module.CoreUObject.3_of_4.cpp
In file included from /home2/UnrealEngine-4.10/Engine/Intermediate/Build/Linux/x86_64-unknown-linux-gnu/UnrealHeaderTool/Development/CoreUObject/Module.CoreUObject.3_of_4.cpp:2:
In file included from /home2/UnrealEngine-4.10/Engine/Source/Runtime/CoreUObject/Private/CoreUObjectPrivate.h:10:
In file included from Runtime/Core/Public/Core.h:16:
In file included from Runtime/Core/Public/HAL/PlatformIncludes.h:53:
In file included from Runtime/Core/Public/Linux/LinuxPlatformIncludes.h:10:
Runtime/Core/Public/Linux/LinuxSystemIncludes.h:32:10: fatal error: 'sys/sysctl.h' file not found
#include <sys/sysctl.h>
         ^
1 error generated.
[7/21] Compile Module.CoreUObject.4_of_4.cpp
In file included from /home2/UnrealEngine-4.10/Engine/Intermediate/Build/Linux/x86_64-unknown-linux-gnu/UnrealHeaderTool/Development/CoreUObject/Module.CoreUObject.4_of_4.cpp:2:
In file included from /home2/UnrealEngine-4.10/Engine/Source/Runtime/CoreUObject/Private/CoreUObjectPrivate.h:10:
In file included from Runtime/Core/Public/Core.h:16:
In file included from Runtime/Core/Public/HAL/PlatformIncludes.h:53:
In file included from Runtime/Core/Public/Linux/LinuxPlatformIncludes.h:10:
Runtime/Core/Public/Linux/LinuxSystemIncludes.h:32:10: fatal error: 'sys/sysctl.h' file not found
#include <sys/sysctl.h>
         ^
1 error generated.
[8/21] Compile Module.ScriptGeneratorPlugin.cpp
In file included from /home2/UnrealEngine-4.10/Engine/Plugins/ScriptGeneratorPlugin/Intermediate/Build/Linux/x86_64-unknown-linux-gnu/UnrealHeaderTool/Development/ScriptGeneratorPlugin/Module.ScriptGeneratorPlugin.cpp:2:
In file included from /home2/UnrealEngine-4.10/Engine/Plugins/ScriptGeneratorPlugin/Source/ScriptGeneratorPlugin/Private/GenericScriptCodeGenerator.cpp:2:
In file included from /home2/UnrealEngine-4.10/Engine/Plugins/ScriptGeneratorPlugin/Source/ScriptGeneratorPlugin/Private/ScriptGeneratorPluginPrivatePCH.h:5:
In file included from ../Plugins/ScriptGeneratorPlugin/Source/ScriptGeneratorPlugin/Public/IScriptGeneratorPlugin.h:5:
In file included from Programs/UnrealHeaderTool/Public/IScriptGeneratorPluginInterface.h:4:
In file included from Runtime/Core/Public/Modules/ModuleManager.h:5:
In file included from Runtime/Core/Public/Modules/ModuleInterface.h:6:
In file included from Runtime/Core/Public/Core.h:16:
In file included from Runtime/Core/Public/HAL/PlatformIncludes.h:53:
In file included from Runtime/Core/Public/Linux/LinuxPlatformIncludes.h:10:
Runtime/Core/Public/Linux/LinuxSystemIncludes.h:32:10: fatal error: 'sys/sysctl.h' file not found
#include <sys/sysctl.h>
         ^
1 error generated.
[9/21] Compile Module.UnrealHeaderTool.cpp
In file included from /home2/UnrealEngine-4.10/Engine/Intermediate/Build/Linux/x86_64-unknown-linux-gnu/UnrealHeaderTool/Development/UnrealHeaderTool/Module.UnrealHeaderTool.cpp:2:
In file included from /home2/UnrealEngine-4.10/Engine/Source/Programs/UnrealHeaderTool/Public/UnrealHeaderTool.h:7:
In file included from Runtime/Core/Public/Core.h:16:
In file included from Runtime/Core/Public/HAL/PlatformIncludes.h:53:
In file included from Runtime/Core/Public/Linux/LinuxPlatformIncludes.h:10:
Runtime/Core/Public/Linux/LinuxSystemIncludes.h:32:10: fatal error: 'sys/sysctl.h' file not found
#include <sys/sysctl.h>
         ^
1 error generated.
1 error generated.
-------- End Detailed Actions Stats -----------------------------------------------------------
ERROR: UBT ERROR: Failed to produce item: /home2/UnrealEngine-4.10/Engine/Binaries/Linux/libUnrealHeaderTool-Core.so
Total build time: 24.24 seconds
UnrealHeaderTool failed for target 'CrashReportClient' (platform: Linux, module info: /home2/UnrealEngine-4.10/Engine/Intermediate/Build/Linux/x86_64-unknown-linux-gnu/CrashReportClient/Development/UnrealHeaderTool.manifest).
make: *** [Makefile:263: CrashReportClient] Error 5

I tried downgrading mono by editing pacman.conf but this also gave errors

╭─gunit at gunit in /home2/UnrealEngine-4.10
╰─λ sudo pacman -Syy mono
:: Synchronizing package databases...
 arcolinux_repo                                                                          97.0 KiB  51.9 KiB/s 00:02 [---------------------------------------------------------------------] 100%
 arcolinux_repo_3party                                                                  174.5 KiB  46.7 KiB/s 00:04 [---------------------------------------------------------------------] 100%
 arcolinux_repo_xlarge                                                                   30.1 KiB  20.2 KiB/s 00:01 [---------------------------------------------------------------------] 100%
 core                                                                                   137.9 KiB   189 KiB/s 00:01 [---------------------------------------------------------------------] 100%
 extra                                                                                 1804.5 KiB   201 KiB/s 00:09 [---------------------------------------------------------------------] 100%
 community                                                                                5.8 MiB  2.68 MiB/s 00:02 [---------------------------------------------------------------------] 100%
 multilib                                                                               150.3 KiB   367 KiB/s 00:00 [---------------------------------------------------------------------] 100%
warning: downgrading package mono (6.12.0.122-1 => 3.12.0-1)
resolving dependencies...
looking for conflicting packages...

Package (1)  Old Version   New Version  Net Change   Download Size

extra/mono   6.12.0.122-1  3.12.0-1     -111.43 MiB      31.42 MiB

Total Download Size:     31.42 MiB
Total Installed Size:   139.72 MiB
Net Upgrade Size:      -111.43 MiB

:: Proceed with installation? [Y/n] y
:: Retrieving packages...
 mono-3.12.0-1-x86_64                                                                    31.4 MiB   409 KiB/s 01:19 [---------------------------------------------------------------------] 100%
(1/1) checking keys in keyring                                                                                      [---------------------------------------------------------------------] 100%
(1/1) checking package integrity                                                                                    [---------------------------------------------------------------------] 100%
error: mono: key "Daniel Isenmann <daniel@archlinux.org>" is disabled
:: File /var/cache/pacman/pkg/mono-3.12.0-1-x86_64.pkg.tar.xz is corrupted (invalid or corrupted package (PGP signature)).
Do you want to delete it? [Y/n] y
error: failed to commit transaction (invalid or corrupted package (PGP signature))
Errors occurred, no packages were upgraded.
╭─gunit at gunit in /home2/UnrealEngine-4.10
╰─λ sudo pacman -Syy mono
:: Synchronizing package databases...
 arcolinux_repo                                                                          97.0 KiB  56.1 KiB/s 00:02 [---------------------------------------------------------------------] 100%
 arcolinux_repo_3party                                                                  174.5 KiB  79.3 KiB/s 00:02 [---------------------------------------------------------------------] 100%
 arcolinux_repo_xlarge                                                                   30.1 KiB  21.4 KiB/s 00:01 [---------------------------------------------------------------------] 100%
 core                                                                                   137.9 KiB   186 KiB/s 00:01 [---------------------------------------------------------------------] 100%
 extra                                                                                 1804.5 KiB   220 KiB/s 00:08 [---------------------------------------------------------------------] 100%
 community                                                                                5.8 MiB  1534 KiB/s 00:04 [---------------------------------------------------------------------] 100%
 multilib                                                                               150.3 KiB   224 KiB/s 00:01 [---------------------------------------------------------------------] 100%
warning: downgrading package mono (6.12.0.122-1 => 3.12.0-1)
resolving dependencies...
looking for conflicting packages...

Package (1)  Old Version   New Version  Net Change   Download Size

extra/mono   6.12.0.122-1  3.12.0-1     -111.43 MiB      31.42 MiB

Total Download Size:     31.42 MiB
Total Installed Size:   139.72 MiB
Net Upgrade Size:      -111.43 MiB

:: Proceed with installation? [Y/n] 
:: Retrieving packages...
 mono-3.12.0-1-x86_64                                                                    31.4 MiB   400 KiB/s 01:20 [---------------------------------------------------------------------] 100%
(1/1) checking keys in keyring                                                                                      [---------------------------------------------------------------------] 100%
(1/1) checking package integrity                                                                                    [---------------------------------------------------------------------] 100%
error: mono: key "Daniel Isenmann <daniel@archlinux.org>" is disabled
:: File /var/cache/pacman/pkg/mono-3.12.0-1-x86_64.pkg.tar.xz is corrupted (invalid or corrupted package (PGP signature)).
Do you want to delete it? [Y/n] y
error: failed to commit transaction (invalid or corrupted package (PGP signature))
Errors occurred, no packages were upgraded.

again and again this error come when i try to install mono
plz help me fix this

i however installed mono3 and here comes new errors

╭─gunit at gunit in /home2/UnrealEngine-4.10
╰─λ make
bash "/home2/UnrealEngine-4.10"/Engine/Build/BatchFiles/Linux/Build.sh CrashReportClient Linux Development  

Unhandled Exception:
System.TypeInitializationException: An exception was thrown by the type initializer for System.Console ---> System.TypeInitializationException: An exception was thrown by the type initializer for System.ConsoleDriver ---> System.Exception: Magic number is wrong: 542
  at System.TermInfoReader.ReadHeader (System.Byte[] buffer, System.Int32& position) [0x00000] in <filename unknown>:0 
  at System.TermInfoReader..ctor (System.String term, System.String filename) [0x00000] in <filename unknown>:0 
  at System.TermInfoDriver..ctor (System.String term) [0x00000] in <filename unknown>:0 
  at System.ConsoleDriver.CreateTermInfoDriver (System.String term) [0x00000] in <filename unknown>:0 
  at System.ConsoleDriver..cctor () [0x00000] in <filename unknown>:0 
  --- End of inner exception stack trace ---
  at System.Console.SetupStreams (System.Text.Encoding inputEncoding, System.Text.Encoding outputEncoding) [0x00000] in <filename unknown>:0 
  at System.Console..cctor () [0x00000] in <filename unknown>:0 
  --- End of inner exception stack trace ---
  at Mono.XBuild.CommandLine.ConsoleReportPrinter..ctor () [0x00000] in <filename unknown>:0 
  at Mono.XBuild.CommandLine.MainClass.Execute () [0x00000] in <filename unknown>:0 
  at Mono.XBuild.CommandLine.MainClass.Main (System.String[] args) [0x00000] in <filename unknown>:0 
Failed to build to build tool (UnrealBuildTool)
make: *** [Makefile:263: CrashReportClient] Error 1
╭─gunit at gunit in /home2/UnrealEngine-4.10

i solved it , i just build clang 3.6 from source not from extra then everything is working fine

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.