On 02/10/2016 04:36 AM, Antonio Perez Barrero wrote:
>     find_library(${name}_LIBRARY
[snip]
> +   select_library_configurations(${name})
> +   set(${name}_LIBRARY_DEBUG ${${name}_LIBRARY_DEBUG} PARENT_SCOPE)
> +   set(${name}_LIBRARY ${${name}_LIBRARY} PARENT_SCOPE)
> +   set(${name}_LIBRARIES ${${name}_LIBRARIES} PARENT_SCOPE)

Thanks.  IIRC select_library_configurations needs the two inputs
to be <name>_LIBRARY_DEBUG and <name>_LIBRARY_RELEASE.  We'll
have to change the first find_library call to use _RELEASE.
The whole block can be arranged in the form

 if(${name}_LIBRARY)
   set(${name}_LIBRARIES "${${name}_LIBRARY}")
 else()
   ...current block, but with _RELEASE name...
 endif()

in order to be compatible with build scripts that expect to
set just ${name}_LIBRARY in the cache.

-Brad

-- 

Powered by www.kitware.com

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Kitware offers various services to support the CMake community. For more 
information on each offering, please visit:

CMake Support: http://cmake.org/cmake/help/support.html
CMake Consulting: http://cmake.org/cmake/help/consulting.html
CMake Training Courses: http://cmake.org/cmake/help/training.html

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Follow this link to subscribe/unsubscribe:
http://public.kitware.com/mailman/listinfo/cmake-developers

Reply via email to