Mercurial > mplayer.hg
annotate configure @ 554:d8b3c80604e3
dvd sub parser move dto mplayer.c
author | arpi_esp |
---|---|
date | Fri, 20 Apr 2001 23:00:11 +0000 |
parents | c5c2d4e41a4a |
children | 30d9f61e9c0b |
rev | line source |
---|---|
1 | 1 #!/bin/sh |
2 | |
3 # | |
4 # MPlayer configurator. (C) 2000 Pontscho/fresh!mindworkz | |
5 # pontscho@makacs.poliod.hu | |
6 # | |
4 | 7 # Changes in reversed order: |
1 | 8 # |
492 | 9 # 2001/04/16 by LGB |
10 # - added libcss stuffs | |
11 # | |
463 | 12 # 2001/04/15 by Pontscho |
13 # - added --disable-select option | |
14 # - added X11DIR variable in config.mak and fix syncfb Makefile -L/usr/X11/lib bug | |
15 # | |
209
26d2d4d3331a
Addes autodetection of XF86VidMode to configure, and adds a description of
mgraffam
parents:
196
diff
changeset
|
16 # 2001/03/24 by Mike Graffam: |
26d2d4d3331a
Addes autodetection of XF86VidMode to configure, and adds a description of
mgraffam
parents:
196
diff
changeset
|
17 # - added autodetect code for XF86VidMode, along with explicit --enable-vm |
26d2d4d3331a
Addes autodetection of XF86VidMode to configure, and adds a description of
mgraffam
parents:
196
diff
changeset
|
18 # |
196 | 19 # 2001/03/22 by Bivanbi: |
20 # - new option: --cc (to specify C compiler path+name) | |
21 # | |
22 # 2001/03/08 by LGB: | |
492 | 23 # - DGA detect-o-matic :) |
59 | 24 # - '--disable-dga' option to force disabling DGA vo driver compiling into mplayer |
25 # - line about '--enable-dga' is added to the help message | |
26 # | |
196 | 27 # 2001/02/26 by A'rpi: |
11 | 28 # - added DGA option: --enable-dga |
29 # - no notify if --with-win32libdir used [Tibcu] | |
30 # | |
196 | 31 # 2001/02/25 by LGB: |
4 | 32 # - TMPDIR or TEMPDIR variable is honored during tests for temporary files |
33 # - ChangeLog inside configure was reversed ;-) | |
1 | 34 # |
35 # some changes by A'rpi/ESP-team: | |
4 | 36 # - added 'athlon' target for the new athlongcc [Ian Kumlien] |
37 # - applied _win32libdir=-L patch by Magnus Pfeffer | |
1 | 38 # |
39 # some changes by LGB: | |
40 # - Ehhh, AMD K6-2 returns with cpuid 5 ;-) Changing back Arpi's last change :) | |
41 # More info: AMD K6-2 reports with family 5, duron with 6, so I attached | |
42 # much finer CPU type detection based on Linux kernel's one :) | |
43 # (k5: 5, model<6, k6: 5, model>=6, k7: 6, model=any) | |
44 # - On some exit point (error) temporary files were not deleted. Fixed. | |
45 # - $TMP and $TMP2 are renamed to $TMPC and $TMPO ;-) | |
46 # - Some useless { ... } are removed | |
47 # | |
48 # some changes by A'rpi/ESP-team: | |
11 | 49 # - the --with-win32libdir patch by Aaron Hope applied |
4 | 50 # - some english bugfix again :) |
51 # - cpu type selection changed: | |
52 # ( k7->k6->k5-> ) || (i686->pentiumpro-> ) pentium-> i486 -> i386 -> error! | |
53 # - cpu type for AMD/family=5 changed k6->k5 | |
54 # | |
55 # some changes by LGB (Gábor Lénárt): | |
56 # - SOME gcc may support 'k7', so I added tests for ALL CPU type optimization | |
57 # switches with the ability to find out the best optimization for your CPU. | |
58 # - Help moved to the begining to avoid tests if user only wants help. | |
59 # - A one lined help to indicate detailed help for users | |
60 # - Fixed /tmp race (PIDs can be predicted, I added random numbers as well) | |
61 # | |
62 # some changes by A'rpi/ESP-team: | |
63 # - some english bugfix :) | |
64 # - removed _??exists flags, _?? is enough... | |
65 # - creating only config.mak files instead of whole Makefiles | |
1 | 66 # |
67 # -- | |
68 | |
69 | |
70 # LGB: Help moved here. | |
71 | |
72 if [ "$1" = "--help" -o "$1" = "-help" -o "$1" = "-h" ]; then | |
73 cat << EOF | |
74 | |
75 usage: $0 [options] | |
76 | |
77 params: | |
196 | 78 --cc use this C compiler to build MPlayer [gcc] |
1 | 79 --enable-mmx build with mmx support [autodetect] |
350 | 80 --enable-mmx2 build with mmx2 support (PIII, Athlon) [autodetect] |
1 | 81 --enable-3dnow build with 3dnow! support [autodetect] |
82 --enable-sse build with sse support [autodetect] | |
83 --enable-gl build with OpenGL render support [autodetect] | |
59 | 84 --enable-dga build with DGA support [autodetect] |
287 | 85 --enable-svga build with SVGAlib support [autodetect] |
548
c5c2d4e41a4a
added sdl versiondetect and removed sdl warning (it's autodetect now)
atmosfear
parents:
525
diff
changeset
|
86 --enable-sdl build with SDL render support [autodetect] |
1 | 87 --enable-mga build with mga_vid support [autodetect, if /dev/mga_vid |
88 is available] | |
89 --enable-xmga build with mga_vid X Window support [autodetect, | |
90 if both /dev/mga_vid and x11 are available] | |
91 --enable-xv build with Xv render support for X 4.x [autodetect] | |
209
26d2d4d3331a
Addes autodetection of XF86VidMode to configure, and adds a description of
mgraffam
parents:
196
diff
changeset
|
92 --enable-vm build with XF86VidMode support for x11 driver |
1 | 93 --enable-x11 build with X11 render support [autodetect] |
225 | 94 --enable-fbdev build with FBDev render support [_not_ autodetected] |
1 | 95 --enable-mlib build with MLIB support ( only Solaris ) |
96 | |
97 --enable-termcap use termcap database for key codes | |
98 --enable-xmmp use XMMP audio drivers | |
448
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
99 --enable-lirc enable LIRC (remote control) support |
1 | 100 |
463 | 101 --disable-select disable audio select() support ( for example required this |
102 option ALSA or Vortex2 driver ) | |
103 | |
1 | 104 --with-x11libdir=DIR X library files are in DIR |
105 --with-win32libdir=DIR windows codec files | |
492 | 106 --with-csslibdir=DIR directory contains libcss.so shared library |
107 --with-cssincdir=DIR directory contains libcss header file (css.h) | |
1 | 108 |
109 --size-x=SIZE default screen width | |
110 --size-y=SIZE default screen height | |
111 EOF | |
112 exit 0 | |
113 fi | |
114 | |
115 # LGB: Some inital help | |
116 | |
117 echo "You can get detailed help on configure with: $0 --help" | |
118 echo "Please wait while ./configure discovers your software and hardware environment!" | |
119 | |
120 # LGB: temporary files | |
121 | |
4 | 122 TMPC="mplayer-conf-${RANDOM}-$$-${RANDOM}.c" |
123 TMPO="mplayer-conf-${RANDOM}-$$-${RANDOM}.o" | |
1 | 124 |
4 | 125 if [ ! -z $TMPDIR ]; then |
126 TMPC="${TMPDIR}/${TMPC}" | |
127 TMPO="${TMPDIR}/${TMPO}" | |
128 elif [ ! -z $TEMPDIR ]; then | |
129 TMPC="${TEMPDIR}/${TMPC}" | |
130 TMPO="${TEMPDIR}/${TMPO}" | |
131 else | |
132 TMPC="/tmp/${TMPC}" | |
133 TMPO="/tmp/${TMPO}" | |
134 fi | |
1 | 135 |
136 # --- | |
137 | |
138 # config files | |
139 CCONF='config.h' | |
140 MCONF='config.mak' | |
141 | |
196 | 142 # --- Check for C compiler: |
143 | |
144 _cc=gcc | |
448
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
145 _x11=auto |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
146 |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
147 _x11libdir= |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
148 if [ -e /usr/X11R6 ]; then |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
149 _x11libdir=-L/usr/X11R6/lib |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
150 else |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
151 if [ -e /usr/X11 ]; then |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
152 _x11libdir=-L/usr/X11/lib |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
153 fi |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
154 fi |
196 | 155 |
156 for ac_option | |
157 do | |
158 case "$ac_option" in | |
159 --cc=*) | |
160 _cc=`echo $ac_option | cut -d '=' -f 2` | |
161 ;; | |
448
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
162 --with-x11libdir=*) |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
163 _x11libdir=-L`echo $ac_option | cut -d '=' -f 2` |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
164 ;; |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
165 --enable-x11) |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
166 _x11=yes |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
167 ;; |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
168 --disable-x11) |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
169 _x11=no |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
170 ;; |
196 | 171 esac |
172 done | |
173 | |
1 | 174 # --- |
175 | |
176 TAB=`echo -n -e "\t"` | |
177 pname=`cat /proc/cpuinfo | grep 'model name' | cut -d ':' -f 2` | |
178 pparam=`cat /proc/cpuinfo | grep 'features' | cut -d ':' -f 2` | |
179 if [ -z "$pparam" ]; then | |
180 pparam=`cat /proc/cpuinfo | grep 'flags' | cut -d ':' -f 2` | |
181 fi | |
182 pvendor=`cat /proc/cpuinfo | grep 'vendor_id' | cut -d ':' -f 2 | cut -d ' ' -f 2` | |
183 pfamily=`cat /proc/cpuinfo | grep 'cpu family' | cut -d ':' -f 2 | cut -d ' ' -f 2` | |
184 pmodel=`cat /proc/cpuinfo | grep "model$TAB" | cut -d ':' -f 2 | cut -d ' ' -f 2` | |
185 pstepping=`cat /proc/cpuinfo | grep 'stepping' | cut -d ':' -f 2 | cut -d ' ' -f 2` | |
186 | |
187 _mmx=no | |
350 | 188 _mmx2=no |
1 | 189 _3dnow=no |
190 _mtrr=no | |
191 _sse=no | |
525 | 192 |
1 | 193 _mga=no |
194 _gl=no | |
195 _sdl=no | |
196 _xv=no | |
209
26d2d4d3331a
Addes autodetection of XF86VidMode to configure, and adds a description of
mgraffam
parents:
196
diff
changeset
|
197 _vm=no |
525 | 198 _xdpms=no |
1 | 199 _3dfx=no |
200 _syncfb=no | |
201 _mlib=no | |
202 _mpg123=no | |
203 _xmga=no | |
11 | 204 _dga=no |
233
f62ccacbe1e5
Changes to configure to autodetect DGA 2.0 functionality, and to only use
mgraffam
parents:
225
diff
changeset
|
205 _dga2=no |
287 | 206 _svga=no |
448
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
207 _fbdev=yes |
1 | 208 _lirc=no |
525 | 209 _css=no |
1 | 210 |
211 _x=1 | |
212 _y=1 | |
213 | |
214 _gllib= | |
215 _sdllib= | |
448
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
216 _xvlib= |
440
d19a3da6ac13
Pontscho's mixer, select, and hell-a-lot-of-stuff patch ;)
gabucino
parents:
417
diff
changeset
|
217 _x11lib= |
1 | 218 |
463 | 219 _select='#define HAVE_AUDIO_SELECT' |
220 | |
1 | 221 for i in `echo $pparam`; do |
222 | |
223 case "$i" in | |
224 3dnow) | |
225 _3dnow=yes | |
226 _mpg123=yes | |
227 ;; | |
228 mmx) | |
229 _mmx=yes | |
230 ;; | |
350 | 231 mmxext) |
232 _mmx2=yes | |
233 ;; | |
1 | 234 mtrr) |
235 _mtrr=yes | |
236 ;; | |
237 k6_mtrr) | |
238 _mtrr=yes | |
239 ;; | |
240 xmm) | |
241 _sse=yes | |
356 | 242 _mmx2=yes |
1 | 243 ;; |
244 sse) | |
245 _sse=yes | |
356 | 246 _mmx2=yes |
1 | 247 ;; |
248 kni) | |
249 _sse=yes | |
356 | 250 _mmx2=yes |
1 | 251 ;; |
252 esac | |
253 | |
254 done | |
255 | |
256 | |
257 _win32libdirnotify=no | |
258 if [ -e /usr/lib/win32 ]; then | |
259 _win32libdir=/usr/lib/win32 | |
260 else | |
261 if [ -e /usr/local/lib/win32 ]; then | |
262 _win32libdir=/usr/local/lib/win32 | |
263 else | |
264 # This is our default: | |
265 _win32libdir=/usr/lib/win32 | |
266 _win32libdirnotify=yes | |
267 fi | |
268 fi | |
269 | |
270 | |
271 if [ -e /dev/mga_vid ]; then | |
272 _mga=yes | |
273 _syncfb=yes | |
274 fi | |
275 | |
276 proc=pentium | |
277 | |
278 case "$pvendor" in | |
279 AuthenticAMD) | |
280 case "$pfamily" in | |
281 3) | |
282 proc=i386 | |
283 ;; | |
284 4) | |
285 proc=i486 | |
286 ;; | |
287 5) | |
288 if [ $pmodel -ge 6 ]; then # LGB: models are: K5/SSA5 K5 K5 K5 ? ? K6 K6 K6-2 K6-3 | |
289 proc=k6 | |
290 else | |
291 proc=k5 | |
292 fi | |
293 ;; | |
294 6|7) # LGB: Though it seems Athlon CPUs returns with "6" | |
295 proc=k7 | |
296 ;; | |
297 *) | |
298 proc=pentium | |
299 ;; | |
300 esac | |
301 ;; | |
302 GenuineIntel) | |
303 case "$pfamily" in | |
304 3) | |
305 proc=i386 | |
306 ;; | |
307 4) | |
308 proc=i486 | |
309 ;; | |
310 5) | |
311 proc=pentium | |
312 ;; | |
313 6) | |
314 proc=i686 | |
315 ;; | |
316 *) | |
317 proc=pentium | |
318 ;; | |
319 esac | |
320 ;; | |
321 unknown) # added by Gabucino - upon Tibcu's request | |
322 case "$pfamily" in | |
323 3) | |
324 proc=i386 | |
325 ;; | |
326 4) | |
327 proc=i486 | |
328 ;; | |
329 *) | |
330 proc=pentium | |
331 ;; | |
332 esac | |
333 ;; | |
334 *) | |
335 proc=pentium | |
336 ;; | |
337 esac | |
338 | |
339 # --- | |
340 | |
341 cat > $TMPC << EOF | |
342 int main( void ) { return 0; } | |
343 EOF | |
344 | |
345 # check that gcc supports our cpu, if not, fallback to pentium | |
346 # LGB: check -mcpu and -march swithing step by step with enabling | |
347 # to fall back till 386. | |
348 | |
349 #echo -n "Checking your GCC CPU optimalization abilities: " | |
350 if [ "$proc" = "k7" ]; then | |
351 # echo -n "trying k7 " | |
196 | 352 $_cc $TMPC -o $TMPO -march=$proc -mcpu=$proc &> /dev/null || proc=athlon |
1 | 353 fi |
354 if [ "$proc" = "athlon" ]; then | |
355 # echo -n "trying athlon " | |
196 | 356 $_cc $TMPC -o $TMPO -march=$proc -mcpu=$proc &> /dev/null || proc=k6 |
1 | 357 fi |
358 if [ "$proc" = "k6" ]; then | |
359 # echo -n "trying k6 " | |
196 | 360 $_cc $TMPC -o $TMPO -march=$proc -mcpu=$proc &> /dev/null || proc=k5 |
1 | 361 fi |
362 if [ "$proc" = "k5" ]; then | |
363 # echo -n "trying k5 " | |
196 | 364 $_cc $TMPC -o $TMPO -march=$proc -mcpu=$proc &> /dev/null || proc=pentium |
1 | 365 fi |
366 if [ "$proc" = "i686" ]; then | |
367 # echo -n "trying i686 " | |
196 | 368 $_cc $TMPC -o $TMPO -march=$proc -mcpu=$proc &> /dev/null || proc=pentiumpro |
1 | 369 fi |
370 if [ "$proc" = "pentiumpro" ]; then | |
371 # echo -n "trying pentiumpro " | |
196 | 372 $_cc $TMPC -o $TMPO -march=$proc -mcpu=$proc &> /dev/null || proc=pentium |
1 | 373 fi |
374 if [ "$proc" = "pentium" ]; then | |
375 # echo -n "trying pentium " | |
196 | 376 $_cc $TMPC -o $TMPO -march=$proc -mcpu=$proc &> /dev/null || proc=i486 |
1 | 377 fi |
378 if [ "$proc" = "i486" ]; then | |
379 # echo -n "trying i486 " | |
196 | 380 $_cc $TMPC -o $TMPO -march=$proc -mcpu=$proc &> /dev/null || proc=i386 |
1 | 381 fi |
382 if [ "$proc" = "i386" ]; then | |
383 # echo -n "trying i386 " | |
196 | 384 $_cc $TMPC -o $TMPO -march=$proc -mcpu=$proc &> /dev/null || proc=error |
1 | 385 fi |
386 if [ "$proc" = "error" ]; then | |
387 echo | |
388 echo "Your gcc does not support even \"i386\" for '-march' and '-mcpu'." >&2 | |
389 rm -f $TMPC $TMPO | |
390 exit | |
391 fi | |
392 #echo "DONE (${proc})." | |
393 | |
394 | |
448
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
395 $_cc $TMPC -o $TMPO -lvgagl -lvga &> /dev/null && _svga=yes |
1 | 396 |
448
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
397 $_cc $TMPC -o $TMPO -lpthread &> /dev/null || \ |
1 | 398 { echo "Lib pthread not found."; rm -f $TMPC $TMPO ; exit 1; } |
399 | |
548
c5c2d4e41a4a
added sdl versiondetect and removed sdl warning (it's autodetect now)
atmosfear
parents:
525
diff
changeset
|
400 # Atmosfear: added SDL versioncheck and autodetect; removed warnings. |
c5c2d4e41a4a
added sdl versiondetect and removed sdl warning (it's autodetect now)
atmosfear
parents:
525
diff
changeset
|
401 _sdl=no |
c5c2d4e41a4a
added sdl versiondetect and removed sdl warning (it's autodetect now)
atmosfear
parents:
525
diff
changeset
|
402 if test `sdl-config --version | sed s/[=[:punct:]=]//g` -gt 116 ; then |
c5c2d4e41a4a
added sdl versiondetect and removed sdl warning (it's autodetect now)
atmosfear
parents:
525
diff
changeset
|
403 $_cc $TMPC -o $TMPO -L/usr/lib/ -L/usr/local/lib/ -lSDL -lpthread &> /dev/null && _sdl=yes |
c5c2d4e41a4a
added sdl versiondetect and removed sdl warning (it's autodetect now)
atmosfear
parents:
525
diff
changeset
|
404 else |
c5c2d4e41a4a
added sdl versiondetect and removed sdl warning (it's autodetect now)
atmosfear
parents:
525
diff
changeset
|
405 _sdl=outdated |
c5c2d4e41a4a
added sdl versiondetect and removed sdl warning (it's autodetect now)
atmosfear
parents:
525
diff
changeset
|
406 fi |
1 | 407 |
408 _termcap=no | |
196 | 409 $_cc $TMPC -o $TMPO -ltermcap &> /dev/null && _termcap=yes |
1 | 410 |
525 | 411 _png=no |
412 $_cc $TMPC -o $TMPO -lpng &> /dev/null && _png=yes | |
413 | |
1 | 414 _binutils=no |
415 as libac3/downmix/downmix_i386.S -o $TMPO &> /dev/null && _binutils=yes | |
416 | |
448
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
417 # ----------- Check X11 and related libs (GL, Xxf86vm, Xv, DGA) -------------- |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
418 |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
419 if [ $_x11 = auto ]; then |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
420 _x11=no |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
421 $_cc $TMPC -o $TMPO $_x11libdir -lX11 -lXext &> /dev/null && _x11=yes |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
422 fi |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
423 |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
424 if [ $_x11 = yes ]; then |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
425 |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
426 $_cc $TMPC -o $TMPO $_x11libdir -lX11 -lXext -lXdpms &> /dev/null && _xdpms=yes |
525 | 427 $_cc $TMPC -o $TMPO $_x11libdir -lX11 -lXext -lXv &> /dev/null && _xv=yes |
448
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
428 |
525 | 429 $_cc $TMPC -o $TMPO $_x11libdir -lX11 -lXext -lGL &> /dev/null && _gl=yes |
448
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
430 |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
431 cat > $TMPC << EOF |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
432 #include <GL/gl.h> |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
433 int main( void ) { return 0; } |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
434 EOF |
525 | 435 $_cc $TMPC -o $TMPO $_x11libdir -lX11 -lXext -lGL &> /dev/null || \ |
448
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
436 { _gl=no; echo "GL includes not found!";} |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
437 |
525 | 438 $_cc $TMPC -o $TMPO $_x11libdir -lX11 -lXext -lXxf86vm &> /dev/null && _vm=yes |
59 | 439 |
440 cat > $TMPC << EOF | |
441 #include <stdio.h> | |
442 #include <X11/Xlib.h> | |
443 #include <X11/extensions/xf86dga.h> | |
444 int main (void) { return 0;} | |
445 EOF | |
446 | |
196 | 447 $_cc $TMPC -o $TMPO -L/usr/X11R6/lib -L/usr/X11/lib -lX11 -lXext -lXxf86dga -lXxf86vm &> /dev/null && _dga=yes |
59 | 448 # Note: the -lXxf86vm library is the VideoMode extension and though it's |
449 # not needed for DGA, AFAIK every distribution packages together with DGA | |
450 # stuffs named 'X extensions' or something similar. This check can be usefull | |
451 # for further mplayer versions to set resolution by mplayer itself. | |
452 # If you run into problems, remove '-lXxf86vm'. | |
453 | |
233
f62ccacbe1e5
Changes to configure to autodetect DGA 2.0 functionality, and to only use
mgraffam
parents:
225
diff
changeset
|
454 # Check if DGA is 2.0 or greater |
f62ccacbe1e5
Changes to configure to autodetect DGA 2.0 functionality, and to only use
mgraffam
parents:
225
diff
changeset
|
455 cat > $TMPC << EOF |
f62ccacbe1e5
Changes to configure to autodetect DGA 2.0 functionality, and to only use
mgraffam
parents:
225
diff
changeset
|
456 #include <stdio.h> |
f62ccacbe1e5
Changes to configure to autodetect DGA 2.0 functionality, and to only use
mgraffam
parents:
225
diff
changeset
|
457 #include <X11/Xlib.h> |
f62ccacbe1e5
Changes to configure to autodetect DGA 2.0 functionality, and to only use
mgraffam
parents:
225
diff
changeset
|
458 #include <X11/extensions/xf86dga.h> |
f62ccacbe1e5
Changes to configure to autodetect DGA 2.0 functionality, and to only use
mgraffam
parents:
225
diff
changeset
|
459 int main (void) { XDGAMode mode; XDGADevice device; return 0;} |
f62ccacbe1e5
Changes to configure to autodetect DGA 2.0 functionality, and to only use
mgraffam
parents:
225
diff
changeset
|
460 EOF |
f62ccacbe1e5
Changes to configure to autodetect DGA 2.0 functionality, and to only use
mgraffam
parents:
225
diff
changeset
|
461 |
f62ccacbe1e5
Changes to configure to autodetect DGA 2.0 functionality, and to only use
mgraffam
parents:
225
diff
changeset
|
462 _dga2=no |
f62ccacbe1e5
Changes to configure to autodetect DGA 2.0 functionality, and to only use
mgraffam
parents:
225
diff
changeset
|
463 $_cc $TMPC -o $TMPO -L/usr/X11R6/lib -L/usr/X11/lib -lX11 -lXext -lXxf86dga -lXxf86vm &> /dev/null && _dga2=yes |
f62ccacbe1e5
Changes to configure to autodetect DGA 2.0 functionality, and to only use
mgraffam
parents:
225
diff
changeset
|
464 |
448
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
465 fi |
1 | 466 |
467 rm -f $TMPC $TMPO | |
468 | |
469 # --- | |
470 | |
471 # check for the parameters. | |
472 | |
473 for ac_option | |
474 do | |
475 case "$ac_option" in | |
492 | 476 --enable-css) |
477 _css=yes | |
478 ;; | |
525 | 479 --enable-png) |
480 _png=yes | |
481 ;; | |
1 | 482 --enable-sse) |
483 _sse=yes | |
484 ;; | |
485 --enable-3dnow) | |
486 _3dnow=yes | |
487 ;; | |
488 --enable-mmx) | |
489 _mmx=yes | |
490 ;; | |
350 | 491 --enable-mmx2) |
492 _mmx2=yes | |
493 ;; | |
72 | 494 --enable-mtrr) |
495 _mtrr=yes | |
496 ;; | |
1 | 497 --enable-gl) |
498 _gl=yes | |
499 ;; | |
500 --enable-sdl) | |
501 _sdl=yes | |
502 ;; | |
503 --enable-mga) | |
504 _mga=yes | |
505 ;; | |
506 --enable-xmga) | |
507 _xmga=yes | |
508 ;; | |
287 | 509 --enable-svga) |
510 _svga=yes | |
511 ;; | |
11 | 512 --enable-dga) |
513 _dga=yes | |
233
f62ccacbe1e5
Changes to configure to autodetect DGA 2.0 functionality, and to only use
mgraffam
parents:
225
diff
changeset
|
514 ;; |
f62ccacbe1e5
Changes to configure to autodetect DGA 2.0 functionality, and to only use
mgraffam
parents:
225
diff
changeset
|
515 --enable-dga2) |
f62ccacbe1e5
Changes to configure to autodetect DGA 2.0 functionality, and to only use
mgraffam
parents:
225
diff
changeset
|
516 _dga2=yes |
f62ccacbe1e5
Changes to configure to autodetect DGA 2.0 functionality, and to only use
mgraffam
parents:
225
diff
changeset
|
517 ;; |
1 | 518 --enable-xv) |
519 _xv=yes | |
520 ;; | |
209
26d2d4d3331a
Addes autodetection of XF86VidMode to configure, and adds a description of
mgraffam
parents:
196
diff
changeset
|
521 --enable-vm) |
26d2d4d3331a
Addes autodetection of XF86VidMode to configure, and adds a description of
mgraffam
parents:
196
diff
changeset
|
522 _vm=yes |
26d2d4d3331a
Addes autodetection of XF86VidMode to configure, and adds a description of
mgraffam
parents:
196
diff
changeset
|
523 ;; |
1 | 524 --enable-3dfx) |
525 _3dfx=yes | |
526 ;; | |
527 --enable-syncfb) | |
528 _syncfb=yes | |
529 ;; | |
225 | 530 --enable-fbdev) |
531 _fbdev=yes | |
532 ;; | |
1 | 533 --enable-mlib) |
534 _mlib=yes | |
535 ;; | |
536 --enable-termcap) | |
537 _termcap=yes | |
538 ;; | |
539 --enable-xmmp) | |
540 _xmmp=yes | |
541 ;; | |
542 --enable-lirc) | |
543 _lirc=yes | |
544 ;; | |
463 | 545 --enable-select) |
546 _select='#define HAVE_AUDIO_SELECT' | |
547 ;; | |
492 | 548 --disable-css) |
549 _css=no | |
550 ;; | |
525 | 551 --disable-png) |
552 _png=no | |
553 ;; | |
1 | 554 --disable-sse) |
555 _sse=no | |
556 ;; | |
557 --disable-3dnow) | |
558 _3dnow=no | |
559 ;; | |
560 --disable-mmx) | |
561 _mmx=no | |
350 | 562 _mmx2=no |
1 | 563 ;; |
72 | 564 --disable-mtrr) |
565 _mtrr=no | |
566 ;; | |
1 | 567 --disable-gl) |
568 _gl=no | |
569 ;; | |
570 --disable-sdl) | |
571 _sdl=no | |
572 ;; | |
573 --disable-mga) | |
574 _mga=no | |
575 ;; | |
576 --disable-xmga) | |
577 _xmga=no | |
578 ;; | |
579 --disable-xv) | |
580 _xv=no | |
581 ;; | |
209
26d2d4d3331a
Addes autodetection of XF86VidMode to configure, and adds a description of
mgraffam
parents:
196
diff
changeset
|
582 --disable-vm) |
26d2d4d3331a
Addes autodetection of XF86VidMode to configure, and adds a description of
mgraffam
parents:
196
diff
changeset
|
583 _vm=no |
26d2d4d3331a
Addes autodetection of XF86VidMode to configure, and adds a description of
mgraffam
parents:
196
diff
changeset
|
584 ;; |
1 | 585 --disable-mlib) |
586 _mlib=no | |
587 ;; | |
287 | 588 --disable-svga) |
589 _svga=no | |
590 ;; | |
59 | 591 --disable-dga) |
592 _dga=no | |
593 ;; | |
233
f62ccacbe1e5
Changes to configure to autodetect DGA 2.0 functionality, and to only use
mgraffam
parents:
225
diff
changeset
|
594 --disable-dga2) |
f62ccacbe1e5
Changes to configure to autodetect DGA 2.0 functionality, and to only use
mgraffam
parents:
225
diff
changeset
|
595 _dga2=no |
f62ccacbe1e5
Changes to configure to autodetect DGA 2.0 functionality, and to only use
mgraffam
parents:
225
diff
changeset
|
596 ;; |
225 | 597 --disable-fbdev) |
598 _fbdev=no | |
599 ;; | |
1 | 600 --disable-termcap) |
601 _termcap=no | |
602 ;; | |
463 | 603 --disable-select) |
604 _select='#undef HAVE_AUDIO_SELECT' | |
605 ;; | |
1 | 606 --with-win32libdir=*) |
607 _win32libdir=`echo $ac_option | cut -d '=' -f 2` | |
11 | 608 _win32libdirnotify=no |
1 | 609 ;; |
492 | 610 --with-csslibdir=*) |
611 _csslibdir=`echo $ac_option | cut -d '=' -f 2` | |
612 _css='yes'; | |
613 ;; | |
614 --with-cssincdir=*) | |
615 _cssincdir=`echo $ac_option | cut -d '=' -f 2` | |
616 _css='yes'; | |
617 ;; | |
1 | 618 --size-x=*) |
619 _x=`echo $ac_option | cut -d '=' -f 2` | |
620 ;; | |
621 --size-y=*) | |
622 _y=`echo $ac_option | cut -d '=' -f 2` | |
623 ;; | |
448
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
624 --with-x11libdir=*) |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
625 ;; |
196 | 626 --cc=*) |
627 ;; | |
1 | 628 esac |
629 done | |
630 | |
448
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
631 if [ $_x11 = 'yes' ]; then |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
632 if [ $_mga = 'yes' ]; then |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
633 _xmga=yes |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
634 fi |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
635 fi |
198b46b739d8
qrva eletbe nem kene cvs-t elbaszni inkabb ne nyuljatok hozza baz+
arpi_esp
parents:
440
diff
changeset
|
636 |
1 | 637 # to screen. |
196 | 638 echo "Using C compiler: $_cc" |
1 | 639 echo "Checking for cpu vendor ... $pvendor ( $pfamily:$pmodel:$pstepping )" |
640 echo "Checking for cpu type ... $pname" | |
641 echo "Optimizing to ... $proc" | |
642 echo "Checking for mmx support ... $_mmx" | |
350 | 643 echo "Checking for mmx2 support ... $_mmx2" |
1 | 644 echo "Checking for 3dnow support ... $_3dnow" |
645 echo "Checking for sse support ... $_sse" | |
646 echo "Checking for mtrr support ... $_mtrr" | |
647 echo "Screen size ... ${_x}x${_y}" | |
648 echo "Checking for X11 libs ... $_x11libdir" | |
649 echo "Checking mga_vid device ... $_mga" | |
650 echo "Checking for xmga ... $_xmga" | |
651 echo "Checking for SDL ... $_sdl" | |
652 echo "Checking for OpenGL ... $_gl" | |
653 echo "Checking for Xv ... $_xv" | |
654 echo "Checking for X11 ... $_x11" | |
59 | 655 echo "Checking for DGA ... $_dga" |
233
f62ccacbe1e5
Changes to configure to autodetect DGA 2.0 functionality, and to only use
mgraffam
parents:
225
diff
changeset
|
656 echo "Checking for DGA 2.0 .. $_dga2" |
209
26d2d4d3331a
Addes autodetection of XF86VidMode to configure, and adds a description of
mgraffam
parents:
196
diff
changeset
|
657 echo "Checking for Xf86VM ... $_vm" |
287 | 658 echo "Checking for SVGAlib ... $_svga" |
225 | 659 echo "Checking for FBDev ... $_fbdev" |
492 | 660 echo "Checking for DeCSS support ... $_css" |
525 | 661 echo "Checking for PNG support ... $_png" |
1 | 662 # write conf files. |
663 | |
664 if [ $_gl = yes ]; then | |
665 _gllib='-lGL' | |
666 fi | |
667 | |
492 | 668 if [ $_css = yes ]; then |
669 if [ ! -z $_csslibdir ]; then | |
670 _csslib="-L${_csslibdir} -lcss" | |
671 else | |
672 _csslib='-lcss' | |
673 fi | |
674 _css='#define HAVE_LIBCSS' | |
675 if [ ! -z $_cssincdir ]; then | |
676 _cssinc="-I${_cssincdir}" | |
677 else | |
678 _cssinc="" | |
679 fi | |
680 else | |
681 _css='#undef HAVE_LIBCSS' | |
682 _csslib='' | |
683 _cssinc='' | |
684 fi | |
685 | |
1 | 686 if [ $_x11 = yes ]; then |
330 | 687 if [ $_xdpms = yes ]; then |
688 _x11lib='-lX11 -lXext -lXdpms' | |
689 else | |
690 _x11lib='-lX11 -lXext' | |
691 fi | |
1 | 692 fi |
693 | |
694 if [ $_xv = yes ]; then | |
695 _xvlib='-lXv' | |
696 fi | |
697 | |
698 if [ $_sdl = yes ]; then | |
699 _sdllib='-lSDL -lpthread' | |
700 fi | |
701 | |
14 | 702 if [ $_dga = yes ]; then |
703 _dgalib='-lXxf86dga' | |
704 fi | |
705 | |
287 | 706 if [ $_svga = yes ]; then |
289 | 707 _svgalib='-lvgagl -lvga' |
287 | 708 fi |
709 | |
209
26d2d4d3331a
Addes autodetection of XF86VidMode to configure, and adds a description of
mgraffam
parents:
196
diff
changeset
|
710 if [ $_vm = yes ]; then |
26d2d4d3331a
Addes autodetection of XF86VidMode to configure, and adds a description of
mgraffam
parents:
196
diff
changeset
|
711 _vmlib='-lXxf86vm' |
26d2d4d3331a
Addes autodetection of XF86VidMode to configure, and adds a description of
mgraffam
parents:
196
diff
changeset
|
712 fi |
14 | 713 |
1 | 714 if [ "$_termcap" = "yes" ]; then |
715 _termcap='#define USE_TERMCAP' | |
716 _libtermcap='-ltermcap' | |
717 else | |
718 _termcap='#undef USE_TERMCAP' | |
719 _libtermcap='' | |
720 fi | |
721 | |
722 if [ "$_xmmp" = "yes" ]; then | |
723 _xmmpaudio='#define USE_XMMP_AUDIO' | |
724 _xmmplibs='-Llibxmm -lxmm' | |
725 else | |
726 _xmmpaudio='#undef USE_XMMP_AUDIO' | |
727 fi | |
728 | |
729 if [ "$_lirc" = "yes" ]; then | |
730 _lircdefs='#define HAVE_LIRC' | |
731 _lirclibs='-llirc_client' | |
732 else | |
733 _lircdefs='#undef HAVE_LIRC' | |
734 _lirclibs='' | |
735 fi | |
736 | |
525 | 737 if [ $_png = yes ]; then |
738 _libpng='-lpng' | |
739 fi | |
1 | 740 |
741 echo | |
742 echo "Creating $MCONF" | |
743 cat > $MCONF << EOF | |
744 | |
745 # -------- Generated by ./configure ----------- | |
746 | |
747 AR=ar | |
196 | 748 CC=$_cc |
518 | 749 X11DIR=$_x11libdir |
1 | 750 # OPTFLAGS=-O4 -march=$proc -mcpu=$proc -pipe -fomit-frame-pointer -ffast-math |
751 OPTFLAGS=-O4 -march=$proc -mcpu=$proc -pipe -ffast-math | |
14 | 752 # LIBS=-L/usr/lib -L/usr/local/lib $_x11libdir $_gllib $_sdllib $_dgalib $_x11lib $_xvlib |
525 | 753 X_LIBS=$_x11libdir $_gllib $_sdllib $_dgalib $_x11lib $_xvlib $_vmlib $_svgalib $_libpng |
1 | 754 TERMCAP_LIB=$_libtermcap |
755 XMM_LIBS = $_xmmplibs | |
756 LIRC_LIBS = $_lirclibs | |
492 | 757 CSS_LIB = $_csslib |
758 CSS_INC = $_cssinc | |
1 | 759 WIN32_PATH=-DWIN32_PATH=\"$_win32libdir\" |
760 | |
761 EOF | |
762 # echo 'CFLAGS=$(OPTFLAGS) -Wall -DMPG12PLAY' >> config.mak | |
763 | |
764 echo "Creating $CCONF" | |
765 | |
766 if [ "$_mmx" = "yes" ]; then | |
767 _mmx='#define HAVE_MMX' | |
768 else | |
769 _mmx='#undef HAVE_MMX' | |
770 fi | |
771 | |
350 | 772 if [ "$_mmx2" = "yes" ]; then |
773 _mmx2='#define HAVE_MMX2' | |
774 else | |
775 _mmx2='#undef HAVE_MMX2' | |
776 fi | |
777 | |
1 | 778 if [ $_3dnow = yes ]; then |
779 _3dnowm='#define HAVE_3DNOW' | |
780 else | |
781 _3dnowm='#undef HAVE_3DNOW' | |
782 fi | |
783 | |
784 if [ $_sse = yes ]; then | |
785 _ssem='#define HAVE_SSE' | |
786 else | |
787 _ssem='#undef HAVE_SSE' | |
788 fi | |
789 | |
790 # --- | |
791 | |
792 _vosrc='' | |
793 | |
525 | 794 if [ $_png = yes ]; then |
795 _png='#define HAVE_PNG' | |
796 _vosrc=$_vosrc' vo_png.c' | |
797 else | |
798 _png='#undef HAVE_PNG' | |
799 fi | |
800 | |
801 | |
1 | 802 if [ $_mlib = yes ]; then |
803 _mlib='#define HAVE_MLIB' | |
804 _vosrc=$_vosrc' yuv2rgb_mlib.c' | |
805 else | |
806 _mlib='#undef HAVE_MLIB' | |
807 fi | |
808 | |
809 # --- | |
810 | |
811 if [ $_gl = yes ]; then | |
812 _gl='#define HAVE_GL' | |
813 _vosrc=$_vosrc' vo_gl.c' | |
814 else | |
815 _gl='#undef HAVE_GL' | |
816 fi | |
817 | |
818 if [ $_sdl = yes ]; then | |
819 _sdldef='#define HAVE_SDL' | |
820 _vosrc=$_vosrc' vo_sdl.c' | |
821 else | |
822 _sdldef='#undef HAVE_SDL' | |
823 fi | |
824 | |
825 if [ $_x11 = yes ]; then | |
826 _x11='#define HAVE_X11' | |
827 _vosrc=$_vosrc' vo_x11.c' | |
828 else | |
829 _x11='#undef HAVE_X11' | |
830 fi | |
831 | |
832 if [ $_xv = yes ]; then | |
833 _xv='#define HAVE_XV' | |
834 _vosrc=$_vosrc' vo_xv.c' | |
835 else | |
836 _xv='#undef HAVE_XV' | |
837 fi | |
838 | |
209
26d2d4d3331a
Addes autodetection of XF86VidMode to configure, and adds a description of
mgraffam
parents:
196
diff
changeset
|
839 if [ $_vm = yes ]; then |
26d2d4d3331a
Addes autodetection of XF86VidMode to configure, and adds a description of
mgraffam
parents:
196
diff
changeset
|
840 _vm='#define HAVE_XF86VM' |
26d2d4d3331a
Addes autodetection of XF86VidMode to configure, and adds a description of
mgraffam
parents:
196
diff
changeset
|
841 else |
26d2d4d3331a
Addes autodetection of XF86VidMode to configure, and adds a description of
mgraffam
parents:
196
diff
changeset
|
842 _vm='#undef HAVE_XF86VM' |
26d2d4d3331a
Addes autodetection of XF86VidMode to configure, and adds a description of
mgraffam
parents:
196
diff
changeset
|
843 fi |
26d2d4d3331a
Addes autodetection of XF86VidMode to configure, and adds a description of
mgraffam
parents:
196
diff
changeset
|
844 |
1 | 845 # --- |
846 | |
847 if [ $_mga = yes ]; then | |
848 _mga='#define HAVE_MGA' | |
849 _vosrc=$_vosrc' vo_mga.c' | |
850 else | |
851 _mga='#undef HAVE_MGA' | |
852 fi | |
853 if [ $_xmga = yes ]; then | |
854 _vosrc=$_vosrc' vo_xmga.c' | |
855 fi | |
856 | |
857 if [ $_syncfb = yes ]; then | |
858 _syncfb='#define HAVE_SYNCFB' | |
859 _vosrc=$_vosrc' vo_syncfb.c' | |
860 else | |
861 _syncfb='#undef HAVE_SYNCFB' | |
862 fi | |
863 | |
864 if [ $_3dfx = yes ]; then | |
865 _3dfx='#define HAVE_3DFX' | |
866 _vosrc=$_vosrc' vo_3dfx.c' | |
867 else | |
868 _3dfx='#undef HAVE_3DFX' | |
869 fi | |
870 | |
287 | 871 if [ $_svga = yes ]; then |
872 _svga='#define HAVE_SVGALIB' | |
873 _vosrc=$_vosrc' vo_svga.c' | |
874 else | |
875 _svga='#undef HAVE_SVGALIB' | |
876 fi | |
877 | |
11 | 878 if [ $_dga = yes ]; then |
879 _dga='#define HAVE_DGA' | |
38 | 880 _vosrc=$_vosrc' vo_dga.c vo_fsdga.c' |
11 | 881 else |
882 _dga='#undef HAVE_DGA' | |
883 fi | |
884 | |
233
f62ccacbe1e5
Changes to configure to autodetect DGA 2.0 functionality, and to only use
mgraffam
parents:
225
diff
changeset
|
885 if [ $_dga2 = yes ]; then |
f62ccacbe1e5
Changes to configure to autodetect DGA 2.0 functionality, and to only use
mgraffam
parents:
225
diff
changeset
|
886 _dga2='#define HAVE_DGA2' |
f62ccacbe1e5
Changes to configure to autodetect DGA 2.0 functionality, and to only use
mgraffam
parents:
225
diff
changeset
|
887 _vosrc=$_vosrc' vo_dga.c vo_fsdga.c' |
f62ccacbe1e5
Changes to configure to autodetect DGA 2.0 functionality, and to only use
mgraffam
parents:
225
diff
changeset
|
888 else |
f62ccacbe1e5
Changes to configure to autodetect DGA 2.0 functionality, and to only use
mgraffam
parents:
225
diff
changeset
|
889 _dga2='#undef HAVE_DGA2' |
f62ccacbe1e5
Changes to configure to autodetect DGA 2.0 functionality, and to only use
mgraffam
parents:
225
diff
changeset
|
890 fi |
f62ccacbe1e5
Changes to configure to autodetect DGA 2.0 functionality, and to only use
mgraffam
parents:
225
diff
changeset
|
891 |
225 | 892 if [ $_fbdev = yes ]; then |
893 _fbdev='#define HAVE_FBDEV' | |
894 _vosrc=$_vosrc' vo_fbdev.c' | |
895 else | |
896 _fbdev='#undef HAVE_FBDEV' | |
897 fi | |
898 | |
1 | 899 if [ $_mpg123 = yes ]; then |
900 _mpg123='#define DEFAULT_MPG123' | |
901 else | |
902 _mpg123='#undef DEFAULT_MPG123' | |
903 fi | |
904 | |
905 cat > $CCONF << EOF | |
906 | |
907 /* -------- Generated by ./configure ----------- */ | |
908 | |
909 /* Define this to enable avg. byte/sec-based AVI sync method by default: | |
910 (use -bps or -nobps commandline option for run-time method selection) */ | |
911 #undef AVI_SYNC_BPS | |
912 | |
913 /* Undefine this if you want soundcard-only timing by default: | |
914 You can still change this with the -alsa or -noalsa command-line option! | |
915 (This function was originally impemented to solve ALSA driver's big | |
916 buffer problems, but it seems to be useful for every soundcard drivers) */ | |
917 #define ALSA_TIMER | |
918 | |
919 /* Undefine this if your soundcard driver has no working select(). | |
920 If you have kernel Oops, player hangups, or just no audio, you should | |
921 try to recompile MPlayer with this option disabled! */ | |
463 | 922 $_select |
1 | 923 |
924 /* You have a choice for MP3 decoding: mp3lib(mpg123) or Win32(l3codeca.acm) | |
925 #define this if you prefer mpg123 (with 3Dnow! support) than l3codeca.acm | |
926 (with mmx/sse optimizations) | |
927 You can still change it runtime using -afm 1 (mpg123) or -afm 4 (l3codeca)*/ | |
928 $_mpg123 | |
929 | |
930 /* XMMP support: (test code) */ | |
931 $_xmmpaudio | |
932 #define LIBDIR "/usr/local/lib" | |
933 #define PLUGINDIR LIBDIR "/xmmp/Plugins" | |
934 #define XMMP_AUDIO_DRIVER PLUGINDIR "/Sound/oss.so" | |
935 | |
936 /* LIRC (remote control, see www.lirc.org) support: */ | |
937 $_lircdefs | |
938 | |
492 | 939 /* DeCSS support using libcss */ |
940 $_css | |
941 | |
41 | 942 /* Define this to enable MPEG 1/2 image postprocessing (requires FAST cpu!) */ |
943 #define MPEG12_POSTPROC | |
944 | |
1 | 945 /* Define if your processor stores words with the most significant |
946 byte first (like Motorola and SPARC, unlike Intel and VAX). */ | |
947 /* #define WORDS_BIGENDIAN */ | |
948 | |
949 #define ARCH_X86 | |
950 | |
951 ///////////////////////////////////////////////////////////////////////////// | |
952 // | |
953 // NOTE: Instead of modifying these here, use the --enable/--disable options | |
954 // of the ./configure script! See ./configure --help for details. | |
955 // | |
956 ///////////////////////////////////////////////////////////////////////////// | |
957 | |
958 /* termcap flag for getch2.c */ | |
959 $_termcap | |
525 | 960 $_png |
1 | 961 |
962 /* Extension defines */ | |
963 $_mlib // available only on solaris | |
964 $_3dnowm // only define if you have 3DNOW (AMD k6-2, AMD Athlon, iDT WinChip, etc.) | |
965 $_mmx // only define if you have MMX | |
350 | 966 $_mmx2 // only define if you have MMX2 |
1 | 967 $_ssem // only define if you have SSE (Intel Pentium III or Celeron II) |
968 | |
969 /* libvo options */ | |
970 #define SCREEN_SIZE_X $_x | |
971 #define SCREEN_SIZE_Y $_y | |
972 $_x11 | |
973 $_xv | |
209
26d2d4d3331a
Addes autodetection of XF86VidMode to configure, and adds a description of
mgraffam
parents:
196
diff
changeset
|
974 $_vm |
1 | 975 $_gl |
11 | 976 $_dga |
233
f62ccacbe1e5
Changes to configure to autodetect DGA 2.0 functionality, and to only use
mgraffam
parents:
225
diff
changeset
|
977 $_dga2 |
1 | 978 $_sdldef |
979 $_3dfx | |
980 $_mga | |
981 $_syncfb | |
225 | 982 $_fbdev |
287 | 983 $_svga |
1 | 984 |
23 | 985 #if defined(HAVE_GL)||defined(HAVE_X11)||defined(HAVE_XV) |
1 | 986 #define X11_FULLSCREEN |
987 #endif | |
988 | |
989 EOF | |
990 | |
991 echo "Creating libvo/config.mak" | |
992 | |
993 _voobj=`echo $_vosrc | sed -e 's/\.c/\.o/g'` | |
994 | |
995 cat > libvo/config.mak << EOF | |
996 | |
997 include ../config.mak | |
998 | |
999 OPTIONAL_SRCS=$_vosrc | |
1000 OPTIONAL_OBJS=$_voobj | |
1001 | |
1002 EOF | |
1003 | |
1004 echo "Creating libac3/config.mak" | |
1005 | |
1006 if [ $_sse = yes ]; then | |
1007 _downmixc='downmix/downmix_kni.S' | |
1008 _downmixo='downmix/downmix_kni.o' | |
1009 else | |
1010 if [ $_binutils = yes ]; then | |
1011 _downmixc='downmix/downmix_i386.S' | |
1012 _downmixo='downmix/downmix_i386.o' | |
1013 else | |
1014 _downmixc='downmix/downmix.c' | |
1015 _downmixo='downmix/downmix.o' | |
1016 cat << EOF | |
1017 | |
1018 !!! Warning! fallback to slow downmix.c due the old binutils. | |
1019 !!! Upgrade for better audio decoding performance. | |
1020 | |
1021 EOF | |
1022 fi | |
1023 fi | |
1024 | |
1025 cat > libac3/config.mak << EOF | |
1026 | |
1027 include ../config.mak | |
1028 | |
1029 OPTIONAL_SRCS = $_downmixc | |
1030 OPTIONAL_OBJS = $_downmixo | |
1031 | |
1032 EOF | |
1033 | |
1034 echo "Creating mp3lib/config.mak" | |
1035 | |
1036 if [ $_3dnow = yes ]; then | |
1037 _3dnowobjectsrcs='dct36_3dnow.s dct64_3dnow.s decode_3dnow.s' | |
1038 _3dnowobjectobjs='dct36_3dnow.o dct64_3dnow.o decode_3dnow.o' | |
1039 else | |
1040 _3dnowobjectsrcs= | |
1041 _3dnowobjectobjs= | |
1042 fi | |
1043 | |
1044 cat > mp3lib/config.mak << EOF | |
1045 | |
1046 include ../config.mak | |
1047 | |
1048 OPTIONAL_SRCS = $_3dnowobjectsrcs | |
1049 OPTIONAL_OBJS = $_3dnowobjectobjs | |
1050 | |
1051 EOF | |
1052 | |
1053 cat << EOF | |
1054 | |
1055 Config files successfully generated by ./configure ! | |
1056 Please check config.h and config.mak files, tune CPU | |
1057 and optimization flags if you don't like these defaults. | |
1058 You can compile the program with 'make dep;make' and | |
1059 install with 'make install'. Good luck! | |
1060 | |
1061 EOF | |
1062 | |
1063 if [ $_mtrr = yes ]; then | |
1064 echo "Please check mtrr settings at /proc/mtrr (see DOCS/MTRR)" | |
1065 echo | |
1066 fi | |
1067 | |
548
c5c2d4e41a4a
added sdl versiondetect and removed sdl warning (it's autodetect now)
atmosfear
parents:
525
diff
changeset
|
1068 if [ $_sdl = outdated ]; then |
c5c2d4e41a4a
added sdl versiondetect and removed sdl warning (it's autodetect now)
atmosfear
parents:
525
diff
changeset
|
1069 echo "You have libSDL installed, but your version is outdated (earlier then" |
c5c2d4e41a4a
added sdl versiondetect and removed sdl warning (it's autodetect now)
atmosfear
parents:
525
diff
changeset
|
1070 echo "v.1.1.7), SDL support has been disabled please update, if you want to" |
c5c2d4e41a4a
added sdl versiondetect and removed sdl warning (it's autodetect now)
atmosfear
parents:
525
diff
changeset
|
1071 echo "use it (libSDL v1.1.8 and v1.2.0 are tested and known to work, recent" |
c5c2d4e41a4a
added sdl versiondetect and removed sdl warning (it's autodetect now)
atmosfear
parents:
525
diff
changeset
|
1072 echo "versions are available from http://www.libsdl.org/)." |
c5c2d4e41a4a
added sdl versiondetect and removed sdl warning (it's autodetect now)
atmosfear
parents:
525
diff
changeset
|
1073 echo "After updating you need to re-run ./configure and recompile to enable SDL." |
1 | 1074 echo |
1075 fi | |
1076 | |
1077 if [ $_win32libdirnotify = yes ]; then | |
1078 echo "Missing WIN32 codecs dir at $_win32libdir !" | |
1079 echo "Make it and copy DLL files to there! (You can get them from your windows" | |
1080 echo "directory or download ftp://thot.banki.hu/esp-team/linux/MPlayer/w32codec.zip" | |
1081 else | |
1082 echo "Ok, Win32 codecs directory at $_win32libdir already exists." | |
1083 fi | |
1084 |