wok rev 20654

busybox: add cook workaround
author Pascal Bellard <pascal.bellard@slitaz.org>
date Sun Jan 13 11:19:21 2019 +0100 (2019-01-13)
parents f635783d66b3
children cf687dbfb029
files busybox/receipt busybox/stuff/busybox-1.30-ash.u
line diff
     1.1 --- a/busybox/receipt	Sun Jan 13 10:59:57 2019 +0100
     1.2 +++ b/busybox/receipt	Sun Jan 13 11:19:21 2019 +0100
     1.3 @@ -47,6 +47,7 @@
     1.4  shutdown.u
     1.5  scriptreplay.u
     1.6  mkfs_vfat.u
     1.7 +ash.u
     1.8  EOT
     1.9      cp $stuff/$PACKAGE-${VERSION%.*}.config .config
    1.10  }
     2.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     2.2 +++ b/busybox/stuff/busybox-1.30-ash.u	Sun Jan 13 11:19:21 2019 +0100
     2.3 @@ -0,0 +1,17 @@
     2.4 +Some SliTaz scripts (cook) need that... 
     2.5 +--- busybox-1.30/shell/ash.c
     2.6 ++++ busybox-1.30/shell/ash.c
     2.7 +@@ -13171,7 +13171,13 @@
     2.8 + 	if (strchr(name, '/'))
     2.9 + 		return name;
    2.10 + 
    2.11 ++	/* IIRC standards do not say whether . is to be searched. Bash do it. */
    2.12 ++	if (ENABLE_ASH_BASH_COMPAT) {
    2.13 ++		fullname = name;
    2.14 ++		goto try_cur_dir;
    2.15 ++	}
    2.16 +	while ((fullname = path_advance(&path, name)) != NULL) {
    2.17 ++ try_cur_dir:
    2.18 + 		if ((stat(fullname, &statb) == 0) && S_ISREG(statb.st_mode)) {
    2.19 + 			/*
    2.20 + 			 * Don't bother freeing here, since it will