Question: how long does it take to clear immigration at philadelphia?
Answer: 2.5 hours would be an absolute minimum - even allowing for inbound delays, deplaning/immigration/baggage claim/customs/baggage re-check and possibly a change of terminal.