build in top level directory
merge makefile, simplify preprocessing logic
simplify preprocessing rule