Pass the command same as the sql command and try.

Create two variables and generate the values there.
V_1:=p_surname||'%'||p_firstname||'%';
v_2:=p_firstname||'%'||p_surname||'%';

Run the changed sql.
select surname,firstname into x_surname,x_firstname from departure_all
where ((fullname like v_1) or
(fullname like v_2))
and departure_date>'31-DEC-04' and rownum<2;