1 | # Several changes and additions by Fabian 'x3n' Landau |
---|
2 | # > www.orxonox.net < |
---|
3 | |
---|
4 | IF (OGG_INCLUDE_DIR AND OGG_LIBRARY) |
---|
5 | SET(OGG_FIND_QUIETLY TRUE) |
---|
6 | ENDIF (OGG_INCLUDE_DIR AND OGG_LIBRARY) |
---|
7 | |
---|
8 | IF (VORBIS_INCLUDE_DIR AND VORBIS_LIBRARY AND VORBISENC_LIBRARY AND VORBISFILE_LIBRARY) |
---|
9 | SET(VORBIS_FIND_QUIETLY TRUE) |
---|
10 | ENDIF (VORBIS_INCLUDE_DIR AND VORBIS_LIBRARY AND VORBISENC_LIBRARY AND VORBISFILE_LIBRARY) |
---|
11 | |
---|
12 | |
---|
13 | #SET(OGGVORBIS_LIBRARY_DIR "/usr/pack/oggvorbis-1.0-ds/i686-debian-linux3.0/lib") |
---|
14 | #SET(OGGVORBIS_LIBRARY "-L ${OGGVORBIS_LIBRARY_DIR} -lvorbisenc -lvorbisfile -logg -lvorbis ") |
---|
15 | #SET(OGGVORBIS_INCLUDE_DIR "/usr/pack/oggvorbis-1.0-ds/i686-debian-linux3.0/include") |
---|
16 | |
---|
17 | # |
---|
18 | # Includes |
---|
19 | # |
---|
20 | |
---|
21 | FIND_PATH(OGG_INCLUDE_DIR ogg/ogg.h |
---|
22 | /usr/pack/oggvorbis-1.0-ds/i686-debian-linux3.0/include # Tardis specific hack |
---|
23 | /usr/local/include |
---|
24 | /usr/include |
---|
25 | /sw/include |
---|
26 | /opt/local/include |
---|
27 | /opt/csw/include |
---|
28 | /opt/csw/include |
---|
29 | /opt/include |
---|
30 | ../libs/libogg-1.1.3/include |
---|
31 | ${DEPENDENCY_DIR}/libogg-1.1.3/include |
---|
32 | ) |
---|
33 | |
---|
34 | FIND_PATH(VORBIS_INCLUDE_DIR vorbis/codec.h |
---|
35 | /usr/pack/oggvorbis-1.0-ds/i686-debian-linux3.0/include # Tardis specific hack |
---|
36 | /usr/local/include |
---|
37 | /usr/include |
---|
38 | /sw/include |
---|
39 | /opt/local/include |
---|
40 | /opt/csw/include |
---|
41 | /opt/csw/include |
---|
42 | /opt/include |
---|
43 | ../libs/libvorbis-1.2.0/include |
---|
44 | ${DEPENDENCY_DIR}/libvorbis-1.2.0/include |
---|
45 | ) |
---|
46 | |
---|
47 | # |
---|
48 | # Libs |
---|
49 | # |
---|
50 | |
---|
51 | FIND_LIBRARY(OGG_LIBRARY |
---|
52 | NAMES ogg |
---|
53 | PATHS |
---|
54 | /usr/pack/oggvorbis-1.0-ds/i686-debian-linux3.1/lib |
---|
55 | /usr/local/lib |
---|
56 | /usr/lib |
---|
57 | /sw/lib |
---|
58 | /opt/local/lib |
---|
59 | /opt/csw/lib |
---|
60 | /opt/lib |
---|
61 | ../libs/libogg-1.1.3/src/.libs |
---|
62 | ${DEPENDENCY_DIR}/libogg-1.1.3/lib |
---|
63 | ) |
---|
64 | |
---|
65 | FIND_LIBRARY(VORBIS_LIBRARY |
---|
66 | NAMES vorbis |
---|
67 | PATHS |
---|
68 | /usr/pack/oggvorbis-1.0-ds/i686-debian-linux3.1/lib |
---|
69 | /usr/local/lib |
---|
70 | /usr/lib |
---|
71 | /sw/lib |
---|
72 | /opt/local/lib |
---|
73 | /opt/csw/lib |
---|
74 | /opt/lib |
---|
75 | ../libs/libvorbis-1.2.0/lib/.libs |
---|
76 | ${DEPENDENCY_DIR}/libvorbis-1.2.0/lib |
---|
77 | ) |
---|
78 | |
---|
79 | #FIND_LIBRARY(VORBISENC_LIBRARY |
---|
80 | # NAMES vorbisenc |
---|
81 | # PATHS |
---|
82 | # /usr/pack/oggvorbis-1.0-ds/i686-debian-linux3.1/lib |
---|
83 | # /usr/local/lib |
---|
84 | # /usr/lib |
---|
85 | # /sw/lib |
---|
86 | # /opt/local/lib |
---|
87 | # /opt/csw/lib |
---|
88 | # /opt/lib |
---|
89 | # ../libs/libvorbis-1.2.0/lib/.libs |
---|
90 | # ) |
---|
91 | |
---|
92 | FIND_LIBRARY(VORBISFILE_LIBRARY |
---|
93 | NAMES vorbisfile |
---|
94 | PATHS |
---|
95 | /usr/pack/oggvorbis-1.0-ds/i686-debian-linux3.1/lib |
---|
96 | /usr/local/lib |
---|
97 | /usr/lib |
---|
98 | /sw/lib |
---|
99 | /opt/local/lib |
---|
100 | /opt/csw/lib |
---|
101 | /opt/lib |
---|
102 | ../libs/libvorbis-1.2.0/lib/.libs |
---|
103 | ${DEPENDENCY_DIR}/libvorbis-1.2.0/lib |
---|
104 | ) |
---|
105 | |
---|
106 | SET (OGG_FOUND "NO") |
---|
107 | |
---|
108 | IF (OGG_INCLUDE_DIR AND OGG_LIBRARY) |
---|
109 | SET (OGG_FOUND "YES") |
---|
110 | IF (NOT OGG_FIND_QUIETLY) |
---|
111 | MESSAGE (STATUS "Ogg was found.") |
---|
112 | IF (VERBOSE_FIND) |
---|
113 | MESSAGE (STATUS " include path: ${OGG_INCLUDE_DIR}") |
---|
114 | MESSAGE (STATUS " library path: ${OGG_LIBRARY}") |
---|
115 | MESSAGE (STATUS " libraries: ogg") |
---|
116 | ENDIF (VERBOSE_FIND) |
---|
117 | ENDIF (NOT OGG_FIND_QUIETLY) |
---|
118 | ELSE (OGG_INCLUDE_DIR AND OGG_LIBRARY) |
---|
119 | IF (NOT OGG_INCLUDE_DIR) |
---|
120 | MESSAGE (SEND_ERROR "Ogg include path was not found.") |
---|
121 | ENDIF (NOT OGG_INCLUDE_DIR) |
---|
122 | IF (NOT OGG_LIBRARY) |
---|
123 | MESSAGE (SEND_ERROR "Ogg library was not found.") |
---|
124 | ENDIF (NOT OGG_LIBRARY) |
---|
125 | ENDIF (OGG_INCLUDE_DIR AND OGG_LIBRARY) |
---|
126 | |
---|
127 | |
---|
128 | SET (VORBIS_FOUND "NO") |
---|
129 | |
---|
130 | IF (VORBIS_INCLUDE_DIR AND VORBIS_LIBRARY AND VORBISFILE_LIBRARY)# AND VORBISENC_LIBRARY) |
---|
131 | SET (VORBIS_FOUND "YES") |
---|
132 | IF (NOT VORBIS_FIND_QUIETLY) |
---|
133 | MESSAGE (STATUS "Vorbis was found.") |
---|
134 | IF (VERBOSE_FIND) |
---|
135 | MESSAGE (STATUS " include path: ${VORBIS_INCLUDE_DIR}") |
---|
136 | MESSAGE (STATUS " library path: ${VORBIS_LIBRARY}") |
---|
137 | #MESSAGE (STATUS " library path: ${VORBISENC_LIBRARY}") |
---|
138 | MESSAGE (STATUS " library path: ${VORBISFILE_LIBRARY}") |
---|
139 | MESSAGE (STATUS " libraries: vorbis vorbisenc vorbisfile") |
---|
140 | ENDIF (VERBOSE_FIND) |
---|
141 | ENDIF (NOT VORBIS_FIND_QUIETLY) |
---|
142 | ELSE (VORBIS_INCLUDE_DIR AND VORBIS_LIBRARY AND VORBISFILE_LIBRARY)# AND VORBISENC_LIBRARY) |
---|
143 | IF (NOT VORBIS_INCLUDE_DIR) |
---|
144 | MESSAGE (SEND_ERROR "Vorbis include path was not found.") |
---|
145 | ENDIF (NOT VORBIS_INCLUDE_DIR) |
---|
146 | IF (NOT VORBIS_LIBRARY) |
---|
147 | MESSAGE (SEND_ERROR "Vorbis library \"vorbis\" was not found.") |
---|
148 | ENDIF (NOT VORBIS_LIBRARY) |
---|
149 | #IF (NOT VORBISENC_LIBRARY) |
---|
150 | # MESSAGE (SEND_ERROR "Vorbis library \"vorbisenc\" was not found.") |
---|
151 | #ENDIF (NOT VORBISENC_LIBRARY) |
---|
152 | IF (NOT VORBISFILE_LIBRARY) |
---|
153 | MESSAGE (SEND_ERROR "Vorbis library \"vorbisfile\" was not found.") |
---|
154 | ENDIF (NOT VORBISFILE_LIBRARY) |
---|
155 | ENDIF (VORBIS_INCLUDE_DIR AND VORBIS_LIBRARY AND VORBISFILE_LIBRARY)# AND VORBISENC_LIBRARY) |
---|
156 | |
---|