[CMake] the list parameter passed to function

Petr Kmoch petr.kmoch at gmail.com
Tue May 22 08:00:13 EDT 2012


Hi,

try as I might, I can't see a difference between the output and
expected output. Perhaps a copy-paste error?

Petr

On Tue, May 22, 2012 at 3:07 AM, Marmot Ken <realwangbo at gmail.com> wrote:
> here is the function :
>
> FUNCTION( Append_headers_to_src_list  src_list_out src_list_in
> header_file_path_in )
>     MESSAGE( src_list_in  " : ${src_list_in}" )
>     FILE( GLOB_RECURSE TEMP_LIST ${header_file_path_in}/*.h )
>     SET( ${src_list_out} ${src_list_in} ${TEMP_LIST} PARENT_SCOPE )
> ENDFUNCTION( Append_headers_to_src_list
>
>
> here is the place where the function is invoked:
>
> AUX_SOURCE_DIRECTORY( . SRC_LIST  )
> MESSAGE( SRC_LIST  " : ${SRC_LIST} " )
>
> Append_headers_to_src_list( SRC_LIST  ${SRC_LIST}
> ${CMAKE_SOURCE_DIR}/include/test  )
>
> here is output :
>
> SRC_LIST : ./a.cpp;./c.cpp;./main.cpp
> src_list_in : ./a.cpp
>
> Output expected :
>
> SRC_LIST : ./a.cpp;./c.cpp;./main.cpp
> src_list_in : ./a.cpp
>
> Question:
>       <1>  how to get expected Output ?
>         <2>  why ?
>
> Thanks.
>
> --
>
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at
> http://www.kitware.com/opensource/opensource.html
>
> Please keep messages on-topic and check the CMake FAQ at:
> http://www.cmake.org/Wiki/CMake_FAQ
>
> Follow this link to subscribe/unsubscribe:
> http://www.cmake.org/mailman/listinfo/cmake


More information about the CMake mailing list