Skip to content

Instantly share code, notes, and snippets.

@iwer
Last active February 12, 2024 20:10
Show Gist options
  • Save iwer/fc4e34a2a491461d606d826b72664845 to your computer and use it in GitHub Desktop.
Save iwer/fc4e34a2a491461d606d826b72664845 to your computer and use it in GitHub Desktop.
A writeup of how to to get UnrealGDAL based projects up-and-running with Unreal Engine 5

UnrealGDAL based plugin setup

UnrealGDAL utilizes a python based cli tool to build thirdparty libraries with the Unreal toolchain and to include the build artifacts into the Unreal project build process. It is built around the conan C++ package manager.

There are several gotchas on the way to migrating the stack like: UE dependencies changing requiring conan recipe changes, conan upgrading to 2.0, ubuntu phasing out old autotools and so on...

As I understand, the original author of UnrealGDAL and the build-tools is quite busy, so I cloned relevant repositories and try to maintain something that is functioning for me.

However, maybe this can also be usefull to someone else, so here you go:

UE 5.1

Prepare UE

Install from Epic Launcher and clone UE source to separate directory. In the clone:

./Setup.bat
./GenerateProjectFiles.bat

Build 3rd party libs

Get Build tools

1.57 <= conan <= 1.59 (ue4cli is not yet ready for conan2)

pip3 install --upgrade conan==1.59

ue4cli>=0.0.54 ,conan-ue4cli>=0.0.38

pip3 install ue4cli conan-ue4cli

ue4-conan-recipes (with ue5 compatibility)

git clone git@github.com:iwer/ue4-conan-recipes.git
Windows
git switch -c ue5 origin/ue5

Copy directories to ~/AppData/Roaming/conan-ue4cli/recipes

Linux
git switch -c gdal3 origin/gdal3

Build libs

Windows
ue4 setroot <path/to/ue5/source>
ue4 conan generate
ue4 setroot <path/to/ue5/installation>
ue4 conan update
ue4 conan build gdal-ue4==2.4.0 mergetiff-ue4
Linux
ue4 setroot <path/to/ue5/source>
ue4 conan generate
ue4 setroot <path/to/ue5/installation>
ue4 conan update

I could not build gdal 2.4.0 on Ubuntu anymore due to autoconf >= 2.71. So I created conan recipes for gdal 3.5.1. Get conan recipes from https://github.com/iwer/ue4-conan-recipes and copy the recipes to ~/.config/conan-ue4cli/recipes. Then build:

ue4 conan build gdal-ue4==3.5.1 mergetiff-ue4

Get Plugins

Optional: Populate built thirdparty libs (e.g. to store them in VCS)

cd <UnrealProjectDirectory>
ue4 conan precompute host -d .\Plugins\UnrealGDAL\Source\GDAL\
@iwer
Copy link
Author

iwer commented Jan 9, 2024

Very nice! Feel free to prepare a pull request, i'd be more than happy to review it when i'm back.

@iwer
Copy link
Author

iwer commented Feb 12, 2024

I just discovered, that there is an effort to make UnrealGDAL UE5.3 compatible by ssav7912 and then wolfgangp. While I have not yet found the time to test it, it may be a straw, for everyone struggling with this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment