STYLE: Nightly Date Stamp
[cmake.git] / Modules / FindSDL_net.cmake
blob6de1946fae2ad4535d5462fbfb94e3af61528479
1 # Locate SDL_net library
2 # This module defines
3 # SDLNET_LIBRARY, the name of the library to link against
4 # SDLNET_FOUND, if false, do not try to link against
5 # SDLNET_INCLUDE_DIR, where to find the headers
7 # $SDLDIR is an environment variable that would
8 # correspond to the ./configure --prefix=$SDLDIR
9 # used in building SDL.
11 # Created by Eric Wing. This was influenced by the FindSDL.cmake 
12 # module, but with modifications to recognize OS X frameworks and 
13 # additional Unix paths (FreeBSD, etc).
16 FIND_PATH(SDLNET_INCLUDE_DIR SDL_net.h
17   HINTS
18   $ENV{SDLNETDIR}
19   $ENV{SDLDIR}
20   PATH_SUFFIXES include
21   PATHS
22   ~/Library/Frameworks
23   /Library/Frameworks
24   /usr/local/include/SDL
25   /usr/include/SDL
26   /usr/local/include/SDL12
27   /usr/local/include/SDL11 # FreeBSD ports
28   /usr/include/SDL12
29   /usr/include/SDL11
30   /usr/local/include
31   /usr/include
32   /sw/include/SDL # Fink
33   /sw/include
34   /opt/local/include/SDL # DarwinPorts
35   /opt/local/include
36   /opt/csw/include/SDL # Blastwave
37   /opt/csw/include 
38   /opt/include/SDL
39   /opt/include
41 FIND_LIBRARY(SDLNET_LIBRARY 
42   NAMES SDL_net
43   HINTS
44   $ENV{SDLNETDIR}
45   $ENV{SDLDIR}
46   PATH_SUFFIXES lib64 lib
47   PATHS
48   ~/Library/Frameworks
49   /Library/Frameworks
50   /usr/local
51   /usr
52   /sw
53   /opt/local
54   /opt/csw
55   /opt
58 SET(SDLNET_FOUND "NO")
59 IF(SDLNET_LIBRARY AND SDLNET_INCLUDE_DIR)
60   SET(SDLNET_FOUND "YES")
61 ENDIF(SDLNET_LIBRARY AND SDLNET_INCLUDE_DIR)