Commit Graph

824 Commits

Author SHA1 Message Date
LouisPhilippe Seguin
a21f510ae7 UnrealBuildTool
* Added option to generate assembly files while compiling cpp files.
* Supported only on MSVC compiler for now.
* The generated files have the .asm extension and are located in the same Intermediate folder as the corresponding .obj

#jira none
#rb Joe.Kirchoff
#preflight

[CL 24545403 by LouisPhilippe Seguin in ue5-main branch]
2023-03-07 14:20:51 -05:00
Joe Kirchoff
eb868d8709 UnrealBuildTool: Fix issues with Modified Files Only compiles
#rnx
#rb tivial
#preflight 640294741d304a5471217842

[CL 24511169 by Joe Kirchoff in ue5-main branch]
2023-03-03 19:51:51 -05:00
joe kirchoff
a6e3258893 UnrealBuildTool: If module valdiation is set to Error, raise an exception if any errors are found
#rnx
#jira UE-177808

[CL 24452688 by joe kirchoff in ue5-main branch]
2023-02-28 17:08:32 -05:00
josh adams
4d71aa084a - Fixed .precompiled file location to be architcture independent
- Added IntermediateDirectoryNoArch to UEBuildModule (we can use this in the future to put generated definitions headers, which can help reduce rebuilds going between multi- and single-arch)
#rb Joe.kirchoff
#jira UE-178211,UE-178589
#preflight 63fd3cb72b1a2765f9a46322

[CL 24441385 by josh adams in ue5-main branch]
2023-02-28 09:01:08 -05:00
joe kirchoff
606c42edeb Module include path validation. Disabled until outstanding issues are fixed
#rnx
#jira UE-177808
#rb Tim.Smith

[CL 24412746 by joe kirchoff in ue5-main branch]
2023-02-24 19:01:37 -05:00
bryan sefcik
7dc0758263 Updated UBT to create the shared PCH instances before setting up the modules so all the PCHs and parent PCHs are setup beforehand.
#preflight 63eeb441977ceed915cb4207
#rb joe.kirchoff

[CL 24272192 by bryan sefcik in ue5-main branch]
2023-02-16 18:31:35 -05:00
josh adams
f881608487 - Fixing location for UHT generated headers to not have architecture in the path, because they are per-arch, and with InstalledBuilds, if we made a Universal build, but then user does non-universal, the UHT intermediates would look in a different location than where we put them ('arm64' vs 'arm64+x64')
#jira UE-176191
#preflight 63e401713c44c83044e5b2c3

[CL 24214920 by josh adams in ue5-main branch]
2023-02-14 12:40:03 -05:00
henrik karlsson
5f74d114d5 [UBT]
Changed how single files are built. We don't want to invalidate makefile everytime we build single files since it destroys turnaround times. With this change a single file compile can take 2s (+ the actual compile time).

The new behavior injects a special action per module when creating the makefile. These actions can be used to on-the-fly create a proper compile action that follows the rules of the module that the specific file belongs to.. In a normal build these actions are ignored since the logic deciding which actions to build is backtraced from which binaries we want to create.

When a specific file compile is triggered, the logic deciding which files to build search up all these special actions and create a lookup based on which folders the special actions handle. It then try to find the special action that handles the specific file. The matching special action then creates a compile action that can handle that specific file and then queue up the action for execution. If no special action is found it falls back to try to use actions that have this specific file as input (ispc files for example)

Details:
* Removed lots of custom code for "specific files" handling
* Changed so pch (both private and shared) always use definition file. Added #pragma once and change so pch wrapper file include definition file. This made the adaptive path and specific file easy to implement (just disable pch in compile environment and it will just work)
* Added SingleFileAction for both VCToolChain and ClangToolChain. It now works to compile specific headers and cpp files. (It creates wrapper files on the fly to be able to compile all header files (compiling headers directly blow up if there are circular includes)
* Fixed so GenerateClangDatabase mode works with new changes
* Moved the logic that makes sure all (directly) depending cpp files are recompiled when .h are included in the singlefile option

#preflight 63dcc46f78716a01e8069649
#rb joe.kirchoff

[CL 24094027 by henrik karlsson in ue5-main branch]
2023-02-09 04:20:43 -05:00
chris constantinescu
4e7e7f9f3f LLT cleanup and improvements/updates:
- remove dependency on LaunchEngineLoop.cpp which also allows compilation against engine to succeed
- LowLevelTestsRunner no dependency on engine modules required: Launch, Core, Project
- EXPLICIT_TESTS_TARGET definition for self-contained tests: test modules and targets that derive from TestModuleRules/TestTargetRules respectively
- Cleanup Launch dependencies from existing explicit tests
- Cleanup redundant flags from existing explicit tests
- rename Self -> Foundation for in Horde
- additional platform fixes
Default #preflight 63e14d37244dc45a20e29337
All platform/tests LLTs #preflight 63e022f91b44ee7cb1c11d60
#rnx

[CL 24035900 by chris constantinescu in ue5-main branch]
2023-02-06 14:27:24 -05:00
marc audy
254574121a Restore the setting of UE_USE_VERSE_PATHS
[FYI] Josh.Adams
#rnx

[CL 24007092 by marc audy in ue5-main branch]
2023-02-03 22:41:37 -05:00
joe pribele
378a101376 changed message for circular plugin dependencies to print the cycle per UDN suggestion from Simon Harvey
https://jira.it.epicgames.com/browse/UE-165111

https://p4-swarm.epicgames.net/reviews/23962465

#rb joe.kirchoff
#jira UE-165111
#preflight 63dbe1a97e4c10fe066518ef

[CL 23970883 by joe pribele in ue5-main branch]
2023-02-02 12:34:18 -05:00
joe kirchoff
de91180c39 UnrealBuildTool: Ensure .cpp files found when scanning -SingleFile headers are added to the build list
This can be a lot of files if you request a very common header! For example -SingleFile=Runtime\Core\Public\Containers\Array.h currently would build over 22k UnrealEditor actions

#rnx
#jira UE-131018
#rb Josh.Adams
#preflight 63daa7a38c7003aa8ca997bd

[CL 23960984 by joe kirchoff in ue5-main branch]
2023-02-01 19:25:15 -05:00
henrik karlsson
d4a22c3f50 [UBT]
* Run VNI at the same time as UHT to save wall time
* Changed from linq code to normal parallel.foreach as optimization

#preflight 63d86d93f626715201a3c7e0
#rb joe.kirchoff

[CL 23924114 by henrik karlsson in ue5-main branch]
2023-01-31 01:29:40 -05:00
henrik karlsson
8c4b56c12b [UBT]
* ActionGraphBuilder - Added AllowAsync parameter to CreateIntermediateTextFile which defaults to true.
* UEBuildModuleCPP - Added AllowAsync false to one place where the code touches the file after CreateIntermediateTextFile has been called
* UEBuildModuleCPP - Changed so code writing LiveCodingInfo.json is using same path as others when it comes to writing files

#preflight 63d86264ec3d1af440d22e35
#rb joe.kirchoff

[CL 23924077 by henrik karlsson in ue5-main branch]
2023-01-31 01:28:52 -05:00
Joe Kirchoff
a46c2bb6c1 UnrealBuildTool: Reference any Target.cs files as rules dependencies so modifying them will update the Makefile, as these TargetRules can be referenced
#rnx
#rb Tim.Smith
#jira UE-168481
#preflight 63d7fa38d21dbe1d29525dd3

[CL 23910603 by Joe Kirchoff in ue5-main branch]
2023-01-30 12:31:04 -05:00
Joe Kirchoff
49941df8c8 UnrealBuildTool: Prevent multiple target leaking bundle dependencies on Mac
#rnx
#rb Josh.Adams
#preflight 63d1978cbe435f17b408210c
#preflight 63d1af24be435f17b40e38f4

[CL 23858824 by Joe Kirchoff in ue5-main branch]
2023-01-25 17:55:46 -05:00
Josh Adams
ebcd0d21df - Fixing Arch parsing from commandline (only UnrealArch.Parse was allowing for alternate names, not UnrealArch.TryParse)
#rb thomas.engel
#preflight 63d040e5976daa618cc57da2

[CL 23837393 by Josh Adams in ue5-main branch]
2023-01-24 15:58:36 -05:00
josh adams
1610c3bee3 UnrealArch/UnrealArchitectures changes
- Creates the UnrealArchitectures class, which wraps a list of UnrealArch objects
 - UnrealArch is a single architecture, expandable enum-like struct
 - There is no more concept of "no/default architecture", there is always a valid active architecture when building
 - Most uses of "string Architecture" are replaced with one of the two above, depending if multiple architectures are supported or not
 - UnrealArch has some platform-extensions for platform-specific naming (like Linux adds in LinuxName that turns, for instance, Arm64 -> aarch64-unknown-linux-gnueabi, which is used in folder names, etc)
 - UnrealArch has bIsX64 which can be used determine intel instruction set (as opposed to arm)
 - TargetRules class has an "Architecture" accessor that will return a single architecture if the active architectures is a single architecture, or throw an exception if multiple. This is useful in a majority of the cases where a paltform can only have a single architecture active in TargetRules (microsoft platforms, for instance, will create separate targets when compiling multiple architectures at once)
 - Added UnrealArchitectureConfig class, which contains all the architecture information for a platform (what architectures are supported, what ones are currently active for given project, etc)

#preflight 63c81fb5b065224750a1759e
#rb mike.fricker,roman.dzieciol,joe.kirchoff,dmytro.vovk,brandon.schaefer [various parts]
#p4v-preflight-copy 23562471

[CL 23829977 by josh adams in ue5-main branch]
2023-01-24 09:30:28 -05:00
Joe Kirchoff
08c9da4050 UnrealBuildTool: Don't merge actions that ignore conflicts
#rnx
#rb trivial
#preflight 63cf3c0ad83c1837b161147a

[CL 23826242 by Joe Kirchoff in ue5-main branch]
2023-01-23 21:21:25 -05:00
Tim Smith
106b956993 Remove C++ UHT as the UHT to be used to generate headers. This does not remove the ability to build C++ UHT as a target.
#rb joe.kirchoff
#preflight 63c84257fb1a8cf245e538c4

[CL 23761220 by Tim Smith in ue5-main branch]
2023-01-18 14:14:27 -05:00
joe kirchoff
0b859cfb27 [Backout] - CL23749664
#fyi Joe.Kirchoff
Original CL Desc
-----------------------------------------------------------------
UnrealBuildTool: Fix Action conflict when writing out metadata by ensuring the .version file is written first, then write the .modules and .target files in separate steps that load that version file

#rnx
#rb Josh.Adams
#preflight 63c73b8e7763631ba167e292

[CL 23758203 by joe kirchoff in ue5-main branch]
2023-01-18 12:11:21 -05:00
Joe Kirchoff
b0476f93e7 UnrealBuildTool: Fix Action conflict when writing out metadata by ensuring the .version file is written first, then write the .modules and .target files in separate steps that load that version file
#rnx
#rb Josh.Adams
#preflight 63c73b8e7763631ba167e292

[CL 23749664 by Joe Kirchoff in ue5-main branch]
2023-01-17 19:38:31 -05:00
Joe Kirchoff
4a262359a0 UnrealBuildTool: Store Action file lists in SortedSets rather than Lists, since these collections should never have duplicate entries and sorting them helps when checking for action conflicts
Requires implementing IComparable\IEquatable in FileItem (and I also implemented them in DirectoryItem for consistency)

#rnx
#rb Tim.Smith
#preflight 63c1cce4a06ab115ea17ba4f
#preflight 63c70f4d7763631ba15486ea

[CL 23745743 by Joe Kirchoff in ue5-main branch]
2023-01-17 16:35:14 -05:00
alex kahn
1199db4b52 [Backout] - CL23735141 - Backing out my back out as it seems like there are 2 CL's to backout and I backed it out of order
[FYI] alex.kahn
Original CL Desc
-----------------------------------------------------------------
[Backout] - CL23729890 - Nightly Win64 Build Error
[FYI] JeanMichel.Dignard
Original CL Desc
-----------------------------------------------------------------
Engine FExec (exec commands) changes
- Add Exec_Dev and Exec_Editor virtual functions to allow implementing Exec for specific configurations.
- Add a UBT flag: bAllowExecCommandsInShipping as a master switch to allow or remove Exec in shipping.
- The default Exec implementation calls both Exec_Dev and Exec_Editor, when they are available.
- Blueprint ExecuteConsoleCommand will now ask the console manager to process the command before falling back to Player and GEngine Exec. This is to make sure that if exec commands are disabled the blueprint node is still able to execute console commands.

#rb Josh.Adams
#preflight 63c570c002024f93d8011c2e

[CL 23735316 by alex kahn in ue5-main branch]
2023-01-17 01:46:10 -05:00
alex kahn
9ca4cd21fc [Backout] - CL23729890 - Nightly Win64 Build Error
[FYI] JeanMichel.Dignard
Original CL Desc
-----------------------------------------------------------------
Engine FExec (exec commands) changes
- Add Exec_Dev and Exec_Editor virtual functions to allow implementing Exec for specific configurations.
- Add a UBT flag: bAllowExecCommandsInShipping as a master switch to allow or remove Exec in shipping.
- The default Exec implementation calls both Exec_Dev and Exec_Editor, when they are available.
- Blueprint ExecuteConsoleCommand will now ask the console manager to process the command before falling back to Player and GEngine Exec. This is to make sure that if exec commands are disabled the blueprint node is still able to execute console commands.

#rb Josh.Adams
#preflight 63c570c002024f93d8011c2e

[CL 23735315 by alex kahn in ue5-main branch]
2023-01-17 01:45:57 -05:00