Makefile 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156
  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.1.1
  6. PKG_RELEASE:= 2
  7. PKG_MD5SUM:= 39dd55f30eb5403f219a606e79a6648a
  8. PKG_DESCR:= popular video player
  9. PKG_SECTION:= multimedia
  10. PKG_DEPENDS:= alsa-lib libjpeg-turbo libfaad2 libmad libncurses
  11. PKG_DEPENDS+= libogg libpng libpthread libvorbis giflib
  12. PKG_DEPENDS+= libx11 libxau libxdmcp libxext libxv zlib
  13. PKG_DEPENDS+= libxscrnsaver libtheora libxvid libvpx
  14. PKG_BUILDDEP:= alsa-lib libmad libvorbis faad2 ncurses zlib
  15. PKG_BUILDDEP+= libX11 libXv libpng libXext libjpeg-turbo libtheora
  16. PKG_BUILDDEP+= xvidcore libvpx gettext-tiny
  17. PKG_URL:= http://www.mplayerhq.hu/
  18. PKG_SITES:= http://www.mplayerhq.hu/MPlayer/releases/
  19. DISTFILES:= MPlayer-$(PKG_VERSION).tar.xz
  20. WRKDIST= ${WRKDIR}/MPlayer-${PKG_VERSION}
  21. PKG_ARCH_DEPENDS:= x86 x86_64 mips arm
  22. PKG_FLAVOURS_MPLAYER:= WITH_DIRECTFB
  23. PKGFD_WITH_DIRECTFB:= enable DirectFB video output support
  24. PKGFS_WITH_DIRECTFB:= directfb
  25. PKGFB_WITH_DIRECTFB:= DirectFB
  26. include ${TOPDIR}/mk/package.mk
  27. $(eval $(call PKG_template,MPLAYER,mplayer,${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  28. TARGET_CC:= ${TARGET_COMPILER_PREFIX}gcc
  29. XAKE_FLAGS+= GCC_HONOUR_COPTS=s
  30. TARGET_CFLAGS+= -D_POSIX_SOURCE -D_GNU_SOURCE
  31. CONFIG_STYLE:= minimal
  32. FAKE_FLAGS+= INSTALLSTRIP=''
  33. ifeq (${ADK_TARGET_SYSTEM_LEMOTE_YEELONG},y)
  34. EXTRA_CFLAGS:= -DARCH_MIPS64
  35. endif
  36. # Somehow this include path is missing here, although other
  37. # applications build fine against DirectFB. There is also a
  38. # related patch to allow configure to find out the DirectFB
  39. # version number.
  40. ifeq (${ADK_PACKAGE_MPLAYER_WITH_DIRECTFB},y)
  41. TARGET_CPPFLAGS+= -I${STAGING_TARGET_DIR}/usr/include/directfb
  42. endif
  43. ifeq (${ADK_TARGET_CPU_WITH_MMX},y)
  44. CONFIGURE_CPU_OPTS:= --enable-mmx
  45. else
  46. CONFIGURE_CPU_OPTS:= --disable-mmx
  47. endif
  48. ifeq (${ADK_TARGET_CPU_WITH_MMXEXT},y)
  49. CONFIGURE_CPU_OPTS+= --enable-mmxext
  50. else
  51. CONFIGURE_CPU_OPTS+= --disable-mmxext
  52. endif
  53. ifeq (${ADK_TARGET_CPU_WITH_SSE},y)
  54. CONFIGURE_CPU_OPTS+= --enable-sse
  55. else
  56. CONFIGURE_CPU_OPTS+= --disable-sse
  57. endif
  58. ifeq (${ADK_TARGET_CPU_WITH_SSE2},y)
  59. CONFIGURE_CPU_OPTS+= --enable-sse2
  60. else
  61. CONFIGURE_CPU_OPTS+= --disable-sse2
  62. endif
  63. #ifeq (${ADK_TARGET_CPU_WITH_IWMMXT},y)
  64. #CONFIGURE_CPU_OPTS+= --enable-iwmmxt
  65. #else
  66. #CONFIGURE_CPU_OPTS+= --disable-iwmmxt
  67. #endif
  68. ifeq ($(ADK_DEBUG),y)
  69. CONFIGURE_DEBUG= --enable-debug
  70. endif
  71. ifeq (${ADK_PACKAGE_MPLAYER_WITH_DIRECTFB},y)
  72. CONFIGURE_DIRECTFB= --enable-directfb
  73. else
  74. CONFIGURE_DIRECTFB= --disable-directfb
  75. endif
  76. CONFIGURE_ARGS:= --prefix=/usr \
  77. --enable-x11 \
  78. --confdir=/etc \
  79. --enable-cross-compile \
  80. --target=${ARCH}-linux \
  81. --cc='$(TARGET_CC)' \
  82. --host-cc=$(CC_FOR_BUILD) \
  83. --yasm='' \
  84. --disable-mencoder \
  85. --enable-fbdev \
  86. --enable-alsa \
  87. --enable-tv \
  88. --enable-v4l2 \
  89. --enable-png \
  90. --enable-jpeg \
  91. --enable-mad \
  92. --enable-libvorbis \
  93. --enable-faac \
  94. --enable-theora \
  95. --enable-xvid \
  96. --disable-ossaudio \
  97. --disable-vm \
  98. --disable-iconv \
  99. --disable-lirc \
  100. --disable-radio-v4l2 \
  101. --disable-speex \
  102. --disable-libdv \
  103. --disable-live \
  104. --disable-pvr \
  105. --disable-ftp \
  106. --disable-ivtv \
  107. --disable-dvdread-internal \
  108. --disable-libdvdcss-internal \
  109. --disable-freetype \
  110. --disable-mpg123 \
  111. --disable-tremor-internal \
  112. --disable-arts \
  113. --disable-esd \
  114. --disable-jack \
  115. --disable-openal \
  116. --disable-nas \
  117. --disable-sgiaudio \
  118. --disable-sunaudio \
  119. --disable-win32waveout \
  120. --disable-tga \
  121. --disable-pnm \
  122. --disable-md5sum \
  123. --disable-liblzo \
  124. --disable-sdl \
  125. --disable-xinerama \
  126. --disable-vidix \
  127. --disable-gl \
  128. --extra-cflags="${EXTRA_CFLAGS}" \
  129. ${CONFIGURE_CPU_OPTS} \
  130. ${CONFIGURE_DEBUG} \
  131. ${CONFIGURE_DIRECTFB}
  132. XAKE_FLAGS+= AR="${TARGET_CROSS}ar" RANLIB="${TARGET_CROSS}ranlib"
  133. TARGET_LDFLAGS+= -lxvidcore -lX11 -lXext -lvorbis
  134. mplayer-install:
  135. ${INSTALL_DIR} ${IDIR_MPLAYER}/usr/bin
  136. ${CP} ${WRKINST}/usr/bin/mplayer ${IDIR_MPLAYER}/usr/bin
  137. include ${TOPDIR}/mk/pkg-bottom.mk