Commit 1e0c1da1 authored by Daniel Wortmann's avatar Daniel Wortmann

Added FLEUR_USE_WANNIER environment

parent 2ad33566
......@@ -4,7 +4,18 @@ try_compile(FLEUR_USE_WANN4 ${CMAKE_BINARY_DIR} ${CMAKE_SOURCE_DIR}/cmake/tests/
)
message("Wannier90-4 1.2 Library found:${FLEUR_USE_WANN4}")
if (DEFINED ENV{FLEUR_USE_WANNIER})
if (ENV{FLEUR_USE_WANNIER})
if (NOT FLEUR_USE_WANN)
message(FATAL_ERROR "You asked for Wannier90 but cmake couldn't find it. Please check your Fortran compiler settings")
endif()
else()
if (FLEUR_USE_WANN)
message("Wannier library found, but you explicitely asked not to use it")
set(FLEUR_USE_WANN FALSE)
endif()
endif()
endif()
if (FLEUR_USE_WANN4)
set(FLEUR_DEFINITIONS ${FLEUR_DEFINITIONS} "CPP_WANN4")
set(FLEUR_MPI_DEFINITIONS ${FLEUR_MPI_DEFINITIONS} "CPP_WANN4")
......
......@@ -4,7 +4,18 @@ try_compile(FLEUR_USE_WANN5 ${CMAKE_BINARY_DIR} ${CMAKE_SOURCE_DIR}/cmake/tests/
)
message("Wannier90-5 1.2 Library found:${FLEUR_USE_WANN5}")
if (DEFINED ENV{FLEUR_USE_WANNIER})
if (ENV{FLEUR_USE_WANNIER})
if (NOT FLEUR_USE_WANN)
message(FATAL_ERROR "You asked for Wannier90 but cmake couldn't find it. Please check your Fortran compiler settings")
endif()
else()
if (FLEUR_USE_WANN)
message("Wannier library found, but you explicitely asked not to use it")
set(FLEUR_USE_WANN FALSE)
endif()
endif()
endif()
if (FLEUR_USE_WANN5)
set(FLEUR_DEFINITIONS ${FLEUR_DEFINITIONS} "CPP_WANN5")
set(FLEUR_MPI_DEFINITIONS ${FLEUR_MPI_DEFINITIONS} "CPP_WANN5")
......
......@@ -5,6 +5,19 @@ try_compile(FLEUR_USE_WANN ${CMAKE_BINARY_DIR} ${CMAKE_SOURCE_DIR}/cmake/tests/t
message("Wannier90 1.2 Library found:${FLEUR_USE_WANN}")
if (DEFINED ENV{FLEUR_USE_WANNIER})
if (ENV{FLEUR_USE_WANNIER})
if (NOT FLEUR_USE_WANN)
message(FATAL_ERROR "You asked for Wannier90 but cmake couldn't find it. Please check your Fortran compiler settings")
endif()
else()
if (FLEUR_USE_WANN)
message("Wannier library found, but you explicitely asked not to use it")
set(FLEUR_USE_WANN FALSE)
endif()
endif()
endif()
if (FLEUR_USE_WANN)
set(FLEUR_DEFINITIONS ${FLEUR_DEFINITIONS} "CPP_WANN")
set(FLEUR_MPI_DEFINITIONS ${FLEUR_MPI_DEFINITIONS} "CPP_WANN")
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment