blob: 59f10a4856b9759dd8c793043b2a53779db76d98 [file] [log] [blame]
lh9ed821d2023-04-07 01:36:19 -07001BEGIN {
2 FS = " ";
3}
4
5{
6 for (i = 1; i <= NF; ++i) {
7 s[cnt++] = $i"/";
8 }
9}
10
11END {
12 printf ("#define SYSTEM_DIRS \\\n");
13
14 printf (" \"%s\"", s[0]);
15
16 for (i = 1; i < cnt; ++i) {
17 printf (" \"\\0\" \"%s\"", s[i]);
18 }
19
20 printf ("\n\n");
21
22 printf ("#define SYSTEM_DIRS_LEN \\\n");
23
24 printf (" %d", length (s[0]));
25 m = length (s[0]);
26
27 for (i = 1; i < cnt; ++i) {
28 printf (", %d", length(s[i]));
29 if (length(s[i]) > m) {
30 m = length(s[i]);
31 }
32 }
33
34 printf ("\n\n");
35
36 printf ("#define SYSTEM_DIRS_MAX_LEN\t%d\n", m);
37}