mirror of
https://github.com/joncampbell123/dosbox-x.git
synced 2025-10-14 02:17:36 +08:00
allow fluidsynth, avcodec, and slirp if Brew is installed at compile time
This commit is contained in:
19
build-macosx
19
build-macosx
@@ -53,9 +53,26 @@ export CPPFLAGS="$new$CPPFLAGS"
|
||||
export CXXFLAGS="$new$CXXFLAGS"
|
||||
export INTERNAL_FREETYPE=1
|
||||
|
||||
opts=
|
||||
|
||||
# if Brew has installed packages, try to use those too
|
||||
brew="/opt/homebrew"
|
||||
if [[ -d "$brew" && -d "$brew/include" && -d "$brew/lib" ]]; then
|
||||
echo "Brew is installed, I'm going to use it's libraries too"
|
||||
new=" -I$brew/include"
|
||||
nld=" -L$brew/lib"
|
||||
export CFLAGS="$CFLAGS$new"
|
||||
export LDFLAGS="$LDFLAGS$nld"
|
||||
export CPPFLAGS="$CPPFLAGS$new"
|
||||
export CXXFLAGS="$CXXFLAGS$new"
|
||||
export PKG_CONFIG_PATH="$PKG_CONFIG_PATH:$brew/lib/pkgconfig"
|
||||
else
|
||||
opts+=" --disable-avcodec --disable-libfluidsynth --disable-libslirp"
|
||||
fi
|
||||
|
||||
# now compile ourself
|
||||
echo Compiling DOSBox-X
|
||||
chmod +x configure
|
||||
./configure --enable-core-inline --enable-debug=heavy --prefix=/usr --disable-libfluidsynth --disable-libslirp --disable-avcodec "$@" || exit 1
|
||||
./configure --enable-core-inline --enable-debug=heavy --prefix=/usr $opts "$@" || exit 1
|
||||
make -j3 || exit 1
|
||||
|
||||
|
Reference in New Issue
Block a user