-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathbuild_linux.sh
More file actions
executable file
·76 lines (64 loc) · 2.07 KB
/
build_linux.sh
File metadata and controls
executable file
·76 lines (64 loc) · 2.07 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
#!/usr/bin/env bash
################################################################################
# Author: @gubatron
# Modified: 2025 - Refactored for native Linux builds
# This script builds a native fwplayer_linux binary for the host Linux architecture
# functions are defined in build-functions.sh
# ffmpeg codec flag related variables are generated by prepare_ffmpeg_flags.sh
# as output strings which are evaluated by prepare_ffmpeg_flags
################################################################################
#set -x
source build-functions.sh
# Verify we're on Linux
if ! is_linux; then
echo "Error: Linux builds must be done on Linux"
exit 1
fi
ARCH=`arch`
if [ ${ARCH} == "i386" ]; then
ARCH=x86_64
fi
if [ ${ARCH} == "aarch64" ]; then
ARCH=arm64
fi
echo "Building native Linux player for architecture: ${ARCH}"
press_any_key
cd MPlayer-1.5
make clean
make -C ffmpeg clean
# We now build everything with a single configure from MPlayer and it will sub-sequently build ffmpeg for us
#--enable-static \
./configure \
--disable-gui \
--disable-gnutls \
--disable-librtmp \
--disable-x11 \
--disable-gl \
--disable-esd \
--disable-alsa \
--disable-arts \
--disable-nas \
--disable-jack \
--disable-openal \
--disable-mencoder \
--disable-pulse \
--disable-runtime-cpudetection \
--enable-mad \
--enable-sdl \
--enable-liba52 \
--enable-libvorbis \
--enable-mp3lame \
--disable-live \
--disable-postproc \
--disable-decoder=all \
--enable-decoder=mp3 \
--enable-decoder=ac3 \
--enable-decoder=vorbis \
--extra-cflags="$(sdl-config --cflags) -Wno-error=implicit-function-declaration -Wno-unused-function -Wno-switch -Wno-expansion-to-defined -Wno-deprecated-declarations -Wno-shift-negative-value -Wno-pointer-sign -Wno-parentheses -Wdangling-else -mtune=generic -fPIC -Os" \
--extra-ldflags="-la52 -lvorbis -logg -lmad -lpthread $(sdl-config --libs)"
echo "Done with ./configure, next we build @ $(pwd)"
press_any_key
make -j 16
echo "Done building, now we'll rename mplayer to its new form for FrostWire @ $(pwd)"
strip_and_upx_final_executable "linux" "${ARCH}"
set +x