Makefile 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899
  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:= ffmpeg
  5. PKG_VERSION:= 0.6.1
  6. PKG_RELEASE:= 1
  7. PKG_MD5SUM:= 4f5d732d25eedfb072251b5314ba2093
  8. PKG_DESCR:= record, convert and stream audio & video
  9. PKG_SECTION:= libs
  10. PKG_DEPENDS:= libfaad2
  11. PKG_BUILDDEP:= faad2
  12. PKG_URL:= http://www.ffmpeg.org/
  13. PKG_SITES:= http://www.ffmpeg.org/releases/
  14. PKG_SUBPKGS:= FFMPEG FFPLAY
  15. PKGSD_FFPLAY:= ffmpeg based video player
  16. PKGSC_FFPLAY:= multimedia
  17. PKGSS_FFPLAY:= libsdl libpthread ffmpeg
  18. PKGSB_FFPLAY:= sdl
  19. DISTFILES:= ${PKG_NAME}-${PKG_VERSION}.tar.bz2
  20. include ${TOPDIR}/mk/package.mk
  21. $(eval $(call PKG_template,FFMPEG,${PKG_NAME},${PKG_VERSION}-${PKG_RELEASE},${PKG_DEPENDS},${PKG_DESCR},${PKG_SECTION}))
  22. $(eval $(call PKG_template,FFPLAY,ffplay,${PKG_VERSION}-${PKG_RELEASE},${PKGSS_FFPLAY},${PKGSD_FFPLAY},${PKGSC_FFPLAY}))
  23. SUB_INSTALLS-y:=
  24. SUB_INSTALLS-m:=
  25. SUB_INSTALLS-${ADK_PACKAGE_FFPLAY}+= ffplay-install
  26. ifeq ($(ADK_TARGET),alix)
  27. CONFIGURE_CPU_OPTS:= --disable-ssse3 \
  28. --disable-sse \
  29. --enable-amd3dnow \
  30. --enable-amd3dnowext \
  31. --enable-mmx \
  32. --enable-mmx2
  33. else ifeq ($(ADK_HARDWARE_IBM_X40),y)
  34. CONFIGURE_CPU_OPTS:= --disable-ssse3 \
  35. --enable-sse \
  36. --disable-amd3dnow \
  37. --disable-amd3dnowext \
  38. --enable-mmx \
  39. --enable-mmx2
  40. else
  41. CONFIGURE_CPU_OPTS:= --disable-ssse3 \
  42. --disable-sse \
  43. --disable-amd3dnow \
  44. --disable-amd3dnowext \
  45. --disable-mmx \
  46. --disable-mmx2
  47. endif
  48. # gcc 4.5 produces internal compiler error with -Os
  49. #TCFLAGS:=$(subst Os,O2,$(TCFLAGS))
  50. CONFIG_STYLE:= minimal
  51. CONFIGURE_ARGS:= --prefix=/usr \
  52. --target-os=linux \
  53. --arch=${CPU_ARCH} \
  54. --enable-cross-compile \
  55. --sysroot=${STAGING_DIR} \
  56. --source-path=${WRKSRC} \
  57. --cross-prefix=${TARGET_CROSS} \
  58. --cc=$(TARGET_CC) \
  59. --host-cc=$(HOSTCC) \
  60. --disable-doc \
  61. --disable-debug \
  62. --disable-optimizations \
  63. --disable-stripping \
  64. --enable-shared \
  65. --enable-static \
  66. --disable-ffmpeg \
  67. --disable-ffserver \
  68. --enable-ffplay \
  69. --enable-gpl \
  70. --enable-swscale \
  71. --enable-postproc \
  72. --enable-libfaad \
  73. ${CONFIGURE_CPU_OPTS}
  74. post-install: ${SUB_INSTALLS-m} ${SUB_INSTALLS-y}
  75. ${INSTALL_DIR} ${IDIR_FFMPEG}/usr/lib
  76. ${CP} ${WRKINST}/usr/lib/libavdevice.so* ${IDIR_FFMPEG}/usr/lib
  77. ${CP} ${WRKINST}/usr/lib/libavformat.so* ${IDIR_FFMPEG}/usr/lib
  78. ${CP} ${WRKINST}/usr/lib/libavcodec.so* ${IDIR_FFMPEG}/usr/lib
  79. ${CP} ${WRKINST}/usr/lib/libavutil.so* ${IDIR_FFMPEG}/usr/lib
  80. ${CP} ${WRKINST}/usr/lib/libpostproc.so* ${IDIR_FFMPEG}/usr/lib
  81. ${CP} ${WRKINST}/usr/lib/libswscale.so* ${IDIR_FFMPEG}/usr/lib
  82. ffplay-install:
  83. ${INSTALL_DIR} ${IDIR_FFPLAY}/usr/bin
  84. ${INSTALL_BIN} ${WRKINST}/usr/bin/ffplay ${IDIR_FFPLAY}/usr/bin
  85. include ${TOPDIR}/mk/pkg-bottom.mk