Fix bugs in PMI configure: set correct include path, fix test command with multiple conditions.