From 0465678fff90b0608866731fad4d895cd91cdec0 Mon Sep 17 00:00:00 2001 From: Bradley Sepos Date: Sun, 3 Jun 2018 16:21:09 -0400 Subject: contrib: build: Add AMF headers and --enable-vce. #1144. --- contrib/amf/module.defs | 21 +++++++++++++++++++++ contrib/amf/module.rules | 2 ++ contrib/ffmpeg/module.defs | 2 +- make/configure.py | 4 ++++ make/include/main.defs | 4 ++++ 5 files changed, 32 insertions(+), 1 deletion(-) create mode 100644 contrib/amf/module.defs create mode 100644 contrib/amf/module.rules diff --git a/contrib/amf/module.defs b/contrib/amf/module.defs new file mode 100644 index 000000000..de3bbf3f2 --- /dev/null +++ b/contrib/amf/module.defs @@ -0,0 +1,21 @@ +$(eval $(call import.MODULE.defs,AMF,amf)) +$(eval $(call import.CONTRIB.defs,AMF)) + +AMF.FETCH.url = https://download.handbrake.fr/contrib/AMF-1.4.7.0.tar.gz +AMF.FETCH.url += https://github.com/GPUOpen-LibrariesAndSDKs/AMF/archive/v1.4.7.0.tar.gz +AMF.FETCH.sha256 = ea91c8627fb16eaaf66c9c12b88a9fb8969879c244f782e807d2fb78f8f323bd +AMF.FETCH.basename = AMF-1.4.7.0.tar.gz + +AMF.CONFIGURE = $(TOUCH.exe) $@ +AMF.BUILD = $(TOUCH.exe) $@ + +define AMF.INSTALL + $(MKDIR.exe) -p $(CONTRIB.build/)include/AMF + $(CP.exe) -R $(AMF.EXTRACT.dir/)AMF/public/include/* $(CONTRIB.build/)include/AMF/ + $(TOUCH.exe) $@ +endef + +define AMF.UNINSTALL + $(RM.exe) -rf $(CONTRIB.build/)include/AMF + $(RM.exe) -f $(AMF.INSTALL.target) +endef diff --git a/contrib/amf/module.rules b/contrib/amf/module.rules new file mode 100644 index 000000000..a9c23ab4a --- /dev/null +++ b/contrib/amf/module.rules @@ -0,0 +1,2 @@ +$(eval $(call import.MODULE.rules,AMF)) +$(eval $(call import.CONTRIB.rules,AMF)) diff --git a/contrib/ffmpeg/module.defs b/contrib/ffmpeg/module.defs index 833fc9ad6..f3ae0b1dd 100644 --- a/contrib/ffmpeg/module.defs +++ b/contrib/ffmpeg/module.defs @@ -1,4 +1,4 @@ -__deps__ := YASM BZIP2 ZLIB FDKAAC LIBVPX LAME LIBOPUS LIBSPEEX XZ +__deps__ := YASM AMF BZIP2 ZLIB FDKAAC LIBVPX LAME LIBOPUS LIBSPEEX XZ ifeq (1,$(FEATURE.qsv)) __deps__ += LIBMFX endif diff --git a/make/configure.py b/make/configure.py index 638dfdc85..916a5c2b0 100644 --- a/make/configure.py +++ b/make/configure.py @@ -1304,6 +1304,9 @@ def createCLI(): h = IfHost( 'enable Intel Quick Sync Video (QSV) hardware acceleration. (Windows and Linux only)', '*-*-linux*', '*-*-mingw*', none=optparse.SUPPRESS_HELP ).value grp.add_option( '--enable-qsv', default=False, action='store_true', help=h ) + h = IfHost( 'enable AMD VCE hardware acceleration. (Windows only)', '*-*-mingw*', none=optparse.SUPPRESS_HELP ).value + grp.add_option( '--enable-vce', default=False, action='store_true', help=h ) + h = IfHost( 'enable x265 video encoder', '*-*-*', none=optparse.SUPPRESS_HELP ).value grp.add_option( '--enable-x265', dest="enable_x265", default=True, action='store_true', help=h ) grp.add_option( '--disable-x265', dest="enable_x265", action='store_false' ) @@ -1879,6 +1882,7 @@ int main() doc.add( 'FEATURE.fdk_aac', int( options.enable_fdk_aac )) doc.add( 'FEATURE.ffmpeg_aac', int( options.enable_ffmpeg_aac or build.system == 'mingw' )) doc.add( 'FEATURE.qsv', int( options.enable_qsv )) + doc.add( 'FEATURE.vce', int( options.enable_vce )) doc.add( 'FEATURE.xcode', int( not (Tools.xcodebuild.fail or options.disable_xcode or options.cross) )) doc.add( 'FEATURE.x265', int( options.enable_x265 )) diff --git a/make/include/main.defs b/make/include/main.defs index 8fd265dd3..edc80bd29 100644 --- a/make/include/main.defs +++ b/make/include/main.defs @@ -98,6 +98,10 @@ ifeq (1,$(FEATURE.qsv)) MODULES += contrib/libmfx endif +ifeq (1,$(FEATURE.vce)) + MODULES += contrib/amf +endif + ifneq (,$(filter $(BUILD.system),darwin)) MODULES += contrib/xz endif -- cgit v1.2.3