Fix build without Python support.

Only search for BoostPython3 if Python was found. Otherwise,
${PYTHONLIBS_VERSION_STRING} expands to nothing and the
find_boost_python3 macro gets called with invalid arguments.
This commit is contained in:
Kevin Kofler 2015-02-14 22:45:10 +01:00
parent 92b6464f6e
commit 18da15a087

View File

@ -45,16 +45,18 @@ macro_log_feature(
"Python 3 is used for some Calamares job modules." "Python 3 is used for some Calamares job modules."
) )
include( BoostPython3 ) if ( PYTHONLIBS_FOUND )
find_boost_python3( 1.54.0 ${PYTHONLIBS_VERSION_STRING} CALAMARES_BOOST_PYTHON3_FOUND ) include( BoostPython3 )
macro_log_feature( find_boost_python3( 1.54.0 ${PYTHONLIBS_VERSION_STRING} CALAMARES_BOOST_PYTHON3_FOUND )
CALAMARES_BOOST_PYTHON3_FOUND macro_log_feature(
"Boost.Python" CALAMARES_BOOST_PYTHON3_FOUND
"A C++ library which enables seamless interoperability between C++ and Python 3." "Boost.Python"
"http://www.boost.org" "A C++ library which enables seamless interoperability between C++ and Python 3."
FALSE "1.54.0" "http://www.boost.org"
"Boost.Python is used for interfacing with Calamares job modules written in Python 3." FALSE "1.54.0"
) "Boost.Python is used for interfacing with Calamares job modules written in Python 3."
)
endif()
if ( PYTHONLIBS_NOTFOUND OR NOT CALAMARES_BOOST_PYTHON3_FOUND ) if ( PYTHONLIBS_NOTFOUND OR NOT CALAMARES_BOOST_PYTHON3_FOUND )
set( WITH_PYTHON OFF ) set( WITH_PYTHON OFF )