python/cmd2: update to 2.5.6
[oi-userland.git] / components / encumbered / ffmpeg-6 / Makefile
blobe1dae1e8a8b921da575e27ac002c7c4f6292e8dc
2 # This file and its contents are supplied under the terms of the
3 # Common Development and Distribution License ("CDDL"), version 1.0.
4 # You may only use this file in accordance with the terms of version
5 # 1.0 of the CDDL.
7 # A full copy of the text of the CDDL should have accompanied this
8 # source. A copy of the CDDL is also available via the Internet at
9 # http://www.illumos.org/license/CDDL.
13 # Copyright 2015 Alexander Pyhalov
14 # Copyright 2023 Niklas Poslovski
17 USE_PARALLEL_BUILD= yes
18 include ../../../make-rules/shared-macros.mk
20 COMPONENT_NAME= ffmpeg
21 COMPONENT_VERSION= 6.1.2
22 COMPONENT_SUMMARY= A very fast video and audio converter (runtime libraries)
23 COMPONENT_SRC= $(COMPONENT_NAME)-$(HUMAN_VERSION)
24 COMPONENT_ARCHIVE= $(COMPONENT_SRC).tar.xz
25 COMPONENT_ARCHIVE_HASH= sha256:3b624649725ecdc565c903ca6643d41f33bd49239922e45c9b1442c63dca4e38
26 COMPONENT_PROJECT_URL= https://www.ffmpeg.org
27 COMPONENT_ARCHIVE_URL= $(COMPONENT_PROJECT_URL)/releases/$(COMPONENT_ARCHIVE)
28 COMPONENT_FMRI= library/ffmpeg-6
29 COMPONENT_CLASSIFICATION= System/Multimedia Libraries
30 COMPONENT_LICENSE= LGPLv2.1+, GPLv2, MIT/X11/BSD-style
32 COMPONENT_FMRI.developer = developer/ffmpeg-6
33 COMPONENT_SUMMARY.developer = $(COMPONENT_SUMMARY) (development files)
35 include $(WS_MAKE_RULES)/encumbered.mk
36 include $(WS_MAKE_RULES)/common.mk
38 CFLAGS += -I/usr/X11/include
39 CFLAGS += $(CPP_LARGEFILES)
41 CPPFLAGS += $($(COMPILER)_C99_ENABLE)
43 CONFIGURE_OPTIONS = --prefix=$(CONFIGURE_PREFIX)
44 CONFIGURE_OPTIONS += --mandir=$(CONFIGURE_MANDIR)
45 CONFIGURE_OPTIONS += --bindir=$(CONFIGURE_BINDIR.$(BITS))
46 CONFIGURE_OPTIONS += --libdir=$(CONFIGURE_LIBDIR.$(BITS))
47 CONFIGURE_OPTIONS += --cc=$(CC)
48 CONFIGURE_OPTIONS += --enable-runtime-cpudetect
49 CONFIGURE_OPTIONS += --enable-mmx --enable-sse --enable-ssse3
50 # force additional new CPU instruction enablement
51 CONFIGURE_OPTIONS += --enable-avx
52 CONFIGURE_OPTIONS += --disable-debug
53 CONFIGURE_OPTIONS += --enable-nonfree
54 CONFIGURE_OPTIONS += --enable-gpl
55 CONFIGURE_OPTIONS += --enable-postproc
56 CONFIGURE_OPTIONS += --enable-avfilter
57 CONFIGURE_OPTIONS += --enable-swscale
58 CONFIGURE_OPTIONS += --enable-libgsm
59 CONFIGURE_OPTIONS += --enable-libxvid
60 CONFIGURE_OPTIONS += --enable-libx264
61 CONFIGURE_OPTIONS += --enable-libx265
62 CONFIGURE_OPTIONS += --enable-libdav1d
63 CONFIGURE_OPTIONS += --enable-libwebp
64 # Don't enable it, resulting binary is not
65 # redistributable
66 #CONFIGURE_OPTIONS += --enable-libfaac
67 CONFIGURE_OPTIONS += --enable-libtheora
68 CONFIGURE_OPTIONS += --enable-libmp3lame
69 CONFIGURE_OPTIONS += --enable-libvorbis
70 CONFIGURE_OPTIONS += --enable-libvpx
71 # x11grab has been replaced by the x11xcb options
72 #CONFIGURE_OPTIONS += --enable-x11grab
73 CONFIGURE_OPTIONS += --enable-libxcb
74 CONFIGURE_OPTIONS += --enable-libspeex
75 CONFIGURE_OPTIONS += --enable-pthreads
76 # Incompatible with GPLv2
77 #CONFIGURE_OPTIONS += --enable-libopencore-amrnb
78 CONFIGURE_OPTIONS += --enable-libass
79 CONFIGURE_OPTIONS += --enable-openssl
80 CONFIGURE_OPTIONS += --enable-openal
81 # don't enable avresample any more, it's long-deprecated. Use swresample
82 # instead
83 #CONFIGURE_OPTIONS += --enable-avresample
84 CONFIGURE_OPTIONS += --enable-swresample
85 # Incompatible with GPLv2
86 #CONFIGURE_OPTIONS += --enable-libopencore-amrwb
87 # libschroedinger support was removed in 3.4.x
88 #CONFIGURE_OPTIONS += --enable-libschroedinger
89 CONFIGURE_OPTIONS += --enable-libopenjpeg
90 CONFIGURE_OPTIONS += --enable-librtmp
91 CONFIGURE_OPTIONS += --enable-vdpau
92 CONFIGURE_OPTIONS += --enable-shared
93 CONFIGURE_OPTIONS += --disable-static
94 # these tests cause problems, skip them
95 CONFIGURE_OPTIONS += --ignore-tests=source
97 CONFIGURE_ENV += CPPFLAGS="$(CPPFLAGS)"
99 # We do not need documentation for old ffmpeg version
100 CONFIGURE_OPTIONS += --disable-doc
101 # Install ffmpeg-6 development support into dedicated directories
102 CONFIGURE_OPTIONS += --incdir=$(CONFIGURE_PREFIX)/include/ffmpeg-6
103 CONFIGURE_OPTIONS += --pkgconfigdir=$(PKG_CONFIG_PATH.$(BITS))/ffmpeg-6
104 # We do not need programs in /usr/bin. We cannot use --disable-programs
105 # configure option because testing needs the ffmpeg binary.
106 COMPONENT_POST_INSTALL_ACTION += $(RM) -r $(PROTOUSRBINDIR) ;
107 # We do not need examples and other share files needed for programs
108 COMPONENT_POST_INSTALL_ACTION += $(RM) -r $(PROTOUSRSHAREDIR)/ffmpeg ;
110 COMPONENT_TEST_ENV += PATH=$(PROTO_DIR)/$(CONFIGURE_BINDIR.$(BITS)):$(PATH)
111 COMPONENT_TEST_ENV += LD_LIBRARY_PATH=$(PROTO_DIR)/$(CONFIGURE_LIBDIR.$(BITS))
113 COMPONENT_TEST_TRANSFORMS+= '-n -e "/TEST/p" -e "/^IGNORE/p" '
115 # You must run the 'install' target before running the test
116 # suite, as we use binaries and libraries from $(PROTO_DIR) for tests
117 # to reduce issues with all the test binaries not being able to find
118 # ffmpeg's libraries.
119 test: install $(TEST_64)
121 # Auto-generated dependencies
122 REQUIRED_PACKAGES += $(OPENSSL_PKG)
123 REQUIRED_PACKAGES += audio/lame
124 REQUIRED_PACKAGES += codec/dav1d
125 REQUIRED_PACKAGES += codec/libtheora
126 REQUIRED_PACKAGES += codec/speex
127 REQUIRED_PACKAGES += compress/bzip2
128 REQUIRED_PACKAGES += compress/xz
129 REQUIRED_PACKAGES += image/library/openjpeg
130 REQUIRED_PACKAGES += library/audio/libgsm
131 REQUIRED_PACKAGES += library/audio/openal
132 REQUIRED_PACKAGES += library/graphics/libvdpau
133 REQUIRED_PACKAGES += library/libvorbis
134 REQUIRED_PACKAGES += library/libwebp
135 REQUIRED_PACKAGES += library/sdl2
136 REQUIRED_PACKAGES += library/video/libass
137 REQUIRED_PACKAGES += library/video/libvpx
138 REQUIRED_PACKAGES += library/video/x264
139 REQUIRED_PACKAGES += library/video/x265
140 REQUIRED_PACKAGES += library/video/xvid
141 REQUIRED_PACKAGES += library/zlib
142 REQUIRED_PACKAGES += system/library
143 REQUIRED_PACKAGES += system/library/math
144 REQUIRED_PACKAGES += video/rtmpdump
145 REQUIRED_PACKAGES += x11/library/libx11
146 REQUIRED_PACKAGES += x11/library/libxcb
147 REQUIRED_PACKAGES += x11/library/libxext
148 REQUIRED_PACKAGES += x11/library/libxv