tech-pkg archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Rewrite mk/checksum/checksum in awk

Hey all,

While working on an upgrade to www/grafana, I needed to use the new support.  This resulted in over 600 distfiles to verify,
and the current shell script cannot keep up, with a quadratic runtime
of over 8 minutes for 'bmake checksum'.

I took the opportunity to rewrite the script in awk:

and now it takes less than 4 seconds.

I'm still working through testing this, aiming to support all of the
perculiar features of the existing script (who knew "IGNORE" was a
supported checksum?) and retain 100% compatibility, but figured I'd
throw it out to others for extra testing and review in the meantime.


Jonathan Perkin  -  Joyent, Inc.  -

Home | Main Index | Thread Index | Old Index