Skip to content

Commit

Permalink
Remove --enable-avcodec from build scripts, fix FFMPEG detection, do …
Browse files Browse the repository at this point in the history
…not link to avcodec or include avcodec headers if not detected
  • Loading branch information
Jonathan Campbell committed Jun 3, 2020
1 parent 51a7023 commit f351754
Show file tree
Hide file tree
Showing 9 changed files with 9 additions and 67 deletions.
2 changes: 1 addition & 1 deletion build
Expand Up @@ -19,6 +19,6 @@ echo Compiling our internal SDLnet 1.x
# now compile ourself
echo Compiling DOSBox-X
chmod +x configure
./configure --enable-core-inline --disable-debug --enable-avcodec --prefix=/usr "$@" || exit 1
./configure --enable-core-inline --disable-debug --prefix=/usr "$@" || exit 1
make -j3 || exit 1

2 changes: 1 addition & 1 deletion build-debug
Expand Up @@ -37,6 +37,6 @@ echo Compiling our internal SDLnet 1.x
# now compile ourself
echo Compiling DOSBox-X
chmod +x configure
./configure --enable-core-inline --enable-debug=heavy --enable-avcodec --prefix=/usr "$@" $opt || exit 1
./configure --enable-core-inline --enable-debug=heavy --prefix=/usr "$@" $opt || exit 1
make -j3 || exit 1

32 changes: 0 additions & 32 deletions build-debug-no-avcodec

This file was deleted.

2 changes: 1 addition & 1 deletion build-debug-no-mt32
Expand Up @@ -26,6 +26,6 @@ echo Compiling our internal SDLnet 1.x
# now compile ourself
echo Compiling DOSBox-X
chmod +x configure
./configure --enable-core-inline --enable-debug=heavy --enable-avcodec --prefix=/usr --disable-mt32 "$@" || exit 1
./configure --enable-core-inline --enable-debug=heavy --prefix=/usr --disable-mt32 "$@" || exit 1
make -j3 || exit 1

2 changes: 1 addition & 1 deletion build-debug-sdl2
Expand Up @@ -33,6 +33,6 @@ echo Compiling our internal SDLnet 1.x
(cd vs2015/sdlnet && ./build-dosbox.sh) || exit 1

chmod +x configure
./configure --enable-core-inline --enable-debug=heavy --enable-avcodec --prefix=/usr --enable-sdl2 "$@" $opt || exit 1
./configure --enable-core-inline --enable-debug=heavy --prefix=/usr --enable-sdl2 "$@" $opt || exit 1
make -j3 || exit 1

2 changes: 1 addition & 1 deletion build-macosx
Expand Up @@ -45,6 +45,6 @@ export CXXFLAGS="$new$CXXFLAGS"
# now compile ourself
echo Compiling DOSBox-X
chmod +x configure
./configure --enable-core-inline --enable-debug=heavy --prefix=/usr "$@" || exit 1 # --enable-avcodec
./configure --enable-core-inline --enable-debug=heavy --prefix=/usr "$@" || exit 1
make -j3 || exit 1

2 changes: 1 addition & 1 deletion build-macosx-sdl2
Expand Up @@ -42,6 +42,6 @@ export CXXFLAGS="$new$CXXFLAGS"
# now compile ourself
echo Compiling DOSBox-X
chmod +x configure
./configure --enable-core-inline --enable-debug=heavy --prefix=/usr --enable-sdl2 "$@" || exit 1 # --enable-avcodec
./configure --enable-core-inline --enable-debug=heavy --prefix=/usr --enable-sdl2 "$@" || exit 1
make -j3 || exit 1

24 changes: 0 additions & 24 deletions build-no-avcodec

This file was deleted.

8 changes: 3 additions & 5 deletions configure.ac
Expand Up @@ -947,14 +947,12 @@ fi
dnl FEATURE: FFMPEG output support
AH_TEMPLATE(C_AVCODEC,[Define to 1 to use FFMPEG libavcodec for video capture])
AC_ARG_ENABLE(avcodec,AC_HELP_STRING([--disable-avcodec],[Disable FFMPEG avcodec support]),,enable_ffmpeg=yes)
if test x$enable_avcodec = xyes; then
CFLAGS="$CFLAGS "`pkg-config libavcodec --cflags`
CPPFLAGS="$CPPFLAGS "`pkg-config libavcodec --cflags`
LIBS="$LIBS -lavcodec -lavformat -lavutil -lswscale "`pkg-config libavcodec --libs`
fi
if test x$enable_avcodec = xyes; then
if test x$have_ffmpeg = xyes; then
if test x$have_avcodec_h = xyes; then
CFLAGS="$CFLAGS "`pkg-config libavcodec --cflags`
CPPFLAGS="$CPPFLAGS "`pkg-config libavcodec --cflags`
LIBS="$LIBS -lavcodec -lavformat -lavutil -lswscale "`pkg-config libavcodec --libs`
AC_MSG_RESULT(yes)
AC_DEFINE(C_AVCODEC,1)
fi
Expand Down

0 comments on commit f351754

Please sign in to comment.