Verify found Urho3D library has matching ABI with the chosen compiler.
Check the CMake minimum version before setting project name as recommended by CMake. Minor documentation update on how to setup downstream projects using Urho3D library as external library. For AppVeyor - attempt to add scaffolding test using Urho3D SDK.
This commit is contained in:
Родитель
e95feb9d7e
Коммит
1cd242273e
|
@ -24,7 +24,6 @@ version: '{build}'
|
|||
platform:
|
||||
- x86
|
||||
- x64
|
||||
configuration: Release
|
||||
clone_depth: 50
|
||||
environment:
|
||||
SF_KEY:
|
||||
|
@ -32,6 +31,7 @@ environment:
|
|||
SF_API:
|
||||
secure: cc1q9CXo5BwIYqtgigHpkCGG90zEVM45xx/YzXTOjVp512oQNUzTJq0AmxEYXP78
|
||||
build_tree: native-Build
|
||||
config: Release
|
||||
matrix:
|
||||
- URHO3D_LIB_TYPE: STATIC
|
||||
- URHO3D_LIB_TYPE: SHARED
|
||||
|
@ -51,12 +51,24 @@ install:
|
|||
build_script:
|
||||
- if "%PLATFORM%" == "x64" set "OPTS=URHO3D_64BIT=1"
|
||||
# Our free AppVeyor account is slow for normal daily CI, speed up the build a little bit by excluding Assimp and other tools in the normal build and use the Debug build configuration instead
|
||||
- if "%PACKAGE_UPLOAD%" == "" set "OPTS=%OPTS% URHO3D_TOOLS=0" && set "Configuration=Debug"
|
||||
- rake cmake vs2015 %OPTS% URHO3D_LIB_TYPE=%URHO3D_LIB_TYPE% URHO3D_D3D11=1 URHO3D_LUAJIT=1 URHO3D_LUAJIT_AMALG=1 URHO3D_EXTRAS=1 URHO3D_TESTING=1
|
||||
- rake make config=%Configuration%
|
||||
- if "%PACKAGE_UPLOAD%" == "" set "OPTS=%OPTS% URHO3D_TOOLS=0" && set "config=Debug"
|
||||
- rake cmake vs2015 %OPTS% URHO3D_LIB_TYPE=%URHO3D_LIB_TYPE% URHO3D_D3D11=1 URHO3D_LUAJIT=1 URHO3D_LUAJIT_AMALG=1 URHO3D_EXTRAS=1 URHO3D_TESTING=1 && rake make
|
||||
# Could not run test target yet as AppVeyor does not currently allow its service to interact with desktop
|
||||
# - rake make config=%Configuration% target=RUN_TESTS
|
||||
- if "%PACKAGE_UPLOAD%" == "1" (rake ci_appveyor_package_upload) else (rake scaffolding dir=MyProject project=MyProject && cd MyProject && rake cmake vs2015 %OPTS% URHO3D_HOME=..\..\native-Build URHO3D_D3D11=1 && rake make config=%Configuration%)
|
||||
# - rake make target=RUN_TESTS
|
||||
- ps: if ($env:PACKAGE_UPLOAD -eq "1")
|
||||
{
|
||||
"Packaging the build artifact...";
|
||||
rake ci_appveyor_package_upload;
|
||||
}
|
||||
else
|
||||
{
|
||||
"Configuring downstream project using Urho3D library in its build tree...";
|
||||
rake scaffolding dir=UsingBuildTree && cd UsingBuildTree && rake cmake vs2015 $env:OPTS URHO3D_HOME=..\..\native-Build URHO3D_D3D11=1 && rake make;
|
||||
"Installing Urho3D SDK to default system-wide location...";
|
||||
cd .. && rake make target=install >$null;
|
||||
"Configuring downstream project using Urho3D SDK...";
|
||||
rake scaffolding dir=UsingSDK && cd UsingSDK && rake cmake vs2015 $env:OPTS URHO3D_D3D11=1 && rake make;
|
||||
}
|
||||
test: off
|
||||
artifacts:
|
||||
- path: native-Build\*.zip
|
||||
|
|
|
@ -0,0 +1,31 @@
|
|||
//
|
||||
// Copyright (c) 2008-2015 the Urho3D project.
|
||||
//
|
||||
// Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
// of this software and associated documentation files (the "Software"), to deal
|
||||
// in the Software without restriction, including without limitation the rights
|
||||
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
// copies of the Software, and to permit persons to whom the Software is
|
||||
// furnished to do so, subject to the following conditions:
|
||||
//
|
||||
// The above copyright notice and this permission notice shall be included in
|
||||
// all copies or substantial portions of the Software.
|
||||
//
|
||||
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
// THE SOFTWARE.
|
||||
//
|
||||
|
||||
#include <Urho3D/Revision.h>
|
||||
#include <iostream>
|
||||
|
||||
using namespace Urho3D;
|
||||
|
||||
int main(int argc, char* argv[])
|
||||
{
|
||||
std::cout << GetRevision();
|
||||
}
|
|
@ -57,6 +57,7 @@ if (CMAKE_PROJECT_NAME STREQUAL Urho3D AND TARGET Urho3D)
|
|||
list (APPEND URHO3D_INCLUDE_DIRS ${URHO3D_HOME}/include/${PATH_SUFFIX}/ThirdParty/Lua${JIT})
|
||||
endif ()
|
||||
set (URHO3D_LIBRARIES Urho3D)
|
||||
set (COMPILE_RESULT TRUE)
|
||||
set (FOUND_MESSAGE "Found Urho3D: as CMake target")
|
||||
else ()
|
||||
# Library location would be searched (based on URHO3D_HOME variable if provided and in system-wide default location)
|
||||
|
@ -176,7 +177,11 @@ else ()
|
|||
set (URHO3D_LIB_TYPE SHARED)
|
||||
endif ()
|
||||
endif ()
|
||||
# TODO: Ensure the module has found the library with the right ABI for the chosen compiler and URHO3D_64BIT build option
|
||||
# Ensure the module has found the library with the right ABI for the chosen compiler and URHO3D_64BIT build option
|
||||
try_compile (COMPILE_RESULT ${CMAKE_BINARY_DIR}
|
||||
SOURCES ${CMAKE_CURRENT_LIST_DIR}/CheckUrho3DLibrary.cpp
|
||||
CMAKE_FLAGS -DINCLUDE_DIRECTORIES:STRING=${URHO3D_INCLUDE_DIRS}
|
||||
LINK_LIBRARIES ${URHO3D_LIBRARIES})
|
||||
# For shared library type, also initialize the URHO3D_DLL variable for later use
|
||||
if (WIN32)
|
||||
if (URHO3D_LIB_TYPE STREQUAL SHARED AND URHO3D_HOME)
|
||||
|
@ -195,7 +200,7 @@ else ()
|
|||
endif ()
|
||||
endif ()
|
||||
|
||||
if (URHO3D_INCLUDE_DIRS AND URHO3D_LIBRARIES AND URHO3D_LIB_TYPE)
|
||||
if (URHO3D_INCLUDE_DIRS AND URHO3D_LIBRARIES AND URHO3D_LIB_TYPE AND COMPILE_RESULT)
|
||||
set (URHO3D_FOUND 1)
|
||||
if (NOT FOUND_MESSAGE)
|
||||
set (FOUND_MESSAGE "Found Urho3D: ${URHO3D_LIBRARIES}")
|
||||
|
|
|
@ -20,12 +20,8 @@
|
|||
# THE SOFTWARE.
|
||||
#
|
||||
|
||||
# Set project name
|
||||
project (Urho3D)
|
||||
|
||||
# Set minimum version
|
||||
# Set CMake minimum version and CMake policy required by Urho3D-CMake-common module
|
||||
cmake_minimum_required (VERSION 2.8.6)
|
||||
|
||||
if (COMMAND cmake_policy)
|
||||
cmake_policy (SET CMP0003 NEW)
|
||||
if (CMAKE_VERSION VERSION_GREATER 2.8.12 OR CMAKE_VERSION VERSION_EQUAL 2.8.12)
|
||||
|
@ -40,6 +36,9 @@ if (COMMAND cmake_policy)
|
|||
endif ()
|
||||
endif ()
|
||||
|
||||
# Set project name
|
||||
project (Urho3D)
|
||||
|
||||
# Set CMake modules search path
|
||||
set (CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/CMake/Modules)
|
||||
|
||||
|
|
|
@ -480,11 +480,11 @@ F2 Toggle debug HUD
|
|||
|
||||
\tableofcontents
|
||||
|
||||
This page shows how to create a new C++ project linking against Urho3D library as external library. There are two approaches to do this. The first approach uses Urho3D library directly from the Urho3D project build tree. The second approach uses Urho3D SDK installation. It is imperative to clean the CMake cache when changing from one approach to the other. You should also clean the cache when you change the path in the URHO3D_HOME environment variable.
|
||||
This page shows how to create a new downstream C++ project linking against Urho3D library as external library. There are two approaches to do this. The first approach uses Urho3D library directly from the Urho3D project build tree. The second approach uses Urho3D SDK installation. It is imperative to clean the CMake cache when changing from one approach to the other, or simply delete and recreate your project build tree from scratch.
|
||||
|
||||
> Migration note if you are migrating from Urho3D prior to release 1.4:
|
||||
> - You are probably better of to regenerate your build tree from scratch due to some of the directory renaming in the project structure.
|
||||
> - You must adjust the URHO3D_HOME environment variable in your build. In release 1.4 onward, the URHO3D_HOME environment variable is supposed to point to the build tree of the Urho3D project. In prior releases, the URHO3D_HOME was supposed to point to Urho3D project root itself.
|
||||
> - You must adjust the URHO3D_HOME environment variable in your build because we have changed the meaning of this variable. In release 1.4 onward, the URHO3D_HOME environment variable is supposed to point to the build tree of the Urho3D project. In prior releases, the URHO3D_HOME was supposed to point to Urho3D project root itself.
|
||||
|
||||
First of all, structure your project similar to Urho3D project as below. Although this is not mandatory, it should increase the chance the CMake modules designed for Urho3D project also works out of the box for your project too. CMake and our CMake modules are case-sensitive. It is recommended that your project adheres to the same naming convention as Urho3D project uses, even when the filesystem in your host system is not case-sensitive.
|
||||
|
||||
|
@ -501,17 +501,13 @@ First of all, structure your project similar to Urho3D project as below. Althoug
|
|||
└ *.bat or *.sh
|
||||
\endcode
|
||||
|
||||
The physical project root directory is also the logical project source tree in CMake terminology where your project main CMakeLists.txt should reside. The 'bin' directory should contain the 'Data' and 'CoreData' resource subdirs for your own assets. You may want to copy (or symlink) the 'CMake' subdir from Urho3D project root directory (or from Urho3D SDK installation, which can be found in the 'share/Urho3D/CMake') to your project root directory. You may also want to copy (or symlink) the build scripts from Urho3D project root directory (or from Urho3D SDK installation, which can be found in the 'share/Urho3D/Scripts') to your project root directory. Alternatively, you can add the Urho3D project root directory into the PATH environment variable in your host system in order to make the build scripts available everwhere. The build scripts work together with the Urho3D CMake modules to configure and generate your initial project build tree. Both out-of-source build tree (recommended) and non out-of-source build tree are supported. Note that when you configure your project (either via one of the build script or via cmake-gui), you can also pass most of the \ref Build_Options supported by Urho3D project. In fact, you probably have to pass a compatible build options with the Urho3D library that you intend to use to avoid any conflict.
|
||||
The physical project root directory is also the logical project source tree in CMake terminology where your project main CMakeLists.txt should reside. The 'bin' directory should contain the 'Data' and 'CoreData' resource subdirs for your own assets. You must copy (or symlink) the 'CMake' subdir from Urho3D project root directory (or from Urho3D SDK installation, which can be found in the 'share/Urho3D/CMake') to your project root directory. You may also want to copy (or symlink) the build scripts from Urho3D project root directory (or from Urho3D SDK installation, which can be found in the 'share/Urho3D/Scripts') to your project root directory, unless you just want to use cmake-gui for your own project configuration and generation. Alternatively, you can add the Urho3D project root directory into the PATH environment variable in your host system in order to make the build scripts available everywhere. The build scripts work together with the Urho3D CMake modules to configure and generate your initial project build tree. Both out-of-source build tree (recommended) and non out-of-source build tree are supported. Note that when you configure your project (either via one of the build script or via cmake-gui), you can also pass most of the \ref Build_Options supported by Urho3D project. In fact, you probably have to pass a compatible build options with the Urho3D library that you intend to use to avoid any conflict. Although this may change in the near future as we will enhance our modules to be smart enough to auto-discover the original build options used by the Urho3D library, but until then it is still your responsibility to supply the compatible build options.
|
||||
|
||||
In your own project root directory, create a main CMakeLists.txt file and add the following lines: (replace MyProjectName and MyExecutableName with the actual names you want)
|
||||
|
||||
\code
|
||||
# Set project name
|
||||
project (MyProjectName)
|
||||
|
||||
# Set minimum version
|
||||
# Set CMake minimum version and CMake policy required by Urho3D-CMake-common module
|
||||
cmake_minimum_required (VERSION 2.8.6)
|
||||
|
||||
if (COMMAND cmake_policy)
|
||||
cmake_policy (SET CMP0003 NEW)
|
||||
if (CMAKE_VERSION VERSION_GREATER 2.8.12 OR CMAKE_VERSION VERSION_EQUAL 2.8.12)
|
||||
|
@ -526,6 +522,9 @@ if (COMMAND cmake_policy)
|
|||
endif ()
|
||||
endif ()
|
||||
|
||||
# Set project name
|
||||
project (MyProjectName)
|
||||
|
||||
# Set CMake modules search path
|
||||
set (CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/CMake/Modules)
|
||||
|
||||
|
@ -542,9 +541,9 @@ define_source_files ()
|
|||
setup_main_executable ()
|
||||
\endcode
|
||||
|
||||
The CMAKE_MODULE_PATH is setup so that CMake can find the Urho3D-specific CMake modules provided by Urho3D project inside your own project. The Urho3D-CMake-common.cmake is the module where all the reusable commands and macros are defined. It also gives your project cross-platform build capability similar to Urho3D project.
|
||||
The CMAKE_MODULE_PATH is setup so that CMake can find the Urho3D-specific CMake modules provided by Urho3D project inside your own project. The Urho3D-CMake-common.cmake is the module where all the reusable commands and macros are defined. It also gives your project cross-platform build capability similar to Urho3D project. It does this by automatically finding the required software library components specific for your target platform and configuring your project to use them together with the platform-specific compiler flags and definitions. It utilizes CMake-provided as well as Urho3D custom-made FindXXX modules to get the work done. So, it is important to get the CMAKE_MODULE_PATH setup correctly in your project early on.
|
||||
|
||||
When both Urho3D static and shared library are built and available in the Urho3D project's library output directory in its build tree, the FindUrho3D.cmake module has precedence to first select static library type over over shared library type. However, you can use URHO3D_LIB_TYPE build option to explicitly specify which Urho3D library type to be selected.
|
||||
Your own project naturally depends on Urho3D project, or to be more precise it depends on Urho3D library. The Urho3D library needs to be built first so that it can be found later by your own project. When using GCC/Clang or one of its derivatives, both Urho3D static and shared libraries could be potentially built/installed at a same location and coexist. In such cases the FindUrho3D.cmake module, the module responsible to find Urho3D software library component, has precedence to first find the static library type over over shared library type. However, you can use URHO3D_LIB_TYPE build option to override this precedence. When using MSVC compiler, both static and shared libraries could not be built/installed at a same location because both the static library and import library have a same file extension. However, for MSVC, it is possible to have both Release and Debug versions of either static or shared library type built/installed at a same location. In such cases the FindUrho3D.cmake module would automatically utilize both of Release and Debug versions as appropriate in your project for Release and Debug build configuration, respectively, without user intervention.
|
||||
|
||||
As described earlier there are two approaches on how to find the Urho3D library. The FindUrho3D.cmake module is designed not only able to find Urho3D library from the Urho3D SDK installation, but also from any Urho3D project build tree directly. When searching in Urho3D SDK installed in a system-wide default location then no additional variable need to be set. When searching in a non-default SDK installation or when searching in any Urho3D project build tree then the actual location need to be provided via URHO3D_HOME environment variable (set in the host system) or URHO3D_HOME build option (set using -D at command line or in cmake-gui).
|
||||
|
||||
|
@ -631,8 +630,6 @@ rake cmake URHO3D_LUAJIT=1 && rake make
|
|||
rake cmake rpi URHO3D_LUAJIT=1 && rake make rpi
|
||||
\endcode
|
||||
|
||||
You can in fact set and export any other key/value pair build options as environment variables to avoid repeating yourself when invoking any of our Rake tasks.
|
||||
|
||||
|
||||
\page Structure Overall structure
|
||||
|
||||
|
|
18
Rakefile
18
Rakefile
|
@ -100,6 +100,7 @@ task :make do
|
|||
cmake_build_options = ''
|
||||
build_options = ''
|
||||
unfilter = false
|
||||
['config', 'target', 'sdk'].each { |var| ARGV << "#{var}=\"#{ENV[var]}\"" if ENV[var] and !ARGV.include? var }
|
||||
ARGV.each { |option|
|
||||
task option.to_sym do ; end; Rake::Task[option].clear # No-op hack
|
||||
case option
|
||||
|
@ -507,12 +508,8 @@ end
|
|||
|
||||
def scaffolding dir, project = 'Scaffolding', target = 'Main'
|
||||
build_script = <<EOF
|
||||
# Set project name
|
||||
project (#{project})
|
||||
|
||||
# Set minimum version
|
||||
# Set CMake minimum version and CMake policy required by Urho3D-CMake-common module
|
||||
cmake_minimum_required (VERSION 2.8.6)
|
||||
|
||||
if (COMMAND cmake_policy)
|
||||
cmake_policy (SET CMP0003 NEW)
|
||||
if (CMAKE_VERSION VERSION_GREATER 2.8.12 OR CMAKE_VERSION VERSION_EQUAL 2.8.12)
|
||||
|
@ -527,6 +524,9 @@ if (COMMAND cmake_policy)
|
|||
endif ()
|
||||
endif ()
|
||||
|
||||
# Set project name
|
||||
project (#{project})
|
||||
|
||||
# Set CMake modules search path
|
||||
set (CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/CMake/Modules)
|
||||
|
||||
|
@ -586,13 +586,13 @@ def makefile_ci
|
|||
unless ENV['CI'] && ENV['HTML5'] && ENV['PACKAGE_UPLOAD'] # For Emscripten, skip scaffolding test when packaging
|
||||
# Create a new project on the fly that uses newly built Urho3D library in the build tree
|
||||
scaffolding "../Build/generated/UsingBuildTree"
|
||||
system "cd ../Build/generated/UsingBuildTree && echo '\nDownstream project referencing Urho3D library in its build tree' && ./cmake_generic.sh . #{$build_options} -DURHO3D_HOME=../.. -DURHO3D_LUA#{jit}=1 -DURHO3D_TESTING=#{$testing} -DCMAKE_BUILD_TYPE=#{$configuration} && make -j$NUMJOBS #{test}" or abort 'Failed to configure/build/test temporary downstream project using Urho3D as external library'
|
||||
system "cd ../Build/generated/UsingBuildTree && echo '\nConfiguring downstream project using Urho3D library in its build tree...' && ./cmake_generic.sh . #{$build_options} -DURHO3D_HOME=../.. -DURHO3D_LUA#{jit}=1 -DURHO3D_TESTING=#{$testing} -DCMAKE_BUILD_TYPE=#{$configuration} && make -j$NUMJOBS #{test}" or abort 'Failed to configure/build/test temporary downstream project using Urho3D as external library'
|
||||
ENV['DESTDIR'] = ENV['HOME'] || Dir.home
|
||||
puts "\nInstalling Urho3D SDK to #{ENV['DESTDIR']}/usr/local...\n" # The default CMAKE_INSTALL_PREFIX is /usr/local
|
||||
system 'cd ../Build && make -j$NUMJOBS install >/dev/null' or abort 'Failed to install Urho3D SDK'
|
||||
# Create a new project on the fly that uses newly installed Urho3D SDK
|
||||
scaffolding "../Build/generated/UsingSDK"
|
||||
system "export URHO3D_HOME=~/usr/local && cd ../Build/generated/UsingSDK && echo '\nDownstream project referencing Urho3D SDK' && ./cmake_generic.sh . #{$build_options} -DURHO3D_LUA#{jit}=1 -DURHO3D_TESTING=#{$testing} -DCMAKE_BUILD_TYPE=#{$configuration} && make -j$NUMJOBS #{test}" or abort 'Failed to configure/build/test temporary downstream project using Urho3D as external library'
|
||||
system "export URHO3D_HOME=~/usr/local && cd ../Build/generated/UsingSDK && echo '\nConfiguring downstream project using Urho3D SDK...' && ./cmake_generic.sh . #{$build_options} -DURHO3D_LUA#{jit}=1 -DURHO3D_TESTING=#{$testing} -DCMAKE_BUILD_TYPE=#{$configuration} && make -j$NUMJOBS #{test}" or abort 'Failed to configure/build/test temporary downstream project using Urho3D as external library'
|
||||
end
|
||||
# Make, deploy, and test run Android APK in an Android (virtual) device
|
||||
if ENV['AVD'] && !ENV['PACKAGE_UPLOAD']
|
||||
|
@ -733,13 +733,13 @@ def xcode_ci
|
|||
unless ENV['CI'] && ENV['IOS'] && ENV['PACKAGE_UPLOAD'] # Skip scaffolding test when packaging for iOS
|
||||
# Create a new project on the fly that uses newly built Urho3D library in the build tree
|
||||
scaffolding "../Build/generated/UsingBuildTree"
|
||||
system "cd ../Build/generated/UsingBuildTree && echo '\nDownstream project referencing Urho3D library in its build tree' && ./cmake_macosx.sh . -DIOS=$IOS #{$build_options} -DURHO3D_HOME=../.. -DURHO3D_LUA#{jit}=1 -DURHO3D_TESTING=#{$testing}" or abort 'Failed to configure temporary project using Urho3D as external library'
|
||||
system "cd ../Build/generated/UsingBuildTree && echo '\nConfiguring downstream project using Urho3D library in its build tree...' && ./cmake_macosx.sh . -DIOS=$IOS #{$build_options} -DURHO3D_HOME=../.. -DURHO3D_LUA#{jit}=1 -DURHO3D_TESTING=#{$testing}" or abort 'Failed to configure temporary project using Urho3D as external library'
|
||||
xcode_build(ENV['IOS'], '../Build/generated/UsingBuildTree/Scaffolding.xcodeproj') or abort 'Failed to build/test temporary downstream project using Urho3D as external library'
|
||||
ENV['DESTDIR'] = ENV['HOME'] || Dir.home
|
||||
wait_for_block("\nInstalling Urho3D SDK to #{ENV['DESTDIR']}/usr/local...") { Thread.current[:exit_code] = xcode_build(ENV['IOS'], '../Build/Urho3D.xcodeproj', 'install', '>/dev/null') } or abort 'Failed to install Urho3D SDK'
|
||||
# Create a new project on the fly that uses newly installed Urho3D SDK
|
||||
scaffolding "../Build/generated/UsingSDK"
|
||||
system "export URHO3D_HOME=~/usr/local && cd ../Build/generated/UsingSDK && echo '\nDownstream project referencing Urho3D SDK' && ./cmake_macosx.sh . -DIOS=$IOS #{$build_options} -DURHO3D_LUA#{jit}=1 -DURHO3D_TESTING=#{$testing}" or abort 'Failed to configure temporary downstream project using Urho3D as external library'
|
||||
system "export URHO3D_HOME=~/usr/local && cd ../Build/generated/UsingSDK && echo '\nConfiguring downstream project using Urho3D SDK...' && ./cmake_macosx.sh . -DIOS=$IOS #{$build_options} -DURHO3D_LUA#{jit}=1 -DURHO3D_TESTING=#{$testing}" or abort 'Failed to configure temporary downstream project using Urho3D as external library'
|
||||
xcode_build(ENV['IOS'], '../Build/generated/UsingSDK/Scaffolding.xcodeproj') or abort 'Failed to build/test temporary downstream project using Urho3D as external library'
|
||||
end
|
||||
end
|
||||
|
|
|
@ -20,15 +20,12 @@
|
|||
# THE SOFTWARE.
|
||||
#
|
||||
|
||||
# Set project name
|
||||
if (CMAKE_PROJECT_NAME STREQUAL Urho3D)
|
||||
# Set project name
|
||||
project (Urho3D-Clang-Tools)
|
||||
else ()
|
||||
project (Urho3D-ExternalProject-${URHO3D_CLANG_TOOLS})
|
||||
|
||||
# Set minimum version
|
||||
# Set CMake minimum version and CMake policy required by Urho3D-CMake-common module
|
||||
cmake_minimum_required (VERSION 2.8.6)
|
||||
|
||||
if (COMMAND cmake_policy)
|
||||
cmake_policy (SET CMP0003 NEW)
|
||||
if (CMAKE_VERSION VERSION_GREATER 2.8.12 OR CMAKE_VERSION VERSION_EQUAL 2.8.12)
|
||||
|
@ -43,6 +40,9 @@ else ()
|
|||
endif ()
|
||||
endif ()
|
||||
|
||||
# Set project name
|
||||
project (Urho3D-ExternalProject-${URHO3D_CLANG_TOOLS})
|
||||
|
||||
# Set CMake modules search path
|
||||
set (CMAKE_MODULE_PATH ${BAKED_CMAKE_SOURCE_DIR}/CMake/Modules)
|
||||
|
||||
|
|
|
@ -25,12 +25,8 @@ if (CMAKE_PROJECT_NAME STREQUAL ExternalProject-tolua++)
|
|||
# We only want to keep the buildvm host tool which is built for cross-compiling target (the one built from internal LuaJIT CMake-target)
|
||||
set (DEST_RUNTIME_DIR "") # In this particular case, it is not equivalent to unset() the variable
|
||||
elseif (NOT CMAKE_PROJECT_NAME STREQUAL Urho3D)
|
||||
# Set project name
|
||||
project (Urho3D-ExternalProject-buildvm)
|
||||
|
||||
# Set minimum version
|
||||
# Set CMake minimum version and CMake policy required by Urho3D-CMake-common module
|
||||
cmake_minimum_required (VERSION 2.8.6)
|
||||
|
||||
if (COMMAND cmake_policy)
|
||||
cmake_policy (SET CMP0003 NEW)
|
||||
if (CMAKE_VERSION VERSION_GREATER 2.8.12 OR CMAKE_VERSION VERSION_EQUAL 2.8.12)
|
||||
|
@ -45,6 +41,9 @@ elseif (NOT CMAKE_PROJECT_NAME STREQUAL Urho3D)
|
|||
endif ()
|
||||
endif ()
|
||||
|
||||
# Set project name
|
||||
project (Urho3D-ExternalProject-buildvm)
|
||||
|
||||
# Set CMake modules search path
|
||||
set (CMAKE_MODULE_PATH ${BAKED_CMAKE_SOURCE_DIR}/CMake/Modules)
|
||||
|
||||
|
|
|
@ -21,12 +21,8 @@
|
|||
#
|
||||
|
||||
if (NOT CMAKE_PROJECT_NAME STREQUAL Urho3D)
|
||||
# Set project name
|
||||
project (Urho3D-ExternalProject-tolua++)
|
||||
|
||||
# Set minimum version
|
||||
# Set CMake minimum version and CMake policy required by Urho3D-CMake-common module
|
||||
cmake_minimum_required (VERSION 2.8.6)
|
||||
|
||||
if (COMMAND cmake_policy)
|
||||
cmake_policy (SET CMP0003 NEW)
|
||||
if (CMAKE_VERSION VERSION_GREATER 2.8.12 OR CMAKE_VERSION VERSION_EQUAL 2.8.12)
|
||||
|
@ -41,6 +37,9 @@ if (NOT CMAKE_PROJECT_NAME STREQUAL Urho3D)
|
|||
endif ()
|
||||
endif ()
|
||||
|
||||
# Set project name
|
||||
project (Urho3D-ExternalProject-tolua++)
|
||||
|
||||
# Set CMake modules search path
|
||||
set (CMAKE_MODULE_PATH ${BAKED_CMAKE_SOURCE_DIR}/CMake/Modules)
|
||||
|
||||
|
|
|
@ -21,12 +21,8 @@
|
|||
#
|
||||
|
||||
if (NOT CMAKE_PROJECT_NAME STREQUAL Urho3D)
|
||||
# Set project name
|
||||
project (Urho3D-ExternalProject-PackageTool)
|
||||
|
||||
# Set minimum version
|
||||
# Set CMake minimum version and CMake policy required by Urho3D-CMake-common module
|
||||
cmake_minimum_required (VERSION 2.8.6)
|
||||
|
||||
if (COMMAND cmake_policy)
|
||||
cmake_policy (SET CMP0003 NEW)
|
||||
if (CMAKE_VERSION VERSION_GREATER 2.8.12 OR CMAKE_VERSION VERSION_EQUAL 2.8.12)
|
||||
|
@ -41,6 +37,9 @@ if (NOT CMAKE_PROJECT_NAME STREQUAL Urho3D)
|
|||
endif ()
|
||||
endif ()
|
||||
|
||||
# Set project name
|
||||
project (Urho3D-ExternalProject-PackageTool)
|
||||
|
||||
# Set CMake modules search path
|
||||
set (CMAKE_MODULE_PATH ${BAKED_CMAKE_SOURCE_DIR}/CMake/Modules)
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче