ENH: Fix allows java cmake build