[Toybox] Hello, I would like to carve out a project

Rob Landley rob at landley.net
Fri May 24 10:44:16 PDT 2013


On 05/24/2013 12:06:37 PM, Terrel Shumway wrote:
> > need to swap uClibc out for
> > musl as soon as I get time to rewrite ccwrap. (After finishing  
> mount.c.)
> 
> OT: Exactly what remains to ditch uClibc? musl looks pretty complete.

It's not musl that's incomplete (so far, anyway), it's my ccwrap.c.

I use a wrapper binary to rewrite the gcc command line to take all the  
pathing decisions out of gcc's hands (making the toolchain relocatable,  
making it link against stuff other than glibc, making it _not_ confused  
by cross compiling, etc).

Musl's compiler wrapper uses a different mechanism for this, which  
doesn't for example allow a statically linked toolchain to run from  
whatever directory you happen to extract it into. (So you can't build a  
universal binary that will run from a user's home directory without  
needing root access to install it.) I use the wrapper even for the  
native toolchain (because I'm not patching out its glibc-isms, telling  
it -nostdinc -nostdlib and then explicitly telling it what to include  
and link against because the word "pathological" may not have been  
invented specifically to describe gcc's path logic, but still does an  
excellent job).

The ccwrap I've been using started life as a uClibc-specific tool  
(which went on to be modified by timesys and then by me), developed a  
lot of scar tissue over the years, and is full of uClibc-specific  
assumptions.

Rather than add a new set of assumptions embedded in _more_ scar  
tissue, I decided to write a fresh wrapper from scratch, which could  
also be used as the basis of a distcc replacement and eventually qcc.  
(As long as I'm parsing the compiler command line anyway, I might as  
well make the code generally useful.)

Alas, I have a chronic shortage of time when I'm working an unrelated  
day job (projects at work tend to expand from 40 hours/week to "all my  
time" to "I remember sleep" as deadlines approach), and now that I'm  
married with a real house I don't have the gaps between contracts I  
used to.

I'm putting together a kickstarter variant (indiegogo actually) to see  
if any of the companies that might find the stuff I'm doing useful want  
to sponsor me to work on it full-time for a while. If not, at least  
I'll have an excuse not to feel guilty about only scraping up around 5  
hours/week to work on it...

> > Unfortunately, qemu 1.2 was the last good release, 1.3 and 1.4 have  
> glitches
> > in tcg, and when they finally fixed that in 1.5 (commit  
> 52ae646d4a3e) they
> > screwed up the arm versatile board emulation's IRQ routing (in  
> commit
> > 66a96d7018b9). I need to poke 'em and maybe they can get a fix into  
> 1.5.1 or
> > something...
> 
> hmm... I remember something about "submit small patches that touch few
> files" ;-)
> (this is why I prefer git over hg (slightly))

They did submit small patches that touched few files. The problem is  
they did about 2000 commits between 1.4 and 1.5:

   $ git log v1.5.0...03e94e39 | grep '^commit ' | wc -l
   1931

And deeply insufficient regression testing. (I should throw the  
aboriginal linux images at 'em and go "they all used to work, if you  
break them please fix them".)

I've been using git reasonably heavily for several years, and I _still_  
find its user interface obnoxious and confusing and waste ten minutes  
looking up how to do something obvious that I did last week but I'm  
getting some subtle detail wrong. (And that's _after_ they rewrote it  
in 1.5.)

I still don't know how to do "hg cat -r 1234 filename" in git. I  
managed to do it once, and totally don't remember, and wouldn't know  
where to start looking it up. In theory something like "git show nbd.c  
-- 123456789" except that doesn't work for at least 2 reasons. (I  
always get file and hash order wrong, and "show" does 8 gazillion magic  
thing depending on context, almost none of which is what I actually  
want. But "git cat", doesn't exist, nor do "git display", git  
"examine"... "hg help" lists all the interesting commands, including  
cat. "git help" does not, the closest I get out of that is "show". I  
think I have to check out the whole tree in order to see a version of a  
file...)

Sorry for the verbosity. Symptom of sleep deprivation...

Rob


More information about the Toybox mailing list