Github messages for voidlinux
 help / color / mirror / Atom feed
* [PR PATCH] x265: add options for altivec and assembly
@ 2019-05-07 15:05 voidlinux-github
  2019-05-07 15:09 ` [PR PATCH] [Updated] " voidlinux-github
                   ` (11 more replies)
  0 siblings, 12 replies; 13+ messages in thread
From: voidlinux-github @ 2019-05-07 15:05 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 564 bytes --]

There is a new pull request by q66 against master on the void-packages repository

https://github.com/void-ppc64/void-packages x265
https://github.com/void-linux/void-packages/pull/11540

x265: add options for altivec and assembly
This lets the user choose whether to build them in. Default to on for altivec on ppc64le (because that's always power8 or better) and off on ppc64 (because we support old hardware), assembly is on for ARM and x86 and off for everything else.

A patch file from https://github.com/void-linux/void-packages/pull/11540.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-x265-11540.patch --]
[-- Type: application/text/x-diff, Size: 1961 bytes --]

From d24dc353dd3f2cf7c7d8a3cc3bd5f5c39abaf7c2 Mon Sep 17 00:00:00 2001
From: q66 <daniel@octaforge.org>
Date: Tue, 7 May 2019 17:02:24 +0200
Subject: [PATCH] x265: add options for altivec and assembly

This lets the user choose whether to build them in. Default to
on for altivec on ppc64le (because that's always power8 or better)
and off on ppc64 (because we support old hardware), assembly is
on for ARM and x86 and off for everything else.
---
 srcpkgs/x265/template | 29 +++++++++++++++++++++++++++--
 1 file changed, 27 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/x265/template b/srcpkgs/x265/template
index 80561b477a4..0473181a111 100644
--- a/srcpkgs/x265/template
+++ b/srcpkgs/x265/template
@@ -1,7 +1,7 @@
 # Template file for 'x265'
 pkgname=x265
 version=3.0
-revision=1
+revision=2
 wrksrc="x265_${version}"
 build_wrksrc=source
 build_style=cmake
@@ -14,8 +14,33 @@ homepage="http://x265.org/"
 distfiles="https://bitbucket.org/multicoreware/x265/downloads/x265_${version}.tar.gz"
 checksum=c5b9fc260cabbc4a81561a448f4ce9cad7218272b4011feabc3a6b751b2f0662
 
+build_options="altivec assembly"
+
+desc_option_altivec="Enable AltiVec support on ppc64 (POWER8 and higher only)"
+desc_option_assembly="Enable assembly support on x86/ARM"
+
+case "$XBPS_TARGET_MACHINE" in
+	ppc64le*) build_options_default="altivec" ;;
+	x86_64*|i686*|arm*|aarch64*) build_options_default="assembly" ;;
+	*) ;;
+esac
+
 case "$XBPS_TARGET_MACHINE" in
-	ppc64|ppc64-musl) configure_args+=" -DCPU_POWER8=OFF -DENABLE_ALTIVEC=OFF";;
+	ppc64*)
+		# altivec does not build without power8 being enabled
+		if [ "$build_option_altivec" ]; then
+			configure_args+=" -DENABLE_ALTIVEC=ON -DCPU_POWER8=ON"
+		else
+			configure_args+=" -DENABLE_ALTIVEC=OFF -DCPU_POWER8=OFF"
+		fi
+		;;
+	*)
+		if [ "$build_option_assembly" ]; then
+			configure_args+=" -DENABLE_ASSEMBLY=ON"
+		else
+			configure_args+=" -DENABLE_ASSEMBLY=OFF"
+		fi
+		;;
 esac
 
 pre_configure() {

^ permalink raw reply	[flat|nested] 13+ messages in thread

end of thread, other threads:[~2019-05-07 16:07 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-05-07 15:05 [PR PATCH] x265: add options for altivec and assembly voidlinux-github
2019-05-07 15:09 ` [PR PATCH] [Updated] " voidlinux-github
2019-05-07 15:09 ` voidlinux-github
2019-05-07 15:10 ` voidlinux-github
2019-05-07 15:10 ` voidlinux-github
2019-05-07 15:22 ` voidlinux-github
2019-05-07 15:22 ` voidlinux-github
2019-05-07 15:24 ` voidlinux-github
2019-05-07 15:30 ` [PR PATCH] [Updated] " voidlinux-github
2019-05-07 15:30 ` voidlinux-github
2019-05-07 15:30 ` voidlinux-github
2019-05-07 15:45 ` voidlinux-github
2019-05-07 16:07 ` [PR PATCH] [Merged]: " voidlinux-github

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).