Google has entangled its Play framework deeply into the AOSP, obviously on purpose, not necessarily to discourage ROM developer, but I'm guessing primarily to discourage OEMs from changing AOSP too much, as well as slow down Android fork-developers such as Amazon.