Matt Spinler | 12bdf05 | 2017-03-09 16:01:39 -0600 | [diff] [blame] | 1 | #!/bin/bash |
2 | |||||
3 | files=() | ||||
4 | echo "openpower_procedures_cpp_files = \\" | ||||
5 | for type in "$@"; | ||||
6 | do | ||||
7 | type=${type// /} #remove spaces | ||||
8 | for file in $(ls procedures/$type/*.cpp); | ||||
9 | do | ||||
10 | files+=($file) | ||||
11 | done | ||||
12 | done | ||||
13 | |||||
14 | for file in ${files[@]}; | ||||
15 | do | ||||
16 | echo " $file \\" | ||||
17 | done | ||||
18 | echo | ||||
19 | |||||
20 | cat << MAKEFILE | ||||
21 | openpower_procedures.cpp: \$(openpower_procedures_cpp_files) | ||||
22 | cat \$^ > \$@ | ||||
23 | |||||
24 | MAKEFILE |