Initial api and module loading work
More work on modules, updated build.xml for previous refactoring