comparison configure @ 1020:72cacd3b8f30

Solaris 8 support - patch by Marcus Comstedt <marcus@idonex.se>
author arpi_esp
date Tue, 05 Jun 2001 02:26:56 +0000
parents 990047bcb1b8
children e8cc983945fe
comparison
equal deleted inserted replaced
1019:990047bcb1b8 1020:72cacd3b8f30
147 147
148 TMPC="mplayer-conf-${RANDOM}-$$-${RANDOM}.c" 148 TMPC="mplayer-conf-${RANDOM}-$$-${RANDOM}.c"
149 TMPO="mplayer-conf-${RANDOM}-$$-${RANDOM}.o" 149 TMPO="mplayer-conf-${RANDOM}-$$-${RANDOM}.o"
150 TMPS="mplayer-conf-${RANDOM}-$$-${RANDOM}.S" 150 TMPS="mplayer-conf-${RANDOM}-$$-${RANDOM}.S"
151 151
152 if [ ! -z $TMPDIR ]; then 152 if [ ! -z "$TMPDIR" ]; then
153 TMPC="${TMPDIR}/${TMPC}" 153 TMPC="${TMPDIR}/${TMPC}"
154 TMPO="${TMPDIR}/${TMPO}" 154 TMPO="${TMPDIR}/${TMPO}"
155 TMPS="${TMPDIR}/${TMPS}" 155 TMPS="${TMPDIR}/${TMPS}"
156 elif [ ! -z $TEMPDIR ]; then 156 elif [ ! -z "$TEMPDIR" ]; then
157 TMPC="${TEMPDIR}/${TMPC}" 157 TMPC="${TEMPDIR}/${TMPC}"
158 TMPO="${TEMPDIR}/${TMPO}" 158 TMPO="${TEMPDIR}/${TMPO}"
159 TMPS="${TEMPDIR}/${TMPS}" 159 TMPS="${TEMPDIR}/${TMPS}"
160 else 160 else
161 TMPC="/tmp/${TMPC}" 161 TMPC="/tmp/${TMPC}"
173 173
174 _cc=gcc 174 _cc=gcc
175 _x11=auto 175 _x11=auto
176 176
177 _x11libdir= 177 _x11libdir=
178 if [ -e /usr/X11R6 ]; then 178 if [ -d /usr/X11R6 ]; then
179 _x11libdir=-L/usr/X11R6/lib 179 _x11libdir=-L/usr/X11R6/lib
180 else 180 else
181 if [ -e /usr/X11 ]; then 181 if [ -d /usr/X11 ]; then
182 _x11libdir=-L/usr/X11/lib 182 _x11libdir=-L/usr/X11/lib
183 fi 183 fi
184 fi 184 fi
185 185
186 _skip_cc_check=no 186 _skip_cc_check=no
325 325
326 done 326 done
327 327
328 328
329 _win32libdirnotify=no 329 _win32libdirnotify=no
330 if [ -e /usr/lib/win32 ]; then 330 if [ -d /usr/lib/win32 ]; then
331 _win32libdir=/usr/lib/win32 331 _win32libdir=/usr/lib/win32
332 else 332 else
333 if [ -e /usr/local/lib/win32 ]; then 333 if [ -d /usr/local/lib/win32 ]; then
334 _win32libdir=/usr/local/lib/win32 334 _win32libdir=/usr/local/lib/win32
335 else 335 else
336 # This is our default: 336 # This is our default:
337 _win32libdir=/usr/lib/win32 337 _win32libdir=/usr/lib/win32
338 _win32libdirnotify=yes 338 _win32libdirnotify=yes
339 fi 339 fi
340 fi 340 fi
341 341
342 342
343 if [ -e /dev/mga_vid ]; then 343 if [ -c /dev/mga_vid ]; then
344 _mga=yes 344 _mga=yes
345 _syncfb=yes 345 _syncfb=yes
346 fi 346 fi
347 347
348 proc=pentium 348 proc=pentium
485 { echo "Lib pthread not found."; rm -f $TMPC $TMPO ; exit 1; } 485 { echo "Lib pthread not found."; rm -f $TMPC $TMPO ; exit 1; }
486 486
487 # Atmosfear: added SDL versioncheck and autodetect; removed warnings. 487 # Atmosfear: added SDL versioncheck and autodetect; removed warnings.
488 _sdl=no 488 _sdl=no
489 if $_cc $TMPC -o $TMPO `$_sdlconfig --libs` &> /dev/null ; then 489 if $_cc $TMPC -o $TMPO `$_sdlconfig --libs` &> /dev/null ; then
490 if test `$_sdlconfig --version | sed s/[=[:punct:]=]//g` -gt 116 ; then 490 if test `$_sdlconfig --version | sed s/[^0-9]//g` -gt 116 ; then
491 if test `$_sdlconfig --version | sed s/[=[:punct:]=]//g` -lt 121 ; then 491 if test `$_sdlconfig --version | sed s/[^0-9]//g` -lt 121 ; then
492
492 _sdlbuggy='#define BUGGY_SDL' 493 _sdlbuggy='#define BUGGY_SDL'
493 else 494 else
494 _sdlbuggy='#undef BUGGY_SDL' 495 _sdlbuggy='#undef BUGGY_SDL'
495 fi 496 fi
496 _sdl=yes 497 _sdl=yes
519 520
520 _termcap=no 521 _termcap=no
521 $_cc $TMPC -o $TMPO -ltermcap &> /dev/null && _termcap=yes 522 $_cc $TMPC -o $TMPO -ltermcap &> /dev/null && _termcap=yes
522 523
523 _png=no 524 _png=no
524 $_cc $TMPC -o $TMPO -lpng -lz&> /dev/null && _png=yes 525 $_cc $TMPC -o $TMPO -lpng -lz -lm &> /dev/null && _png=yes
525 526
526 _binutils=no 527 _binutils=no
527 as libac3/downmix/downmix_i386.S -o $TMPO &> /dev/null && _binutils=yes 528 as libac3/downmix/downmix_i386.S -o $TMPO &> /dev/null && _binutils=yes
528 529
529 # echo binutils: $_binutils 530 # echo binutils: $_binutils
530 531
531 # ----------- Check X11 and related libs (GL, Xxf86vm, Xv, DGA) -------------- 532 # ----------- Check X11 and related libs (GL, Xxf86vm, Xv, DGA) --------------
532 533
534 # for Solaris:
535 _socklib=
536 $_cc $TMPC -o $TMPO -lsocket >/dev/null 2>&1 && _socklib=-lsocket
537
533 if [ $_x11 = auto ]; then 538 if [ $_x11 = auto ]; then
534 _x11=no 539 _x11=no
535 $_cc $TMPC -o $TMPO $_x11libdir -lX11 -lXext &> /dev/null && _x11=yes 540 $_cc $TMPC -o $TMPO $_x11libdir -lX11 -lXext $_socklib &> /dev/null && _x11=yes
536 fi 541 fi
537 542
538 if [ $_x11 = yes ]; then 543 if [ $_x11 = yes ]; then
539 544
540 $_cc $TMPC -o $TMPO $_x11libdir -lX11 -lXext -lXdpms &> /dev/null && _xdpms=yes 545 $_cc $TMPC -o $TMPO $_x11libdir -lX11 -lXext -lXdpms $_socklib &> /dev/null && _xdpms=yes
541 $_cc $TMPC -o $TMPO $_x11libdir -lX11 -lXext -lXv &> /dev/null && _xv=yes 546 $_cc $TMPC -o $TMPO $_x11libdir -lX11 -lXext -lXv $_socklib &> /dev/null && _xv=yes
542 $_cc $TMPC -o $TMPO $_x11libdir -lX11 -lXext -lXxf86vm &> /dev/null && _vm=yes 547 $_cc $TMPC -o $TMPO $_x11libdir -lX11 -lXext -lXxf86vm $_socklib &> /dev/null && _vm=yes
543 548
544 $_cc $TMPC -o $TMPO $_x11libdir -lX11 -lXext -lGL &> /dev/null && _gl=yes 549 $_cc $TMPC -o $TMPO $_x11libdir -lX11 -lXext -lGL $_socklib &> /dev/null && _gl=yes
545 550
546 cat > $TMPC << EOF 551 cat > $TMPC << EOF
547 #include <GL/gl.h> 552 #include <GL/gl.h>
548 int main( void ) { return 0; } 553 int main( void ) { return 0; }
549 EOF 554 EOF
550 $_cc $TMPC -o $TMPO $_x11libdir -lX11 -lXext -lGL &> /dev/null || \ 555 $_cc $TMPC -o $TMPO $_x11libdir -lX11 -lXext -lGL $_socklib &> /dev/null || \
551 { _gl=no; echo "GL includes not found!";} 556 { _gl=no; echo "GL includes not found!";}
552 557
553 cat > $TMPC << EOF 558 cat > $TMPC << EOF
554 #include <stdio.h> 559 #include <stdio.h>
555 #include <X11/Xlib.h> 560 #include <X11/Xlib.h>
556 #include <X11/extensions/xf86dga.h> 561 #include <X11/extensions/xf86dga.h>
557 int main (void) { return 0;} 562 int main (void) { return 0;}
558 EOF 563 EOF
559 564
560 $_cc $TMPC -o $TMPO -L/usr/X11R6/lib -L/usr/X11/lib -lX11 -lXext -lXxf86dga -lXxf86vm &> /dev/null && _dga=yes 565 $_cc $TMPC -o $TMPO -L/usr/X11R6/lib -L/usr/X11/lib -lX11 -lXext -lXxf86dga -lXxf86vm $_socklib &> /dev/null && _dga=yes
561 # Note: the -lXxf86vm library is the VideoMode extension and though it's 566 # Note: the -lXxf86vm library is the VideoMode extension and though it's
562 # not needed for DGA, AFAIK every distribution packages together with DGA 567 # not needed for DGA, AFAIK every distribution packages together with DGA
563 # stuffs named 'X extensions' or something similar. This check can be usefull 568 # stuffs named 'X extensions' or something similar. This check can be usefull
564 # for further mplayer versions to set resolution by mplayer itself. 569 # for further mplayer versions to set resolution by mplayer itself.
565 # If you run into problems, remove '-lXxf86vm'. 570 # If you run into problems, remove '-lXxf86vm'.
571 #include <X11/extensions/xf86dga.h> 576 #include <X11/extensions/xf86dga.h>
572 int main (void) { XDGAMode mode; XDGADevice device; return 0;} 577 int main (void) { XDGAMode mode; XDGADevice device; return 0;}
573 EOF 578 EOF
574 579
575 _dga2=no 580 _dga2=no
576 $_cc $TMPC -o $TMPO -L/usr/X11R6/lib -L/usr/X11/lib -lX11 -lXext -lXxf86dga -lXxf86vm &> /dev/null && _dga2=yes 581 $_cc $TMPC -o $TMPO -L/usr/X11R6/lib -L/usr/X11/lib -lX11 -lXext -lXxf86dga -lXxf86vm $_socklib &> /dev/null && _dga2=yes
577 582
578 fi 583 fi
579 584
580 rm -f $TMPC $TMPO 585 rm -f $TMPC $TMPO
581 586
902 if [ $_gl = yes ]; then 907 if [ $_gl = yes ]; then
903 _gllib='-lGL' 908 _gllib='-lGL'
904 fi 909 fi
905 910
906 if [ $_css = yes ]; then 911 if [ $_css = yes ]; then
907 if [ ! -z $_csslibdir ]; then 912 if [ ! -z "$_csslibdir" ]; then
908 _csslib="-L${_csslibdir} -lcss" 913 _csslib="-L${_csslibdir} -lcss"
909 else 914 else
910 _csslib='-lcss' 915 _csslib='-lcss'
911 fi 916 fi
912 _css='#define HAVE_LIBCSS' 917 _css='#define HAVE_LIBCSS'
913 if [ ! -z $_cssincdir ]; then 918 if [ ! -z "$_cssincdir" ]; then
914 _cssinc="-I${_cssincdir}" 919 _cssinc="-I${_cssincdir}"
915 else 920 else
916 _cssinc="" 921 _cssinc=""
917 fi 922 fi
918 else 923 else
1010 CC=$_cc 1015 CC=$_cc
1011 X11DIR=$_x11libdir 1016 X11DIR=$_x11libdir
1012 # OPTFLAGS=-O4 $_profile $_debug -march=$proc -mcpu=$proc -pipe -fomit-frame-pointer -ffast-math 1017 # OPTFLAGS=-O4 $_profile $_debug -march=$proc -mcpu=$proc -pipe -fomit-frame-pointer -ffast-math
1013 OPTFLAGS=$CFLAGS 1018 OPTFLAGS=$CFLAGS
1014 # LIBS=-L/usr/lib -L/usr/local/lib $_x11libdir $_gllib $_sdllib $_dgalib $_x11lib $_xvlib 1019 # LIBS=-L/usr/lib -L/usr/local/lib $_x11libdir $_gllib $_sdllib $_dgalib $_x11lib $_xvlib
1015 X_LIBS=$_x11libdir $_gllib $_sdllib $_dgalib $_x11lib $_xvlib $_vmlib $_svgalib $_libpng 1020 X_LIBS=$_x11libdir $_gllib $_sdllib $_dgalib $_x11lib $_xvlib $_vmlib $_svgalib $_libpng $_socklib
1016 TERMCAP_LIB=$_libtermcap 1021 TERMCAP_LIB=$_libtermcap
1017 XMM_LIBS = $_xmmplibs 1022 XMM_LIBS = $_xmmplibs
1018 LIRC_LIBS = $_lirclibs 1023 LIRC_LIBS = $_lirclibs
1019 CSS_LIB = $_csslib 1024 CSS_LIB = $_csslib
1020 CSS_INC = $_cssinc 1025 CSS_INC = $_cssinc