Unreal Engine appears to both use and include a number of third-party components whose licenses are at, for example, https://github.com/EpicGames/UnrealEngine/tree/4.15.1-release/Engine/Source/ThirdParty/Licenses
Qs:
- Are all the Unreal Engine third-party components’ licenses in that subdirectory, or do we have to go hunting elsewhere?
- For a given “cooked” build, how does one determine which 3rd party components are included as part of our end product (so that we know which notices/licenses to include with ours)? For example: a Mac build might include 3P components {A, B, C} but a Windows build might include 3P component {A, X, Y}, and some other 3P component Z might be used in the Unreal Engine source/editor/whatnot, but never be a part of our product’s binary.
Clearly Unreal has these .TPS xml files documenting third-party components and licenses in a structured form so there is some sort of automation around this. Most modern build systems have a way of manipulating the build as a DAG, where each component/node can be annotated with license info, and the aggregate notices can be generated from these, for example with Gradle or Blaze.
We could build our own thing around this, but if Epic has a system to aggregate the needed license notices already, obviously that would be preferable. The critical thing is still knowing which components are embedded in say the Mac binary vs. the Windows binary etc.
Hi there,
- The following directory only contains licenses for third party software (TPS) which we’re required to redistribute per the license terms: /Engine/Source/ThirdParty/Licenses/
- We’ve developed a ListThirdPartySoftware script to identify what’s compiled into our game products, I’ve attached a pdf with instructions. This script should also work here as long as you’re either using a UE4 source build from our P4 branch or Github repo. Please be aware - the primary purpose of this script is for our internal use, so it’s not the most user friendly or automated thing in the world
What this script does:
- Invokes UBT for each target with -ListBuildFolders, which will then scan the target for all dependent UE4 modules.
- For each module found, it then lists the module source folder and all RuntimeDependencies folders specified in the module.build.cs file.
- We’ve also hardcoded all .tps files in the Engine/Content and Engine/Shaders directory as everything there always gets compiled into the client.
- For each of the folders found, the script finds any .tps file in that subfolder/parent folder
These .tps files also contain basic info on what the TPS is, does, where you can find a EULA or license online, and where you can find the license in our UE distribution if we’re required to redistribute it. A lot of our TPS uses custom licenses, so we’re not always going to be able to direct users to a license.
We could build our own thing around
this, but if Epic has a system to
aggregate the needed license notices
already, obviously that would be
preferable. The critical thing is
still knowing which components are
embedded in say the Mac binary vs. the
Windows binary etc.
Epic currently doesn’t have a system like this in place. If you do end up putting together a system like this, let us know! We’d love to see what you’ve put together.
link text
Thanks Leslie! Yes I’m primarily looking for third-party licenses where we game developers need to include the copyright notices/license/disclaimers/etc. in our own end-user binary package. My understanding is for licenses like PhysX and what not, we just need to follow the Epic EULA, since they are ‘custom’ licenses between Epic and Nvidia for example - correct?
Do we really need to build from source from scratch to figure out what is in the build? Is not enough to use an Epic Games Launcher installation that includes the source?
For example, the following command gives me a series of build folders:
./mono "/Users/USER/unreal/UE_4.15/Engine/Binaries/DotNET/UnrealBuildTool.exe" PROJECTNAME Mac Shipping /Users/USER/src/private/project/PROJECTNAME.uproject -listbuildfolders
Is that enough, or do we ALSO need to run the listbuildfolders on the UE4Game target?
Alright - we were able to get all this working from the source build - thank you! Some of the TPS paths point to license files in ThirdParty/Licenses that don’t exist , but it just seems like they are renames that haven’t propagated (like removing version numbers).
Does following your PDF instructions account for third-party software in the plugins we turn on/off in the editor for those that are deployed in the shipping game that can be turned on/off in the editor (as long as we haven’t installed any new ones from the Marketpalce)? Or do we need to generate that in some other way for each plugin?
My understanding is for licenses like
PhysX and what not, we just need to
follow the Epic EULA, since they are
‘custom’ licenses between Epic and
Nvidia for example - correct?
Correct.
Do we really need to build from source
from scratch to figure out what is in
the build? Is not enough to use an
Epic Games Launcher installation that
includes the source?
There’s currently a bug when using this TPS script in the launcher installation. I have a request in to our dev teams to fix this, but it’s unlikely to be fixed in the near future due to more critical work on their plate. The TPS script does work when using the Github source build and should be simple to set up.
Some of the TPS paths point to license
files in ThirdParty/Licenses that
don’t exist , but it just seems like
they are renames that haven’t
propagated (like removing version
numbers).
What UE release are you using? Can you give me a few examples? This is likely an oversight on my part.
Does following your PDF instructions
account for third-party software in
the plugins we turn on/off in the
editor for those that are deployed in
the shipping game that can be turned
on/off in the editor (as long as we
haven’t installed any new ones from
the Marketpalce)?
Yes it does! If a plugin is enabled and uses additional TPS, the script will find that when determining what code and dependencies are compiled into the Shipping build.
Can you give me a few examples?
We’re forked off 4.15.2. Of the ones we needed just the following:
/Engine/Source/ThirdParty/Licenses/OpenSSL1.0.1e_License.txt
If a plugin is enabled and uses additional TPS, the script will find that when determining what code and dependencies are compiled into the Shipping build.
Cool! But is that based on running just against UE4Game:
RunUAT.bat ListThirdPartySoftware "-target=UE4Game|Shipping|Win64"
"-target=CrashReportClient|Shipping|Win64" >TPSAudit.txt
Or do we also need to run against the actual Game project and take the union, so it can read in the game’s uproject/build rules?
We’re forked off 4.15.2. Of the ones
we needed just the following:
/Engine/Source/ThirdParty/Licenses/OpenSSL1.0.1e_License.txt
Thanks. For 4.15, this path should’ve directed to the following license, although it’s still version 1.1.0:
/Engine/Source/ThirdParty/Licenses/OpenSSL_License.txt
Cool! But is that based on running
just against UE4Game:
You’ll need to run this script against your actual project for the final list of TPS. UE4Game is a good generic example and will be affected by the plugins you turn on/off, but it won’t necessarily be an accurate representation of what’s actually used in your game.
You’ll need to run this script against your actual project for the final list of TPS. UE4Game is a good generic example and will be affected by the plugins you turn on/off, but it won’t necessarily be an accurate representation of what’s actually used in your game.
Do we need to run against our project file and UE4Game and take the union, or just run on our final project?
Finally, re: a Mac solution, LinqPad does not work on Macs even under Mono. One way is as follows:
// This code is provided as-is, with absolutely no warranty. Use at your own risk.
using System;
using System.Collections.Generic;
using System.Linq;
using System.IO;
using System.Xml.Linq;
using System.Xml.XPath;
using System.Xml;
/*
Usage on Mac and using the Mono distribution that comes with UE4 (git repo at $UE_ROOT):
export UE_MONO_DIR=$UE_ROOT/Engine/Binaries/ThirdParty/Mono/Mac/
$UE_MONO_DIR/bin/mcs /reference:System.Xml.Linq.dll TpsDump.cs
$UE_MONO_DIR/bin/mono TpsDump.exe
*/
class TpsDump {
static void Main(string[] args) {
var results = /* Insert query from the PDF */;
// Poor CSV convertor.
var csv = results.Select(V =>
"\"" + (""+V.TPSName).Replace("\"", "\"\"") +
"\",\"" + (""+V.Function).Replace("\"", "\"\"") +
"\",\"" + (""+V.Justification).Replace("\"", "\"\"") +
"\",\"" + (""+V.TPSFile).Replace("\"", "\"\"") +
"\",\"" + (""+V.EULA_URL).Replace("\"", "\"\"") +
"\",\"" + (""+V.LicenseInUE).Replace("\"", "\"\"") + "\"");
Console.WriteLine("TPSName,Function,Justification,TPSFile,EULA_URL,LicenseInUE");
foreach (var x in csv) {
Console.WriteLine(x);
}
}
}
Nope, just run it against your actual project target. UE4Game was used in the instructions as an example.
Regarding Mac - you’ll likely need to take the script output (which is run on a Mac) and extract the info on a PC. Or find a similar program to LinqPad. Internally - we run this script by remote compiling on a Mac from PC.
For everyone reading this: We have automated most parts of the process, except for calling UAT itself. The following GitHub repository contains a tool that will happily remove the other UAT output, skip redirects and duplicates, and parse all TPS files to create a combined license file:
Enjoy.
1 Like
The pdf link seems to be broken, could someone re-post it? I don’t have any terminal / command line experience.