From 3875d2abe2f7f743a961d9b1c4ebfb338f049cd7 Mon Sep 17 00:00:00 2001 From: Lynix Date: Tue, 27 Sep 2016 18:10:13 +0200 Subject: [PATCH] Build: Make some fixes in order to prepare static building Still not linking though Former-commit-id: 3962a663c9368ea78c4703cc860beef8c440bb4b [formerly b9575a870528ef6712500a94c5223a74d5c6dbec] [formerly bf2ab7b17b25479d6a8fda660e8d9055ffce38de [formerly 3db6f9cbf4cedd9f91ef8f7f1bcc99a4e84027a4]] Former-commit-id: 0c292fec84d1963f377d16d5e9a15337bef4620f [formerly 93c016fa10c60bf11e4b0b1e17d8c98a66dfa028] Former-commit-id: 712b1bf14355a82be4cc2c37912f87039b3d9616 --- SDK/include/NDK/Prerequesites.hpp | 4 ++-- build/scripts/common.lua | 6 +++++- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/SDK/include/NDK/Prerequesites.hpp b/SDK/include/NDK/Prerequesites.hpp index f3532c70d..ec40a17d8 100644 --- a/SDK/include/NDK/Prerequesites.hpp +++ b/SDK/include/NDK/Prerequesites.hpp @@ -33,7 +33,7 @@ // Importation/Exportation of the API #if defined(NAZARA_PLATFORM_WINDOWS) - #if !defined(NDK_STATIC) + #if !defined(NAZARA_STATIC) #ifdef NDK_BUILD #define NDK_API NAZARA_EXPORT #else @@ -43,7 +43,7 @@ #define NDK_API #endif #elif defined(NAZARA_PLATFORM_LINUX) - #if !defined(NDK_STATIC) && defined(NAZARA_COMPILER_GCC) + #if !defined(NAZARA_STATIC) && defined(NAZARA_COMPILER_GCC) #define NDK_API NAZARA_EXPORT #else #define NDK_API diff --git a/build/scripts/common.lua b/build/scripts/common.lua index cf6fa6560..e6f231960 100644 --- a/build/scripts/common.lua +++ b/build/scripts/common.lua @@ -228,6 +228,7 @@ function NazaraBuild:Execute() targetdir("../lib/xcode/x64") configuration("*Static") + defines("NAZARA_STATIC") kind("StaticLib") configuration("*Dynamic") @@ -357,6 +358,9 @@ function NazaraBuild:Execute() targetdir("../plugins/" .. toolTable.Name .. "/lib/xcode/x64") end + configuration("*Static") + defines("NAZARA_STATIC") + if (toolTable.Kind == "library" or toolTable.Kind == "plugin") then configuration("*Static") kind("StaticLib") @@ -705,7 +709,7 @@ function NazaraBuild:MakeInstallCommands(infoTable) end if (os.is("windows")) then - configuration({}) + configuration("*Dynamic") for k,v in pairs(self.InstallDir) do local destPath = path.translate(path.isabsolute(k) and k or "../../" .. k)