FIND_PATH(CONFIG++_INCLUDE_DIRS libconfig.h++ /usr/include /usr/local/include)

FIND_LIBRARY(CONFIG++_LIBRARIES NAMES config++ PATH /usr/lib /usr/local/lib) 

IF (CONFIG++_INCLUDE_DIR AND CONFIG++_LIBRARIES)
    SET(CONFIG++_FOUND TRUE)
ENDIF ( CONFIG++_INCLUDE_DIR AND CONFIG++_LIBRARIES)

IF (CONFIG++_FOUND)
    IF (NOT CONFIG++_FIND_QUIETLY)
	MESSAGE(STATUS "Found Config++: ${CONFIG++_LIBRARIES}")
    ENDIF (NOT  CONFIG++_FIND_QUIETLY)
ELSE(CONFIG++_FOUND)
    IF (Config++_FIND_REQUIRED)
	IF(NOT CONFIG++_INCLUDE_DIR)
	    MESSAGE(FATAL_ERROR "Could not find LibConfig++ header file!")
	ENDIF(NOT CONFIG++_INCLUDE_DIR)

	IF(NOT CONFIG++_LIBRARIES)
	    MESSAGE(FATAL_ERROR "Could not find LibConfig++ library file!")
	ENDIF(NOT CONFIG++_LIBRARIES)
    ENDIF (Config++_FIND_REQUIRED)
ENDIF (CONFIG++_FOUND)
