Linux game project build

Hello,

I have been working with UE for few months now (Switched from Unity to UE4)
Recently i started to get a dedicated server up and running for my project, which goes fine on windows.

The main issue i have is that my main development machine is getting low on disc space cause there are many more projects on it (working as software engineer as daily job)
Currently the UE4 source folder is +50GB (compiled development editor/development server) which is only needed to get the dedicated server running (was using the binary version installed with epic launcher before)
I’m only running the dedicated server atm for testing network features of my game at this point.

As i have a linux pc running in my network with plenty of disc space, i want to compile/run my dedicated server on linux and switch back to the binary version of the engine on my laptop to save up about 50GB on compiled UE4 sources :smiley:
I checked out the UE4.8 source code last night on the linux box, as well of the SVN repository containing my game project. (din’t compile anything yet as it was getting to late)

Now my main question is how to target the UE4 source on linux for my game project.
On windows we can right click the uproject file and choose to switch engine version.

My linux pc does not have a monitor/keyboard connected to it, so i have to do this trough ssh :o
I found articles/wiki pages about how to compile the engine on linux, but not how to target a game project to the compiled source and build the game project …
While the linux pc is running as a server (mainly svn/file/jenkins build server), it does have Ubuntu 14.04 desktop installed with vnc server, so if really needed i can go into the desktop

Kind regards,
Randy

You can compile the server binary on Linux through the command line, but you won’t be able to package the game … as far as I understand. So you would need to compile the UE4 Editor on Linux and then package your game through Linux as well.

I did at one stage encounter an error when I tried to connect a Windows client built on my Windows machine to a Linux dedicated server built on my Linux machine. I have since then reverted to use clang on my Windows machine and build and package my game for Windows and Linux on said Windows machine.

Building the editor on Linux will work but I have found it to be a bit clunky and have some serious performance issues, so I merely use my Linux machine to test the Client and Server built and packaged on my Windows box.

I am not sure about the right-clicking on Linux option … I haven’t found a definitive answer on that.

In my opinion, your best bet is to try and get a larger hard drive for your machine or a secondary drive and move some of the stuff you can to the secondary drive, this would be the easier thing in the long run.

Getting more disc space is not really an option as this is a company laptop :wink:
I will give it a try to get the dedicated server compiled on linux this evening.

Still, for now it’s only temporary that i need to compile the dedicated server. Just want to be sure the base network code (mainly online session registration, beacon setup, , …) works for both listen server and dedicated server, so i dont have to rewrite stuff afterward. Storing the engine source on external disc or network share might be a better option as spending time to get linux environment working for now.

Put your game code in the same directory as the engine installation and GenerateProjectFiles.sh should create targets for the game as well.

My first attempt to compile on linux was successful (or at least no compile errors) :slight_smile:

But when i try to run the server i get the following error message:
./SwatReloadedServer-Linux-Debug: error while loading shared libraries: libsteam_api.so: cannot open shared object file: No such file or directory

These are the steps i took to compile the game project

cd ~/Workspace
git clone -b 4.8 https://github.com/EpicGames/UnrealEngine.git
svn co svn://192.168.1.170/gamedev/SwatReloaded

cd ~/Workspace/UnrealEngine
./Setup.sh
./GenerateProjectFiles.sh

export UE_ROOT="$HOME/Workspace/UnrealEngine"

cd ~/Workspace/SwatReloaded/branches/UE4
mono “$UE_ROOT/Engine/Binaries/DotNET/UnrealBuildTool.exe” -makefile -project="$HOME/Workspace/SwatReloaded/branches/UE4/SwatReloaded.uproject" -game -engine -progress
make SwatReloadedServer-Linux-Debug

ps: Would be nice to have the mono …UnrealBuildTools.exe -makefile -project explained in the linux wiki pages, cause it took me a while to find how to generate the makefile for my project :s

You shouldn’t have to use mono to call the build tool … I merely use make.

I followed these instructions: Building On Linux … I have never had to go the mono route on Linux.