1
0

Makefile 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157
  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:= 1
  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. XAKE_FLAGS+= GCC_HONOUR_COPTS=s
  29. # gcc 4.5 produces internal compiler error with -Os
  30. #TARGET_CFLAGS:=$(subst Os,O2,$(TARGET_CFLAGS))
  31. TARGET_CFLAGS+= -D_POSIX_SOURCE -D_GNU_SOURCE
  32. CONFIG_STYLE:= minimal
  33. FAKE_FLAGS+= INSTALLSTRIP=''
  34. ifeq (${ADK_TARGET_SYSTEM_LEMOTE_YEELONG},y)
  35. EXTRA_CFLAGS:= -DARCH_MIPS64
  36. endif
  37. # Somehow this include path is missing here, although other
  38. # applications build fine against DirectFB. There is also a
  39. # related patch to allow configure to find out the DirectFB
  40. # version number.
  41. ifeq (${ADK_PACKAGE_MPLAYER_WITH_DIRECTFB},y)
  42. TARGET_CPPFLAGS+= -I${STAGING_TARGET_DIR}/usr/include/directfb
  43. endif
  44. ifeq (${ADK_TARGET_CPU_WITH_MMX},y)
  45. CONFIGURE_CPU_OPTS:= --enable-mmx
  46. else
  47. CONFIGURE_CPU_OPTS:= --disable-mmx
  48. endif
  49. ifeq (${ADK_TARGET_CPU_WITH_MMXEXT},y)
  50. CONFIGURE_CPU_OPTS+= --enable-mmxext
  51. else
  52. CONFIGURE_CPU_OPTS+= --disable-mmxext
  53. endif
  54. ifeq (${ADK_TARGET_CPU_WITH_SSE},y)
  55. CONFIGURE_CPU_OPTS+= --enable-sse
  56. else
  57. CONFIGURE_CPU_OPTS+= --disable-sse
  58. endif
  59. ifeq (${ADK_TARGET_CPU_WITH_SSE2},y)
  60. CONFIGURE_CPU_OPTS+= --enable-sse2
  61. else
  62. CONFIGURE_CPU_OPTS+= --disable-sse2
  63. endif
  64. #ifeq (${ADK_TARGET_CPU_WITH_IWMMXT},y)
  65. #CONFIGURE_CPU_OPTS+= --enable-iwmmxt
  66. #else
  67. #CONFIGURE_CPU_OPTS+= --disable-iwmmxt
  68. #endif
  69. ifeq ($(ADK_DEBUG),y)
  70. CONFIGURE_DEBUG= --enable-debug
  71. endif
  72. ifeq (${ADK_PACKAGE_MPLAYER_WITH_DIRECTFB},y)
  73. CONFIGURE_DIRECTFB= --enable-directfb
  74. else
  75. CONFIGURE_DIRECTFB= --disable-directfb
  76. endif
  77. CONFIGURE_ARGS:= --prefix=/usr \
  78. --enable-x11 \
  79. --confdir=/etc \
  80. --enable-cross-compile \
  81. --target=${ARCH}-linux \
  82. --cc='$(TARGET_CC)' \
  83. --host-cc=$(CC_FOR_BUILD) \
  84. --yasm='' \
  85. --disable-mencoder \
  86. --enable-fbdev \
  87. --enable-alsa \
  88. --enable-tv \
  89. --enable-v4l2 \
  90. --enable-png \
  91. --enable-jpeg \
  92. --enable-mad \
  93. --enable-libvorbis \
  94. --enable-faac \
  95. --enable-theora \
  96. --enable-xvid \
  97. --disable-ossaudio \
  98. --disable-vm \
  99. --disable-iconv \
  100. --disable-lirc \
  101. --disable-radio-v4l2 \
  102. --disable-speex \
  103. --disable-libdv \
  104. --disable-live \
  105. --disable-pvr \
  106. --disable-ftp \
  107. --disable-ivtv \
  108. --disable-dvdread-internal \
  109. --disable-libdvdcss-internal \
  110. --disable-freetype \
  111. --disable-mpg123 \
  112. --disable-tremor-internal \
  113. --disable-arts \
  114. --disable-esd \
  115. --disable-jack \
  116. --disable-openal \
  117. --disable-nas \
  118. --disable-sgiaudio \
  119. --disable-sunaudio \
  120. --disable-win32waveout \
  121. --disable-tga \
  122. --disable-pnm \
  123. --disable-md5sum \
  124. --disable-liblzo \
  125. --disable-sdl \
  126. --disable-xinerama \
  127. --disable-vidix \
  128. --disable-gl \
  129. --extra-cflags="${EXTRA_CFLAGS}" \
  130. ${CONFIGURE_CPU_OPTS} \
  131. ${CONFIGURE_DEBUG} \
  132. ${CONFIGURE_DIRECTFB}
  133. XAKE_FLAGS+= AR="${TARGET_CROSS}ar" RANLIB="${TARGET_CROSS}ranlib"
  134. TARGET_LDFLAGS+= -lxvidcore -lX11 -lXext -lvorbis
  135. mplayer-install:
  136. ${INSTALL_DIR} ${IDIR_MPLAYER}/usr/bin
  137. ${CP} ${WRKINST}/usr/bin/mplayer ${IDIR_MPLAYER}/usr/bin
  138. include ${TOPDIR}/mk/pkg-bottom.mk