FindSDL.cmake 641 B

123456789101112131415161718192021222324252627282930313233
  1. # Locate SDL library
  2. # This module defines
  3. # SDL_LIBRARY, the name of the library to link against
  4. # SDL_FOUND, if false, do not try to link to SDL
  5. # SDL_INCLUDE_DIR, where to find SDL/SDL.h
  6. #
  7. # $SDLDIR is an environment variable that would
  8. # correspond to the ./configure --prefix=$SDLDIR
  9. # used in building SDL.
  10. # l.e.galup 9-20-02
  11. IF (UNIX)
  12. FIND_LIBRARY(SDL_LIBRARY SDL
  13. $ENV{SDLDIR}/lib
  14. /usr/lib
  15. /usr/local/lib
  16. )
  17. FIND_PATH( SDL_INCLUDE_DIR SDL/SDL.h
  18. $ENV{SDLDIR}/include
  19. /usr/include
  20. /usr/local/include
  21. )
  22. ENDIF (UNIX)
  23. SET( SDL_FOUND "NO" )
  24. IF(SDL_LIBRARY)
  25. SET( SDL_FOUND "YES" )
  26. ENDIF(SDL_LIBRARY)