committing some changes to support sharing of resources between applications
-some compiler error fixes
-still unstable, more commits to follow