From 16a409af6aaa08a49519fc185df7966fcdc99e7f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois=20Andriot?= Date: Tue, 14 Apr 2020 08:49:44 +0200 Subject: [PATCH] Fix boost_python library detection on CentOS 8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: François Andriot --- ConfigureChecks.cmake | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/ConfigureChecks.cmake b/ConfigureChecks.cmake index 24c10fa9..a2d6593a 100644 --- a/ConfigureChecks.cmake +++ b/ConfigureChecks.cmake @@ -100,6 +100,10 @@ if( BUILD_KIG AND WITH_KIG_PYTHON_SCRIPTING ) find_package( Boost COMPONENTS python${PYTHON_VERSION_MAJOR}${PYTHON_VERSION_MINOR} ) +if( NOT Boost_FOUND ) + find_package( Boost COMPONENTS python${PYTHON_VERSION_MAJOR} ) +endif( ) + if( NOT Boost_FOUND ) find_package( Boost COMPONENTS python ) endif( ) @@ -110,6 +114,9 @@ if( NOT Boost_FOUND ) set( KIG_ENABLE_PYTHON_SCRIPTING 1 ) endif( NOT Boost_FOUND ) +if( NOT Boost_PYTHON_LIBRARY AND Boost_PYTHON${PYTHON_VERSION_MAJOR}_LIBRARY ) + set( Boost_PYTHON_LIBRARY "${Boost_PYTHON${PYTHON_VERSION_MAJOR}_LIBRARY}" ) +endif( ) if( NOT Boost_PYTHON_LIBRARY AND Boost_PYTHON${PYTHON_VERSION_MAJOR}${PYTHON_VERSION_MINOR}_LIBRARY ) set( Boost_PYTHON_LIBRARY "${Boost_PYTHON${PYTHON_VERSION_MAJOR}${PYTHON_VERSION_MINOR}_LIBRARY}" ) endif( )