Subthreshold antiproton production in nucleon-nucleus and nucleus-nucleus collisions