Announcement

Collapse
No announcement yet.

Compiling on Linux: Instructions need change.

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Compiling on Linux: Instructions need change.

    I forked and cloned the latest UT git repo and noticed that /UnrealTournament/Setup.sh only pulls in the git dependencies. It does not call /UnrealTournament/Engine/BatchFiles/Linux/Setup.sh; which is a mandatory part of the process. (The LinuxNativeDialogs part.)

    Code:
    #!/bin/bash
    # Copyright 1998-2015 Epic Games, Inc. All Rights Reserved.
    
    
    set -e
    
    
    cd "`dirname "$0"`"
    
    
    if [ ! -f Engine/Binaries/DotNET/GitDependencies.exe ]; then
        echo "GitSetup ERROR: This script does not appear to be located \
           in the root UT directory and must be run from there."
        exit 1
    fi 
    
    
    # Setup the git hooks
    if [ -d .git/hooks ]; then
        echo "Registering git hooks... (this will override existing ones!)"
        echo \#!/bin/sh >.git/hooks/post-checkout
        echo mono Engine/Binaries/DotNET/GitDependencies.exe >>.git/hooks/post-checkout
        chmod +x .git/hooks/post-checkout
    
    
        echo \#!/bin/sh >.git/hooks/post-merge
        echo mono Engine/Binaries/DotNET/GitDependencies.exe >>.git/hooks/post-merge
        chmod +x .git/hooks/post-merge
    fi
    
    
    # Download the binaries
    set +e
    mono Engine/Binaries/DotNET/GitDependencies.exe --prompt "$@"
    set -e

    For Unreal Engine, /UnrealEngine/Setup.sh does call /UnrealEngine/Engine/BatchFiles/Linux/Setup.sh.

    Code:
    #!/bin/bash
    # Copyright 1998-2015 Epic Games, Inc. All Rights Reserved.
    
    
    set -e
    
    
    cd "`dirname "$0"`"
    
    
    if [ ! -f Engine/Binaries/DotNET/GitDependencies.exe ]; then
        echo "GitSetup ERROR: This script does not appear to be located \
           in the root UE4 directory and must be run from there."
        exit 1
    fi 
    
    
    if [ "$(uname)" = "Darwin" ]; then
        # Setup the git hooks
        if [ -d .git/hooks ]; then
            echo "Registering git hooks... (this will override existing ones!)"
            rm -f .git/hooks/post-checkout
            rm -f .git/hooks/post-merge
            ln -s ../../Engine/Build/BatchFiles/Mac/GitDependenciesHook.sh .git/hooks/post-checkout
            ln -s ../../Engine/Build/BatchFiles/Mac/GitDependenciesHook.sh .git/hooks/post-merge
        fi
    
    
        # Get the dependencies for the first time
        Engine/Build/BatchFiles/Mac/GitDependencies.sh --prompt $@
    else
        # Setup the git hooks
        if [ -d .git/hooks ]; then
            echo "Registering git hooks... (this will override existing ones!)"
            echo \#!/bin/sh >.git/hooks/post-checkout
            echo Engine/Build/BatchFiles/Linux/GitDependencies.sh >>.git/hooks/post-checkout
            chmod +x .git/hooks/post-checkout
    
    
            echo \#!/bin/sh >.git/hooks/post-merge
            echo Engine/Build/BatchFiles/Linux/GitDependencies.sh >>.git/hooks/post-merge
            chmod +x .git/hooks/post-merge
        fi
    
    
        pushd Engine/Build/BatchFiles/Linux > /dev/null
        ./Setup.sh "$@"
        popd > /dev/null
    fi
    All the associated README.md's and the wiki point to running /UnrealTournament/Setup.sh, followed by /UnrealTournament/GenerateProjectFiles.sh. Without intervention this will fail.

    Two options suggest themselves:

    1) Rewrite all the README.md's and update the wiki to inform people that they need to run the second Setup.sh @ /UnrealTournament/Engine/BatchFiles/Linux/Setup.sh before running /UnrealTournament/GenerateProjectFiles.sh.

    2) Rewrite /UnrealTournament/Setup.sh to include the call to /UnrealTournament/Engine/BatchFiles/Linux/Setup.sh.

    Option #2 gets my vote.
    No one sees what tomorrow knows.
Working...
X