[Toybox] make menuconfig

Felix Janda felix.janda at posteo.de
Mon May 4 10:57:51 PDT 2015


Rob Landley wrote:
> On 05/02/2015 02:54 PM, enh wrote:
> > anyone else having trouble with "make menuconfig"? getprop and setprop
> > aren't showing up for me, and i don't see where to set
> > CONFIG_TOYBOX_ON_ANDROID and generated/mkflags segfaults if i have ls
> > configured and...
> > 
> > actually, downloading a clean toybox git repo, "make defconfig &&
> > make" reproduces the segfault, so at least it's not Android-specific.
> > posting early in case anyone's already debugged this...
> 
> FYI I had a test wrong in the config parser. It was triggered by
> configuring out a command line option that was the last (leftmost) short
> option in a config that also had bare longopts.

I just wanted to say that not everything is yet fixed. For example
'ls --color' does not work at all. (Seems to be related to the option
parsing.)

Also even on a terminal ls now only shows one directory per line. With the
following hack, the previous behavior is restored in my case.

diff --git a/toys/posix/ls.c b/toys/posix/ls.c
index 9c4d6d3..d783eca 100644
--- a/toys/posix/ls.c
+++ b/toys/posix/ls.c
@@ -344,7 +344,7 @@ static void listfiles(int dirfd, struct dirtree *indir)
         if (len[width]>totals[width]) totals[width] = len[width];
       blocks += sort[ul]->st.st_blocks;
     }
-    totpad = totals[1]+!!totals[1]+totals[6]+!!totals[6]+totals[7]+!!totals[7];
+    totpad = totals[1]+!!totals[1]+totals[6]+!!totals[6];//+totals[7]+!!totals[7];
     if (flags & (FLAG_l|FLAG_o|FLAG_n|FLAG_g|FLAG_s) && indir->parent)
       xprintf("total %llu\n", blocks);
   }

Thanks,
Felix

 1430762271.0


More information about the Toybox mailing list