Added command line tool and fixed reflection for transitive module dependencies