ref: 706bd3d57a2f2b871b1eefb462ce66ecbd4a4c2b
parent: 7bd73b638a98cfc8978f7162a4058728c77a132c
parent: 4d8796a59cca0573fd5f38391452d8a3429191d6
author: James Zern <[email protected]>
date: Fri Apr 29 14:31:06 EDT 2016
Merge "msvs_common.sh: make fix_file_list generic"
--- a/build/make/gen_msvs_proj.sh
+++ b/build/make/gen_msvs_proj.sh
@@ -193,7 +193,7 @@
done
# Make one call to fix_path for file_list to improve performance.
-fix_file_list
+fix_file_list file_list
outfile=${outfile:-/dev/stdout}
guid=${guid:-`generate_uuid`}
--- a/build/make/gen_msvs_vcxproj.sh
+++ b/build/make/gen_msvs_vcxproj.sh
@@ -211,7 +211,7 @@
done
# Make one call to fix_path for file_list to improve performance.
-fix_file_list
+fix_file_list file_list
outfile=${outfile:-/dev/stdout}
guid=${guid:-`generate_uuid`}
--- a/build/make/msvs_common.sh
+++ b/build/make/msvs_common.sh
@@ -39,11 +39,12 @@
}
# Corrects the paths in file_list in one pass for efficiency.
+# $1 is the name of the array to be modified.
fix_file_list() {
- # TODO(jzern): this could be more generic and take the array as a param.
- files=$(fix_path "${file_list[@]}")
+ declare -n array_ref=$1
+ files=$(fix_path "${array_ref[@]}")
local IFS=$'\n'
- file_list=($files)
+ array_ref=($files)
}
generate_uuid() {