This question is more of theoretical nature than of practical use.
I know that there are several programs to find unused code, but this question is a little bit different then that.
Would it be possible to find unused code and resources during or after the build and remove it? I've several 'generic' libraries which are shared across many projects, and each project is only using a part of those libraries (overlapping and may change in the future, so no direct refactoring possible and I don't feel like breaking those further down). My idea was to remove these unused parts to keep the resulting files small.
So, what are my odds to accomplish this?
Edit: There's a tool from the Mono-Framework available called Mono.Linker, which does exactly what I was looking (in combination with mkbundle). Unfortunately, the build seems to be broken due to changes in Mono.Cecil. I'll see if I can fix that.