Commit Graph

14 Commits (a4110a59c5ec9a016f26061b217cd7bc15bd40dc)

Author SHA1 Message Date
Kalyan Kumar b990f703a0 Add IMPORTED_CONFIGURATIONS property to cmake target. 2020-05-07 15:05:40 -07:00
Robikz 379d59bcbd Erase the remaining _INSTALL_PREFIX and LIBSUFFIX in CMake files
These seem to have survived from the migration to GNUInstallDirs in
9fb81c3be6

_INSTALL_PREFIX was not set anywhere and resolved to empty value, which
in turn caused some paths in the installed lib config CMake files to
start from '/', effectively causing the failure of the "do the installed
files exist" checks.

After complete replacement of all uses of the _INSTALL_PREFIX with
GNUInstallDirs equivalents, the LIBSUFFIX variable has become unused
and can be removed too.
2020-04-16 16:02:34 +02:00
Kim Kulling 2d4eab6db0
Merge branch 'master' into cmake_targets_determine_lib_path 2020-04-16 08:08:37 +02:00
Victor Mataré 9fb81c3be6 use GNUInstallDirs where possible
Emulate the CMAKE_INSTALL_FULL_* variables on non-Unix systems and
disable redefining FHS-mandated install locations via user-editable
ASSIMP_*_INSTALL_DIR variables. Instead, if it REALLY proves necessary,
Unix users can edit the advanced, canonical CMAKE_INSTALL_* variables.
2020-04-03 00:44:44 +02:00
Kim Kulling 3eba67dca3
Merge branch 'master' into cmake_targets_determine_lib_path 2020-03-12 20:24:12 +01:00
Nikita Shubin 3c081f5f70 [RFC] cmake: targets: check lib or lib64 path
Linkage against lib or lib64 should be taken into assumption.

Without it we get:

The imported target "assimp::assimp" references the file

     "/usr/lib/libassimp.so.5"

When compiling against x86_64 target. The library of couse exits in
/usr/lib64.

see:
https://cmake.org/cmake/help/v3.17/prop_gbl/FIND_LIBRARY_USE_LIB64_PATHS.html

As i am not a master of cmake this should be double checked if
it doesn't break anything.

Signed-off-by: Nikita Shubin <NShubin@topcon.com>
2020-02-26 17:06:22 +03:00
Nikita Shubin 4182d6fb60 cmake: double quotes around the <path>
see https://cmake.org/cmake/help/latest/command/file.html#to-native-path
2020-02-26 16:24:34 +03:00
Kim Kulling 58729b1b3d fix debug-target. 2019-11-09 11:28:56 +01:00
Kim Kulling d3ddf8de60
Merge branch 'master' into mingw-fix-2685 2019-10-12 11:24:33 +02:00
Robikz 0761530e17 Set proper sharedLibraryName for MinGW in installed assimpTargets-*.cmake
The shared library name for MinGW is the .a library with which we need to
link the built binary. This problem is described in issue #2685.
2019-10-06 19:03:00 +02:00
Dániel Molnár ae3236f481 Support Apple naming conventions - shared library 2019-09-25 18:03:26 +02:00
PK d24b6e220b
toolset changes in debug cmake template 2019-06-11 15:24:39 +02:00
Jack Andersen d048bccad1 Export static libaries as CMake package
When built with BUILD_SHARED_LIBS disabled, the exported CMake
targets are modified to reference the static library location.

This also fixes version detection for VS2017 and beyond within
the target import script.
2019-05-24 22:06:50 -10:00
dormon b43cf92337 Improved cmake configs for Windows and Linux.
Now the configs follows the standard cmake-package code: see https://cmake.org/cmake/help/v3.12/manual/cmake-packages.7.html

Downstreamer no longer have to manually specify target_include_directories with ${ASSIMP_INCLUDE_DIRS}, target_link_libraries with ${ASSIMP_LIBRARY_DIRS} and so on.

Downstreamer can now use:
find_package(assimp CONFIG REQUIRED)
target_link_libraries(AWESOME_APP PUBLIC assimp::assimp)
and everything should work.

Added assimpTargets.cmake.in
Added assimpTargets-debug.cmake.in
Added assimpTargets-release.cmake.in
Modified CMakeLists.txt
Modified code/CMakeLists.txt - added ALIAS assimp::assimp

Tested on Ubuntu 18.04 and Windows 10
2018-09-30 17:18:18 +02:00