add attributes to fix dead_code and unused_imports

I started cleaning up compilation warnings for dead_code and unused_imports.  When rust files are compiled with `--test`, much of the code and imports aren't used.  An open rust bug about main being dead code is https://github.com/mozilla/rust/issues/13793

We could disable the warnings globally in the makefile, but then you lose the sanity check.  I think the lesser of two evils is to add the config attributes to each file.