SET(BLSURF_INCLUDES)
SET(BLSURF_INCLUDES ${BLSURF_INCLUDES} -I${BLSURF_INCLUDES_DIR})
-FIND_LIBRARY(BLSurf BLSurf PATHS ${BLSURFHOME}/lib ${BLSURFHOME}/lib/WinXP_VC9)
-FIND_LIBRARY(distene distene PATHS ${BLSURFHOME}/lib ${BLSURFHOME}/lib/WinXP_VC9)
+SET(BLSURF_LIBS_PATHS)
+SET(BLSURF_LIBS_PATHS ${BLSURF_LIBS_PATHS} ${BLSURFHOME}/lib)
+IF(WINDOWS)
+ SET(BLSURF_LIBS_PATHS ${BLSURF_LIBS_PATHS} ${BLSURFHOME}/lib/WinXP_VC9)
+ELSE(WINDOWS)
+ IF(CMAKE_SIZEOF_VOID_P STREQUAL 8)
+ SET(BLSURF_LIBS_PATHS ${BLSURF_LIBS_PATHS} ${BLSURFHOME}/lib/Linux_64)
+ ELSE()
+ SET(BLSURF_LIBS_PATHS ${BLSURF_LIBS_PATHS} ${BLSURFHOME}/lib/Linux)
+ ENDIF()
+ENDIF(WINDOWS)
+
+FIND_LIBRARY(BLSurf BLSurf PATHS ${BLSURF_LIBS_PATHS})
+FIND_LIBRARY(distene distene PATHS ${BLSURF_LIBS_PATHS})
SET(BLSURF_LIBS)
SET(BLSURF_LIBS ${BLSURF_LIBS} ${BLSurf})