mirror of
https://gitee.com/openharmony/third_party_libsnd
synced 2024-11-23 09:59:54 +00:00
CMake/file.cmake: Handle leading space from wc output
This commit is contained in:
parent
6776ceafa8
commit
cb47664a80
@ -15,6 +15,7 @@ function (file_line_count filename variable)
|
||||
|
||||
execute_process (
|
||||
COMMAND ${WC} -l ${filename}
|
||||
COMMAND ${SED} "s/^[ ]*//" # wc output on Mac has leading whitespace.
|
||||
COMMAND ${SED} "s/ .*//"
|
||||
OUTPUT_VARIABLE line_count
|
||||
)
|
||||
|
Loading…
Reference in New Issue
Block a user