separate out static dependencies of core on java backend

@andreistefanescu @yilongli @cos please review
should we remove this?