Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
chromebrew
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
chromebrew
Commits
10d2b384
Commit
10d2b384
authored
Mar 10, 2021
by
satmandu
Committed by
GitHub
Mar 10, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Create intel_media_driver.rb
parent
d3fcc34a
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
61 additions
and
0 deletions
+61
-0
packages/intel_media_driver.rb
packages/intel_media_driver.rb
+61
-0
No files found.
packages/intel_media_driver.rb
0 → 100644
View file @
10d2b384
require
'package'
class
Intel_media_driver
<
Package
description
'The Intel(R) Media Driver for VAAPI is a new VA-API (Video Acceleration API) user mode driver supporting hardware accelerated decoding, encoding, and video post processing for GEN based graphics hardware.'
homepage
'https://github.com/intel/media-driver'
@_ver
=
'20.4.5'
version
@_ver
compatibility
'x86_64'
case
ARCH
when
'x86_64'
source_url
"https://github.com/intel/media-driver/archive/intel-media-
#{
@_ver
}
.tar.gz"
source_sha256
'3d856a963127ddd6690fc6dac521d7674947675d5f20452f1e6f45c0fc83f9e6'
depends_on
'gmmlib'
depends_on
'libva'
end
binary_url
({
x86_64:
'https://dl.bintray.com/chromebrew/chromebrew/intel_media_driver-20.4.5-chromeos-x86_64.tar.xz'
})
binary_sha256
({
x86_64:
'0710ad9dd76b97b62849cfe6179dae0e884e56c475332b03f889d5eaa121ffff'
})
def
self
.
preflight
abort
'Not an Intel processor, aborting.'
.
lightred
unless
`grep -c 'GenuineIntel' /proc/cpuinfo`
.
to_i
.
positive?
end
def
self
.
patch
system
"find . -type f -exec sed -e 's,LD_LIBRARY_PATH=,LD_LIBRARY_PATH=
#{
CREW_LIB_PREFIX
}
:,g' \
-e 's,-fstack-protector-all,-fno-stack-protector,g' \
-e 's,-fstack-protector,-fno-stack-protector,g' -i {} +"
end
def
self
.
build
FileUtils
.
mkdir
(
'builddir'
)
Dir
.
chdir
(
'builddir'
)
do
system
"env CFLAGS='-pipe -fno-stack-protector -U_FORTIFY_SOURCE -flto=auto -fuse-ld=gold' \
CXXFLAGS='-pipe -fno-stack-protector -U_FORTIFY_SOURCE -flto=auto -fuse-ld=gold' \
LDFLAGS='-fno-stack-protector -U_FORTIFY_SOURCE -flto=auto' \
cmake
#{
CREW_CMAKE_OPTIONS
}
../ -G Ninja"
end
system
'ninja -C builddir'
end
def
self
.
install
system
"DESTDIR=
#{
CREW_DEST_DIR
}
ninja -C builddir install"
end
def
self
.
postinstall
@_str
=
'export LIBVA_DRIVER_NAME=iHD'
if
`grep -c '
#{
@_str
}
'
#{
HOME
}
/.bashrc`
.
to_i
.
zero?
puts
'Performing env-setup...'
system
"echo '
#{
@_str
}
' >>
#{
HOME
}
/.bashrc"
puts
puts
'To complete the installation, execute the following:'
.
lightblue
puts
'source ~/.bashrc'
.
lightblue
puts
end
end
end
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment