1
0
mirror of https://git.FreeBSD.org/ports.git synced 2024-12-27 05:10:36 +00:00

devel/opencl: don't include altivec.h

altivec.h shouldn't be included directly by users. It's managed with -maltivec / -mno-altivec compiler switches.

Including it causes compiler errors when using clang.

Already upstreamed.

PR:		247396
Approved by:	ohartman@zedat.fu-berlin.de (maintainer timeout)
MFH:		2020Q3 (fixes build of some other ports)
This commit is contained in:
Piotr Kubaj 2020-07-03 12:04:02 +00:00
parent e6075bc3dd
commit a746ee148f
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=541100
2 changed files with 14 additions and 1 deletions

View File

@ -3,7 +3,7 @@
PORTNAME= opencl
PORTVERSION= 2.2
PORTREVISION= 1
PORTREVISION= 2
CATEGORIES= devel
MAINTAINER= ohartman@zedat.fu-berlin.de

View File

@ -0,0 +1,13 @@
--- cl_platform.h.orig 2020-06-18 22:38:47 UTC
+++ cl_platform.h
@@ -429,7 +429,9 @@ typedef unsigned int cl_GLenum;
/* Define basic vector types */
#if defined( __VEC__ )
- #include <altivec.h> /* may be omitted depending on compiler. AltiVec spec provides no way to detect whether the header is required. */
+# if !defined(__clang__)
+ #include <altivec.h> /* may be omitted depending on compiler. AltiVec spec provides no way to detect whether the header is required. */
+# endif
typedef vector unsigned char __cl_uchar16;
typedef vector signed char __cl_char16;
typedef vector unsigned short __cl_ushort8;