
SET(ENET_SEARCH_PATHS
    /usr/local/
    /usr
    /opt
)

FIND_PATH(ENET_INCLUDE_DIR enet/enet.h
    HINTS ${ENET_ROOT}
    PATH_SUFFIXES include include/enet
    PATHS ${ENET_SEARCH_PATHS}
)
FIND_LIBRARY(ENET_LIBRARY enet
    HINTS ${ENET_ROOT}
    PATH_SUFFIXES lib64 lib bin
    PATHS ${ENET_SEARCH_PATHS}
)

IF(ENET_INCLUDE_DIR AND ENET_LIBRARY)
   SET(ENET_FOUND TRUE)
ENDIF (ENET_INCLUDE_DIR AND ENET_LIBRARY)


IF(ENET_FOUND)
    MESSAGE(STATUS "Found ENet: ${ENET_LIBRARY}")
ELSE(ENET_FOUND)
    MESSAGE(WARNING "Could not find ENet")
ENDIF(ENET_FOUND)
