summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--app-admin/eselect-xvmc/ChangeLog12
-rw-r--r--app-admin/eselect-xvmc/Manifest14
-rw-r--r--app-admin/eselect-xvmc/eselect-xvmc-0.3.ebuild20
-rw-r--r--app-admin/eselect-xvmc/files/eselect-xvmc-0.3.eselect189
4 files changed, 223 insertions, 12 deletions
diff --git a/app-admin/eselect-xvmc/ChangeLog b/app-admin/eselect-xvmc/ChangeLog
index 602233e5e96d..6ff162677475 100644
--- a/app-admin/eselect-xvmc/ChangeLog
+++ b/app-admin/eselect-xvmc/ChangeLog
@@ -1,6 +1,16 @@
# ChangeLog for app-admin/eselect-xvmc
# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/app-admin/eselect-xvmc/ChangeLog,v 1.17 2011/08/29 06:31:33 jer Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-admin/eselect-xvmc/ChangeLog,v 1.18 2011/08/29 21:02:02 cardoe Exp $
+
+*eselect-xvmc-0.3 (29 Aug 2011)
+
+ 29 Aug 2011; Doug Goldstein <cardoe@gentoo.org> +eselect-xvmc-0.3.ebuild,
+ +files/eselect-xvmc-0.3.eselect:
+ Bump version to support and fix the following:
+ * Newer Intel XvMC (i915). Based on patch from Otávio Cipriani
+ <otavio.n.cipriani@gmail.com> bug #378827
+ * Fix bad redirect. bug #314031
+ * Add unichrome support
29 Aug 2011; Jeroen Roovers <jer@gentoo.org> eselect-xvmc-0.2.ebuild:
Stable for HPPA (bug #376283).
diff --git a/app-admin/eselect-xvmc/Manifest b/app-admin/eselect-xvmc/Manifest
index 788d1afd360d..a4d81d17f385 100644
--- a/app-admin/eselect-xvmc/Manifest
+++ b/app-admin/eselect-xvmc/Manifest
@@ -1,16 +1,8 @@
------BEGIN PGP SIGNED MESSAGE-----
-Hash: SHA1
-
AUX eselect-xvmc-0.1.eselect 3835 RMD160 7852ee39c1c5b09490e097d086f7d42c0602b8c6 SHA1 52589b44cf25003c5c0fe59b713f2404816511b7 SHA256 76d3b735ac543994dfca3a3208b13dbe24f7a0463864e78950ac92b00b20726b
AUX eselect-xvmc-0.2.eselect 3859 RMD160 a616f5ebba7f48ab7adc1a35652607147b72be6f SHA1 fb3072269d85195c7050b3e0f5e78d7ccae7ef86 SHA256 5bb36b96de0068e3e15486015c809766d9bc0ef86f6fc0c81ad17e7f9db3b048
+AUX eselect-xvmc-0.3.eselect 3967 RMD160 5eca8df7ca3a3cf8fa3eedbb6b85b019746e5f52 SHA1 c53cb25a125cff907cb1fee793d11d0d1991dea1 SHA256 3e1f7fffbdcf112b832c87fd62149f712ec2fbb4ef51c76b2321d7e396b986fe
EBUILD eselect-xvmc-0.1.ebuild 622 RMD160 b4dc74a0470f67b1ff77a4190f355efc2e2a36de SHA1 a595b589abcd97285b86b7d5bb1fe3b417a2a7e9 SHA256 1399ae8c47b86427d0f00fc097d0731679c0fff33d73238f228476be76d740b9
EBUILD eselect-xvmc-0.2.ebuild 620 RMD160 20872f81a39a6621331f29fe5324e1206a8f8a92 SHA1 774ab9e4ebf620366ee8ead5fffb0e4cb4047164 SHA256 f2aa6e3ae0564cdcd78a1975d4c3e855b6cf992a93a7a0d6f593134b4b7be666
-MISC ChangeLog 2150 RMD160 dfff2dd4b630147d7746a3efd70eb579a8d21ab4 SHA1 771836df3d8e188a6f22dc8805b99481fc4d36a4 SHA256 2643ee59e4fac02ed2769986edf10ea81a429b22033e9bb22f422fd358c70ca0
+EBUILD eselect-xvmc-0.3.ebuild 635 RMD160 5d9f7064376a4ab13ab9710ea972f962afaf00ad SHA1 edda5bd9d0eb2630672cfb40056d7adc5bdcd0a0 SHA256 388fcba17d53cd9b634c44a9f6e18b5a7d0991db67fe792b67d54b1412c37d9c
+MISC ChangeLog 2517 RMD160 3f21e583ab10ca0d96b19e2acb081068508732a0 SHA1 f93db01be17662224b09ed7c9869153ceba632f4 SHA256 995e092a5fc04e9df9656e3ad79fffe834e3d92a9c998e6309098a16eac9cfa6
MISC metadata.xml 222 RMD160 d1a3fdf35754f259a53541e6f3fdf4685c621b4c SHA1 2669a0aa4051cb9d7eca5b8e5719f5039bf850b9 SHA256 2744b911fd4a893fc26fd4fbfcf4bad6189fbbd14a6b525c84c95d012e8c06da
------BEGIN PGP SIGNATURE-----
-Version: GnuPG v2.0.17 (GNU/Linux)
-
-iEYEARECAAYFAk5bMksACgkQVWmRsqeSphPbwgCcCzIhsrGwGczXwzC2ycy89XHq
-WyUAniLsSWHI3L3IUBeyoHp1AgMsvBrO
-=95BG
------END PGP SIGNATURE-----
diff --git a/app-admin/eselect-xvmc/eselect-xvmc-0.3.ebuild b/app-admin/eselect-xvmc/eselect-xvmc-0.3.ebuild
new file mode 100644
index 000000000000..4e28876fba03
--- /dev/null
+++ b/app-admin/eselect-xvmc/eselect-xvmc-0.3.ebuild
@@ -0,0 +1,20 @@
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/app-admin/eselect-xvmc/eselect-xvmc-0.3.ebuild,v 1.1 2011/08/29 21:02:02 cardoe Exp $
+
+DESCRIPTION="Manages XvMC implementations"
+HOMEPAGE="http://www.gentoo.org/"
+SRC_URI=""
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~sparc-fbsd ~x86-fbsd"
+IUSE=""
+
+DEPEND=""
+RDEPEND=">=app-admin/eselect-1.0.10"
+
+src_install() {
+ insinto /usr/share/eselect/modules
+ newins "${FILESDIR}"/${P}.eselect xvmc.eselect || die "newins failed"
+}
diff --git a/app-admin/eselect-xvmc/files/eselect-xvmc-0.3.eselect b/app-admin/eselect-xvmc/files/eselect-xvmc-0.3.eselect
new file mode 100644
index 000000000000..8e9659ae5600
--- /dev/null
+++ b/app-admin/eselect-xvmc/files/eselect-xvmc-0.3.eselect
@@ -0,0 +1,189 @@
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id: eselect-xvmc-0.3.eselect,v 1.1 2011/08/29 21:02:02 cardoe Exp $
+
+DESCRIPTION="Manage the XvMC implementation used by your system"
+MAINTAINER="cardoe@gentoo.org"
+SVN_DATE='$Date: 2011/08/29 21:02:02 $'
+VERSION=$(svn_date_to_version "${SVN_DATE}" )
+
+XVMCLIBS=(
+"libXvMCNVIDIA_dynamic.so.1"
+"libXvMC.so.1"
+"libviaXvMC.so.1"
+"libviaXvMCPro.so.1"
+"libchromeXvMC.so.1"
+"libchromeXvMCPro.so.1"
+"libXvMCVIA.so"
+"libXvMCVIAPro.so"
+"libI810XvMC.so.1"
+"/usr/lib/libIntelXvMC.so"
+"libAMDXvBA.so.1" )
+XVMCPRETTY=(
+"nvidia"
+"xorg-x11"
+"via"
+"via-pro"
+"openchrome"
+"openchrome-pro"
+"unichrome"
+"unichrome-pro"
+"intel-i815"
+"intel-i915"
+"ati" )
+
+get_implementation_indices() {
+ local ret n
+ for (( n = 0; n < ${#XVMCLIBS[@]}; ++n )); do
+ [[ -e "${ROOT}/usr/lib/${XVMCLIBS[n]}" ]] && ret+=($n)
+ done
+
+ echo ${ret[@]}
+}
+
+get_current_implementation_index() {
+ local n
+ if [[ -f "${ROOT}/etc/X11/XvMCConfig" ]]; then
+ local current=$(< "${ROOT}/etc/X11/XvMCConfig")
+ for (( n = 0; n < ${#XVMCLIBS[@]}; ++n )); do
+ if [[ "${XVMCLIBS[n]}" = "${current}" ]]; then
+ echo "${n}"
+ return
+ fi
+ done
+ fi
+
+ echo "-1"
+}
+
+set_new_implementation() {
+ echo -n "Switching to ${XVMCPRETTY[$1]} XvMC implementation..."
+ touch "${ROOT}/etc/X11/XvMCConfig" 2>&1 > /dev/null
+ if [[ $? -eq 0 ]]; then
+ echo "${XVMCLIBS[$1]}" > "${ROOT}/etc/X11/XvMCConfig"
+ chmod 644 "${ROOT}/etc/X11/XvMCConfig"
+ chown 0:0 "${ROOT}/etc/X11/XvMCConfig"
+ echo " done"
+ else
+ echo " failed!"
+ echo "Insufficient privileges"
+ fi
+}
+
+### list action
+
+## {{{ list stuff
+describe_list() {
+ echo "List Available XvMC implementations"
+}
+
+do_list() {
+ local output n
+ local avail=( $(get_implementation_indices) )
+ local current=$(get_current_implementation_index)
+ write_list_start "Available XvMC implementations ( $(highlight '*') is current ):"
+
+ if (( ${#avail[@]} )) ; then
+ for n in "${avail[@]}" ; do
+ output[n]="${XVMCPRETTY[n]}"
+ [[ ${current} -eq ${n} ]] && \
+ output[n]+=" $(highlight '*')"
+ done
+ write_numbered_list "${output[@]}"
+ else
+ write_kv_list_entry "(none found)" ""
+ fi
+
+ return 0
+}
+## }}}
+
+### show action
+
+## {{{ show stuff
+describe_show() {
+ echo "Print the current XvMC implementation."
+}
+
+do_show() {
+ local current=$(get_current_implementation_index)
+ write_list_start "Current XvMC implementation:"
+
+ if [[ ${current} -ne -1 ]]; then
+ echo "${XVMCPRETTY[current]}"
+ return 0
+ else
+ echo "(none)"
+ return 2
+ fi
+}
+## }}}
+
+### set action
+
+## {{{ set stuff
+describe_set() {
+ echo "Select the XvMC implementation"
+}
+
+describe_set_parameters() {
+ echo "<target>"
+}
+
+describe_set_options() {
+ echo "<target> : XvMC implementation to activate"
+ echo "--use-old : If an implementation is already set, use that one instead"
+}
+
+do_set() {
+ local current=$(get_current_implementation_index)
+ local avail=( $(get_implementation_indices) )
+ local n new action
+
+ while [[ ${#@} -gt 0 ]]; do
+ local opt=${1}
+ shift
+ case ${opt} in
+ --use-old)
+ if [[ ${current} -gt -1 ]]; then
+ (( ${current} < ${#XVMCPRETTY[@]} )) && action="old-implementation"
+ fi
+ ;;
+ *)
+ [[ -z ${action} ]] && action="set-implementation"
+
+ if is_number ${opt} ; then
+ new=${avail[opt - 1]}
+ if [[ -z ${new} ]]; then
+ die -q "Unrecognized option: ${opt}"
+ fi
+ elif has ${opt} ${XVMCPRETTY[@]}; then
+ for (( n = 0; n < ${#XVMCPRETTY[@]}; ++n )); do
+ [[ "${XVMCPRETTY[n]}" = "${opt}" ]] && new=${n}
+ done
+ else
+ die -q "Unrecognized option: ${opt}"
+ fi
+ ;;
+ esac
+ done
+
+ case ${action} in
+ old-implementation)
+ set_new_implementation ${current}
+ return $?
+ ;;
+ set-implementation)
+ if [[ -n ${new} ]]; then
+ set_new_implementation ${new}
+ return $?
+ else
+ die -q "Please specify an implementation to set"
+ fi
+ ;;
+ *)
+ die -q "Invalid usage of set action."
+ esac
+}
+
+# vim: ts=4 sw=4 noet fdm=marker