Makefile 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143
  1. # This file is part of the OpenADK project. OpenADK is copyrighted
  2. # material, please see the LICENCE file in the top-level directory.
  3. include ${TOPDIR}/rules.mk
  4. PKG_NAME:= mplayer
  5. PKG_VERSION:= 1.0-32749
  6. PKG_RELEASE:= 3
  7. PKG_MD5SUM:= aadc5d8cca503c8b18b3ed00b3a52cf5
  8. PKG_DESCR:= popular video player
  9. PKG_SECTION:= multimedia
  10. PKG_DEPENDS:= alsa-lib libjpeg libfaad2 libmad libncurses
  11. PKG_DEPENDS+= libogg libpng libpthread libvorbis giflib
  12. PKG_DEPENDS+= libx11 libxau libxdmcp libxext libxv zlib
  13. PKG_DEPENDS+= libxscrnsaver
  14. PKG_BUILDDEP:= alsa-lib libmad libvorbis faad2 ncurses zlib
  15. PKG_BUILDDEP+= libX11 libXv libpng libXext jpeg
  16. PKG_URL:= http://www.mplayerhq.hu/
  17. PKG_SITES:= http://openadk.org/distfiles/
  18. PKG_ARCH_DEPENDS:= x86 mips
  19. PKG_FLAVOURS_MPLAYER:= WITH_DIRECTFB
  20. PKGFD_WITH_DIRECTFB:= enable DirectFB video output support
  21. PKGFS_WITH_DIRECTFB:= directfb
  22. PKGFB_WITH_DIRECTFB:= DirectFB
  23. include ${TOPDIR}/mk/package.mk
  24. $(eval $(call PKG_template,MPLAYER,${PKG_NAME},${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  25. # gcc 4.5 produces internal compiler error with -Os
  26. TARGET_CFLAGS:=$(subst Os,O2,$(TARGET_CFLAGS))
  27. CONFIG_STYLE:= minimal
  28. FAKE_FLAGS+= INSTALLSTRIP=''
  29. ifeq (${ADK_TARGET_SYSTEM_LEMOTE_YEELONG},y)
  30. EXTRA_CFLAGS:= -DARCH_MIPS64
  31. endif
  32. # Somehow this include path is missing here, although other
  33. # applications build fine against DirectFB. There is also a
  34. # related patch to allow configure to find out the DirectFB
  35. # version number.
  36. ifeq (${ADK_PACKAGE_MPLAYER_WITH_DIRECTFB},y)
  37. TARGET_CPPFLAGS+= -I${STAGING_TARGET_DIR}/usr/include/directfb
  38. endif
  39. ifeq (${ADK_TARGET_CPU_WITH_MMX},y)
  40. CONFIGURE_CPU_OPTS:= --enable-mmx
  41. else
  42. CONFIGURE_CPU_OPTS:= --disable-mmx
  43. endif
  44. ifeq (${ADK_TARGET_CPU_WITH_MMXEXT},y)
  45. CONFIGURE_CPU_OPTS+= --enable-mmxext
  46. else
  47. CONFIGURE_CPU_OPTS+= --disable-mmxext
  48. endif
  49. ifeq (${ADK_TARGET_CPU_WITH_SSE},y)
  50. CONFIGURE_CPU_OPTS+= --enable-sse
  51. else
  52. CONFIGURE_CPU_OPTS+= --disable-sse
  53. endif
  54. ifeq (${ADK_TARGET_CPU_WITH_SSE2},y)
  55. CONFIGURE_CPU_OPTS+= --enable-sse2
  56. else
  57. CONFIGURE_CPU_OPTS+= --disable-sse2
  58. endif
  59. ifeq ($(ADK_DEBUG),y)
  60. CONFIGURE_DEBUG= --enable-debug
  61. endif
  62. ifeq (${ADK_PACKAGE_MPLAYER_WITH_DIRECTFB},y)
  63. CONFIGURE_DIRECTFB= --enable-directfb
  64. else
  65. CONFIGURE_DIRECTFB= --disable-directfb
  66. endif
  67. CONFIGURE_ARGS:= --prefix=/usr \
  68. --enable-x11 \
  69. --confdir=/etc \
  70. --enable-cross-compile \
  71. --target=${ARCH}-linux \
  72. --cc='$(TARGET_CC)' \
  73. --host-cc=$(CC_FOR_BUILD) \
  74. --yasm='' \
  75. --disable-mencoder \
  76. --enable-fbdev \
  77. --enable-alsa \
  78. --enable-tv \
  79. --enable-v4l2 \
  80. --enable-png \
  81. --enable-jpeg \
  82. --enable-mad \
  83. --enable-libvorbis \
  84. --disable-ossaudio \
  85. --disable-vm \
  86. --disable-iconv \
  87. --disable-lirc \
  88. --disable-radio-v4l2 \
  89. --disable-speex \
  90. --disable-faac \
  91. --disable-libdv \
  92. --disable-live \
  93. --disable-pvr \
  94. --disable-ftp \
  95. --disable-ivtv \
  96. --disable-dvdread-internal \
  97. --disable-libdvdcss-internal \
  98. --disable-freetype \
  99. --disable-mpg123 \
  100. --disable-tremor-internal \
  101. --disable-arts \
  102. --disable-esd \
  103. --disable-jack \
  104. --disable-openal \
  105. --disable-nas \
  106. --disable-sgiaudio \
  107. --disable-sunaudio \
  108. --disable-win32waveout \
  109. --disable-tga \
  110. --disable-pnm \
  111. --disable-md5sum \
  112. --disable-liblzo \
  113. --disable-sdl \
  114. --disable-xinerama \
  115. --disable-vidix \
  116. --disable-gl \
  117. --extra-cflags="${EXTRA_CFLAGS}" \
  118. ${CONFIGURE_CPU_OPTS} \
  119. ${CONFIGURE_DEBUG} \
  120. ${CONFIGURE_DIRECTFB}
  121. XAKE_FLAGS+= AR="${TARGET_CROSS}ar" RANLIB="${TARGET_CROSS}ranlib"
  122. post-install:
  123. ${INSTALL_DIR} ${IDIR_MPLAYER}/usr/bin
  124. ${CP} ${WRKINST}/usr/bin/mplayer ${IDIR_MPLAYER}/usr/bin
  125. include ${TOPDIR}/mk/pkg-bottom.mk