Restore tcs.c

This file used to live in user/util/tcs.c and
was deleted in this commit:

  ea456d79a3bd7fed833df6c3817ec82adba15129
compile tcs
Make directories for general-purpose, platform-dependent code