This paper addresses relay selection(RS) and power allocation(PA) issues for a physical-layer network coding (PNC) relay based secondary user (SU) communication in cognitive radio networks, in which two secondary transceiver nodes exchange their information with the assistance of a relay under interference power threshold (IPT) constraints. We propose an optimal energy-efficient RS and PA (OE-RS-PA) scheme to minimize total energy consumption per bit with the sum rate constraint and IPT constraints. A closed-form solution for optimal allocation of transmit power among the SU nodes and relay node are then derived analytically and confirmed by numerical results. Furthermore, numerical simulations and comparisons are presented to illustrate the performance of the proposed scheme.