From afec2e2c4951830708587bb4df8bcf45a1e7c101 Mon Sep 17 00:00:00 2001 From: Engin Manap Date: Sat, 5 Oct 2019 19:23:02 +0200 Subject: [PATCH 1/4] Fix #2693 aiGetVersionMajor return wrong version The 2 constants MinorVersion and MajorVersion are updated for 5.0 --- code/Common/Version.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code/Common/Version.cpp b/code/Common/Version.cpp index cc94340ac..868cfb06a 100644 --- a/code/Common/Version.cpp +++ b/code/Common/Version.cpp @@ -46,8 +46,8 @@ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. #include #include "ScenePrivate.h" -static const unsigned int MajorVersion = 4; -static const unsigned int MinorVersion = 1; +static const unsigned int MajorVersion = 5; +static const unsigned int MinorVersion = 0; // -------------------------------------------------------------------------------- // Legal information string - don't remove this. From ecd413c86c031900832028c94c0d55488cf26a0a Mon Sep 17 00:00:00 2001 From: Kim Kulling Date: Sun, 6 Oct 2019 20:19:59 +0200 Subject: [PATCH 2/4] Update utVersion.cpp Fix the unittests as well. --- test/unit/utVersion.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/test/unit/utVersion.cpp b/test/unit/utVersion.cpp index 5cfc91ccd..233b2fb0b 100644 --- a/test/unit/utVersion.cpp +++ b/test/unit/utVersion.cpp @@ -4,8 +4,6 @@ Open Asset Import Library (assimp) Copyright (c) 2006-2019, assimp team - - All rights reserved. Redistribution and use of this software in source and binary forms, @@ -55,11 +53,11 @@ TEST_F( utVersion, aiGetLegalStringTest ) { } TEST_F( utVersion, aiGetVersionMinorTest ) { - EXPECT_EQ( aiGetVersionMinor(), 1U ); + EXPECT_EQ( aiGetVersionMinor(), 0U ); } TEST_F( utVersion, aiGetVersionMajorTest ) { - EXPECT_EQ( aiGetVersionMajor(), 4U ); + EXPECT_EQ( aiGetVersionMajor(), 5U ); } TEST_F( utVersion, aiGetCompileFlagsTest ) { From b8006cb4c9d016de0b20fd13851f40a646e9ea40 Mon Sep 17 00:00:00 2001 From: Maksym Sditanov Date: Mon, 7 Oct 2019 21:41:38 +0300 Subject: [PATCH 3/4] Findassimp.cmake: add hint for lib search path for Linux Add /usr/lib64 and /usr/lib directory hints to cmake module libassimp.so library installs in /usr/lib for 32bit or in /usr/lib64 for 64bit distros. All linux distros apply custom patch to extend cmake HINTs to systems /usr/lib and /usr/lib64 (see https://gitweb.gentoo.org/repo/gentoo.git/tree/media-libs/assimp/files/findassimp-3.3.1.patch) Signed-off-by: Maksym Sditanov --- cmake-modules/Findassimp.cmake | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/cmake-modules/Findassimp.cmake b/cmake-modules/Findassimp.cmake index 95f3250b3..23b975e68 100644 --- a/cmake-modules/Findassimp.cmake +++ b/cmake-modules/Findassimp.cmake @@ -62,6 +62,8 @@ else(WIN32) assimp_LIBRARIES NAMES assimp PATHS /usr/local/lib/ + PATHS /usr/lib64/ + PATHS /usr/lib/ ) if (assimp_INCLUDE_DIRS AND assimp_LIBRARIES) @@ -78,4 +80,4 @@ else(WIN32) endif (assimp_FIND_REQUIRED) endif (assimp_FOUND) -endif(WIN32) \ No newline at end of file +endif(WIN32) From 63a047119fb9bced398ebc7db240bfced60bb0be Mon Sep 17 00:00:00 2001 From: Maksym Sditanov Date: Mon, 7 Oct 2019 22:07:51 +0300 Subject: [PATCH 4/4] Findassimp.cmake: add hint for include path's for Linux By default, Linux distro installs assimp into /usr/include/assimp In case of this commit, fix hint path to include default path Signed-off-by: Maksym Sditanov --- cmake-modules/Findassimp.cmake | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/cmake-modules/Findassimp.cmake b/cmake-modules/Findassimp.cmake index 23b975e68..663645574 100644 --- a/cmake-modules/Findassimp.cmake +++ b/cmake-modules/Findassimp.cmake @@ -54,8 +54,10 @@ else(WIN32) find_path( assimp_INCLUDE_DIRS - NAMES postprocess.h scene.h version.h config.h cimport.h - PATHS /usr/local/include/ + NAMES assimp/postprocess.h assimp/scene.h assimp/version.h assimp/config.h assimp/cimport.h + PATHS /usr/local/include + PATHS /usr/include/ + ) find_library(