From a277e7560fe2cc2fdd2e1a057d9daa0f6b0c8914 Mon Sep 17 00:00:00 2001 From: Lynix Date: Mon, 13 Jun 2016 21:19:12 +0200 Subject: [PATCH] Build: Fix example path Former-commit-id: 54e56da81ea8c93da5ec276035dca59a62932ed0 [formerly ab7201812c22e7a4dcabbfbf74686a169a67a1b0] Former-commit-id: 48aaf02c04cea375eeb33b64afc09428631ee523 --- build/scripts/common.lua | 12 ++++++------ build/scripts/tools/assimp.lua | 3 ++- build/scripts/tools/ndk.lua | 3 ++- build/scripts/tools/ndk_server.lua | 3 ++- build/scripts/tools/unittests.lua | 1 + 5 files changed, 13 insertions(+), 9 deletions(-) diff --git a/build/scripts/common.lua b/build/scripts/common.lua index 12aa13d70..2b4906569 100644 --- a/build/scripts/common.lua +++ b/build/scripts/common.lua @@ -270,7 +270,7 @@ function NazaraBuild:Execute() project(prefix .. toolTable.Name) location(_ACTION .. "/tools") - targetdir(toolTable.Directory) + targetdir(toolTable.TargetDirectory) if (toolTable.Kind == "plugin" or toolTable.Kind == "library") then kind("SharedLib") @@ -278,7 +278,7 @@ function NazaraBuild:Execute() -- Copy the tool binaries to the example folder self:MakeInstallCommands(toolTable) elseif (toolTable.Kind == "application") then - debugdir(toolTable.Directory) + debugdir(toolTable.TargetDirectory) if (toolTable.EnableConsole) then kind("ConsoleApp") else @@ -404,7 +404,7 @@ function NazaraBuild:Execute() self:MakeInstallCommands(toolTable) elseif (exampleTable.Kind == "application") then - debugdir(exampleTable.Directory) + debugdir(exampleTable.TargetDirectory) if (exampleTable.EnableConsole) then kind("ConsoleApp") else @@ -769,7 +769,7 @@ function NazaraBuild:RegisterTool(toolTable) return false, "This tool name is already in use" end - if (toolTable.Directory == nil or type(toolTable.Directory) ~= "string" or string.len(toolTable.Directory) == 0) then + if (toolTable.TargetDirectory == nil or type(toolTable.TargetDirectory) ~= "string" or string.len(toolTable.TargetDirectory) == 0) then return false, "Invalid tool directory" end @@ -907,7 +907,7 @@ function NazaraBuild:Process(infoTable) end if (infoTable.Kind == "application") then - self:AddExecutablePath(infoTable.Directory) + self:AddExecutablePath(infoTable.TargetDirectory) end return true @@ -995,8 +995,8 @@ end function NazaraBuild:SetupExampleTable(infoTable) self:SetupInfoTable(infoTable) - infoTable.Directory = "../examples/bin" infoTable.Kind = "application" + infoTable.TargetDirectory = "../examples/bin" end function NazaraBuild:SetupExtlibTable(infoTable) diff --git a/build/scripts/tools/assimp.lua b/build/scripts/tools/assimp.lua index 0eecbcd54..08688ef72 100644 --- a/build/scripts/tools/assimp.lua +++ b/build/scripts/tools/assimp.lua @@ -1,7 +1,8 @@ TOOL.Name = "Assimp" -TOOL.Directory = "../SDK/lib" +TOOL.Directory = "../plugins/Assimp" TOOL.Kind = "Plugin" +TOOL.TargetDirectory = "../SDK/lib" TOOL.Includes = { "../include", diff --git a/build/scripts/tools/ndk.lua b/build/scripts/tools/ndk.lua index d2038342b..8a40ea170 100644 --- a/build/scripts/tools/ndk.lua +++ b/build/scripts/tools/ndk.lua @@ -1,7 +1,8 @@ TOOL.Name = "SDK" -TOOL.Directory = "../SDK/lib" +TOOL.Directory = "../SDK" TOOL.Kind = "Library" +TOOL.TargetDirectory = "../SDK/lib" TOOL.Defines = { "NDK_BUILD" diff --git a/build/scripts/tools/ndk_server.lua b/build/scripts/tools/ndk_server.lua index 91a0fd170..2881c56fc 100644 --- a/build/scripts/tools/ndk_server.lua +++ b/build/scripts/tools/ndk_server.lua @@ -1,7 +1,8 @@ TOOL.Name = "SDKServer" -TOOL.Directory = "../SDK/lib" +TOOL.Directory = "../SDK" TOOL.Kind = "Library" +TOOL.TargetDirectory = "../SDK/lib" TOOL.Defines = { "NDK_BUILD", diff --git a/build/scripts/tools/unittests.lua b/build/scripts/tools/unittests.lua index 349932cb6..fc0f4bad6 100644 --- a/build/scripts/tools/unittests.lua +++ b/build/scripts/tools/unittests.lua @@ -3,6 +3,7 @@ TOOL.Name = "UnitTests" TOOL.Directory = "../tests" TOOL.EnableConsole = true TOOL.Kind = "Application" +TOOL.TargetDirectory = TOOL.Directory TOOL.Defines = { }