summaryrefslogtreecommitdiffstats
path: root/video/mpv/BUILD
blob: 980fc65b84637614a9b31523fa52f3ceda90e520 (plain) (blame)
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
OPTS="$MPV_OPTS $OPTS" &&

if is_depends_enabled "${SPELL}" "smgl-gl_select"; then
  local GLSELECT=n &&

  for provider in `gaze -q provides OPENGL`; do
    if spell_ok $provider && [[ $provider != mesalib || $provider != mesa ]]; then
      GLSELECT=y
    fi
  done &&

  if [[ $GLSELECT == y ]]; then
    message "${MESSAGE_COLOR}NOTICE: Other OPENGL provider than mesalib is installed;" &&
    message "$SPELL requires active mesalib headers - switching it now." &&
    message "Don't forget to switch back via smgl-gl_select script.${DEFAULT_COLOR}\n" &&

    glselect mesa
  fi
fi &&

if [[ $(get_spell_provider $SPELL LIBAVCODEC) == "ffmpeg-svn" ]]; then
  OPTS+=" --enable-ffmpeg-strict-abi"
fi &&

OPTS+=" --bindir=${INSTALL_ROOT}/usr/bin --confdir=${INSTALL_ROOT}/etc/mpv" &&
waf_build