Revision 320d060a configure

View differences:

configure
31 31
echo "  --enable-a52bin          open liba52.so.0 at runtime [default=no]"
32 32
echo "  --enable-dts             enable GPLed DTS support [default=no]"
33 33
echo "  --enable-pp              enable GPLed postprocessing support [default=no]"
34
echo "  --enable-static          build static libraries [default=yes]"
35
echo "  --disable-static         do not build static libraries [default=no]"
34 36
echo "  --enable-shared          build shared libraries [default=no]"
37
echo "  --disable-shared         do not build shared libraries [default=yes]"
35 38
echo "  --enable-amr_nb          enable amr_nb float audio codec"
36 39
echo "  --enable-amr_nb-fixed    use fixed point for amr-nb codec"
37 40
echo "  --enable-amr_wb          enable amr_wb float audio codec"
......
206 209
mingwce="no"
207 210
cygwin="no"
208 211
os2="no"
212
lstatic="yes"
209 213
lshared="no"
210 214
optimize="yes"
211 215
debug="yes"
......
549 553
  ;;
550 554
  --enable-mingwce) mingwce="yes"
551 555
  ;;
556
  --enable-static) lstatic="yes"
557
  ;;
558
  --disable-static) lstatic="no"
559
  ;;
552 560
  --enable-shared) lshared="yes"
553 561
  ;;
562
  --disable-shared) lshared="no"
563
  ;;
554 564
  --disable-debug) debug="no"
555 565
  ;;
556 566
  --disable-opts) optimize="no"
......
607 617
  esac
608 618
done
609 619

  
620
# we need to build at least one lib type
621
if test "$lstatic" = "no" && test "$lshared" = "no" ; then
622
    cat <<EOF
623
At least one library type must be built.
624
Specify --enable-static to build the static libraries or --enable-shared to
625
build the shared libraries as well. To only build the shared libraries specify
626
--disable-static in addition to --enable-shared.
627
EOF
628
    exit 1;
629
fi
630

  
610 631
if test "$theora" = "yes" ; then
611 632
    if test "$libogg" = "no"; then
612 633
        echo "libogg must be enabled to enable Theora."
......
869 890
fi
870 891

  
871 892
if test "$mingw32" = "yes" -o "$mingwce" = "yes"; then
893
    if test "$lshared" = "yes" && test "$lstatic" = "yes" ; then
894
        cat <<EOF
895
You can only build one library type at once on MinGW.
896
Specify --disable-static --enable-shared to only build
897
the shared libraries. To build only the static libraries
898
you don't need to pass additional options.
899
EOF
900
        exit 1
901
    fi
872 902
    v4l="no"
873 903
    bktr="no"
874 904
    audio_oss="no"
......
1296 1326
echo "debug symbols    $debug"
1297 1327
echo "strip symbols    $dostrip"
1298 1328
echo "optimize         $optimize"
1329
echo "static           $lstatic"
1299 1330
echo "shared           $lshared"
1300 1331
echo "video hooking    $vhook"
1301 1332
echo "SDL support      $sdl"
......
1364 1395
echo "BUILDSUF=$BUILDSUF" >> config.mak
1365 1396
echo "LIBPREF=$LIBPREF" >> config.mak
1366 1397
echo "LIBSUF=\${BUILDSUF}$LIBSUF" >> config.mak
1367
echo "LIB=$LIB" >> config.mak
1398
if test "$lstatic" = "yes" ; then
1399
  echo "LIB=$LIB" >> config.mak
1400
fi
1368 1401
echo "SLIBPREF=$SLIBPREF" >> config.mak
1369 1402
echo "SLIBSUF=\${BUILDSUF}$SLIBSUF" >> config.mak
1370 1403
echo "EXESUF=\${BUILDSUF}$EXESUF" >> config.mak
......
1508 1541

  
1509 1542

  
1510 1543
if test "$lshared" = "yes" ; then
1544
  echo "#define BUILD_SHARED_AV 1" >> $TMPH
1511 1545
  echo "BUILD_SHARED=yes" >> config.mak
1512 1546
  echo "PIC=-fPIC -DPIC" >> config.mak
1513 1547
  echo "SPPMAJOR=${lavc_version%%.*}" >> config.mak

Also available in: Unified diff