You don't have to choose a target for Proctor's Gaze. However, if you do and the target is illegal as Proctor's Gaze tries to resolve, it won't resolve and none of its effects will happen. You won't search your library.
Return up to one target nonland permanent to its owner's hand. Search your library for a basic land card, put it onto the battlefield tapped, then shuffle.