Gate-controlled superconducting proximity effect in ultrathin graphite films