summaryrefslogtreecommitdiff
path: root/scripts/basic
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/basic')
-rw-r--r--scripts/basic/fixdep.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/scripts/basic/fixdep.c b/scripts/basic/fixdep.c
index f387538c58bc..850966f3d602 100644
--- a/scripts/basic/fixdep.c
+++ b/scripts/basic/fixdep.c
@@ -115,7 +115,7 @@ static void usage(void)
*/
static void print_dep(const char *m, int slen, const char *dir)
{
- int c, i;
+ int c, prev_c = '/', i;
printf(" $(wildcard %s/", dir);
for (i = 0; i < slen; i++) {
@@ -124,7 +124,9 @@ static void print_dep(const char *m, int slen, const char *dir)
c = '/';
else
c = tolower(c);
- putchar(c);
+ if (c != '/' || prev_c != '/')
+ putchar(c);
+ prev_c = c;
}
printf(".h) \\\n");
}