Fixup the samba generation script a bit.

Based on input from a core samba developer move some things
around and make some changes.

Also remove an unused import and comment out some code
that doesn't get used since it's consumers are commented out.