From: ludo@gnu.org (Ludovic Courtès)
To: Fis Trivial <ybbs.daans@hotmail.com>
Cc: "31436@debbugs.gnu.org" <31436-done@debbugs.gnu.org>
Subject: bug#31436: [PATCH 3/3] gnu: Add beignet.
Date: Tue, 26 Jun 2018 23:00:16 +0200 [thread overview]
Message-ID: <87vaa51cwv.fsf@gnu.org> (raw)
In-Reply-To: <SN1PR16MB051193DD65457EAA67E270A192490@SN1PR16MB0511.namprd16.prod.outlook.com> (Fis Trivial's message of "Tue, 26 Jun 2018 19:40:31 +0000")
[-- Attachment #1: Type: text/plain, Size: 1197 bytes --]
Fis Trivial <ybbs.daans@hotmail.com> skribis:
> * gnu/packages/opencl.scm (beignet): New variable.
> * gnu/packages/patches/beignet-correct-paths.patch: New file.
> * gnu/local.mk: Add it.
Applied with the changes below.
There’s one issue, though: the ‘beignet.pch’ file is not bit
reproducible, as can be seen when running ‘guix build beignet --check
-K’. The file is generated by Clang:
--8<---------------cut here---------------start------------->8---
ADD_CUSTOM_COMMAND(OUTPUT ${OCL_OBJECT_DIR}/beignet.local.pch
COMMAND mkdir -p ${OCL_OBJECT_DIR}
COMMAND ${CLANG_EXECUTABLE} -cc1 ${CLANG_OCL_FLAGS} -I ${OCL_OBJECT_DIR}/include/ -emit-pch -x cl ${OCL_OBJECT_DIR}/include/ocl.h -o ${OCL_OBJECT_DIR}/beignet.local.pch
DEPENDS ${OCL_HEADER_FILES}
COMMENT "Generate the pch file: ${OCL_OBJECT_DIR}/beignet.local.pch"
)
--8<---------------cut here---------------end--------------->8---
This may be a Clang/LLVM issue not specific to Beignet, and we should
ask the Clang/LLVM people about it.
Thanks for following up on this patch series! I’m closing it now, but
hopefully later on we’ll have POCL as well.
Thanks,
Ludo’.
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: Type: text/x-patch, Size: 4638 bytes --]
diff --git a/gnu/local.mk b/gnu/local.mk
index b400c9f18..08888da35 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -583,7 +583,7 @@ dist_patch_DATA = \
%D%/packages/patches/azr3.patch \
%D%/packages/patches/bash-completion-directories.patch \
%D%/packages/patches/bazaar-CVE-2017-14176.patch \
- %D%/packages/patches/beignet-correct-paths.patch \
+ %D%/packages/patches/beignet-correct-file-names.patch \
%D%/packages/patches/bind-CVE-2018-5738.patch \
%D%/packages/patches/binutils-aarch64-symbol-relocation.patch \
%D%/packages/patches/binutils-loongson-workaround.patch \
diff --git a/gnu/packages/opencl.scm b/gnu/packages/opencl.scm
index b209d361d..644cd95e9 100644
--- a/gnu/packages/opencl.scm
+++ b/gnu/packages/opencl.scm
@@ -224,7 +224,12 @@ the system.")
(sha256
(base32
"18r0lq3dkd4yn6bxa45s2lrr9cjbg70nr2nn6xablvgqwzw0jb0r"))
- (patches (search-patches "beignet-correct-paths.patch"))))
+ (patches (search-patches "beignet-correct-file-names.patch"))
+ (modules '((guix build utils)))
+ (snippet
+ ;; There's a suspicious .isa binary file under kernels/.
+ ;; Remove it.
+ '(for-each delete-file (find-files "." "\\.isa$")))))
(native-inputs `(("pkg-config" ,pkg-config)
("python" ,python)))
(inputs `(("clang@3.7" ,clang-3.7)
@@ -251,13 +256,15 @@ the system.")
(assoc-ref %build-inputs "clang@3.7") "/lib")
"-DENABLE_GL_SHARING=ON"
"-DEXPERIMENTAL_DOUBLE=ON")
+
#:phases
(modify-phases %standard-phases
(add-after 'install 'remove-headers
(lambda* (#:key outputs #:allow-other-keys)
(let ((out (assoc-ref outputs "out")))
(delete-file-recursively
- (string-append out "/include")))))
+ (string-append out "/include"))
+ #t)))
(add-after 'remove-headers 'install-kernels
(lambda* (#:key outputs #:allow-other-keys)
(let* ((out (assoc-ref outputs "out"))
@@ -265,14 +272,19 @@ the system.")
(source-dir (string-append
builddir
"/../beignet-Release_v1.3.2/kernels")))
- (copy-recursively source-dir (string-append
- out
- "/lib/beignet/kernels"))))))
+ (copy-recursively source-dir
+ (string-append out "/lib/beignet/kernels"))
+ #t))))
;; Beignet tries to find GPU when running tests, which is not available
;; during build.
#:tests? #f))
(home-page "https://wiki.freedesktop.org/www/Software/Beignet/")
- (synopsis "Intel's OpenCL framework")
- (description "Intel's OpenCL framework that works with Intel IvyBridge GPUs
-and above.")
- (license license:gpl2)))
+ (synopsis "OpenCL framework for Intel GPUs")
+ (description
+ "Beignet is an implementation of the OpenCL specification. This code
+base contains the code to run OpenCL programs on Intel GPUs---IvyBridge,
+Haswell, Skylake, Apollolake, etc. It defines and implements the OpenCL host
+functions required to initialize the device, create the command queues, the
+kernels and the programs, and run them on the GPU. The code also contains a
+back-end for the LLVM compiler framework.")
+ (license license:lgpl2.1+)))
diff --git a/gnu/packages/patches/beignet-correct-paths.patch b/gnu/packages/patches/beignet-correct-file-names.patch
similarity index 73%
rename from gnu/packages/patches/beignet-correct-paths.patch
rename to gnu/packages/patches/beignet-correct-file-names.patch
index 96f15d782..2c5d0bbae 100644
--- a/gnu/packages/patches/beignet-correct-paths.patch
+++ b/gnu/packages/patches/beignet-correct-file-names.patch
@@ -1,14 +1,5 @@
-From 0ba525465782ec3fd6484b7483941344f293d3ab Mon Sep 17 00:00:00 2001
-From: fis <ybbs.daans@hotmail.com>
-Date: Sun, 8 Apr 2018 02:14:44 +0800
-Subject: [PATCH] Correct paths.
-
-* CMake/FindLLVM.cmake (CLANG_LIBRARY_DIR): New vairable.
-* CMakelists: Let cmake figure out where to install icd file.
----
- CMake/FindLLVM.cmake | 2 +-
- CMakeLists.txt | 2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
+Help CMake find Clang's libraries.
+Have it install the ICD file in the right place.
diff --git a/CMake/FindLLVM.cmake b/CMake/FindLLVM.cmake
index 5457f248..e8e8f94a 100644
prev parent reply other threads:[~2018-06-26 21:01 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-05-12 19:46 [bug#31436] [PATCH 0/6] gnu: Add opencl related packages Fis Trivial
2018-05-12 19:49 ` [bug#31436] [PATCH 1/6] gnu: Add opencl-headers Fis Trivial
2018-05-12 19:49 ` [bug#31436] [PATCH 2/6] gnu: Add opencl-clhpp Fis Trivial
2018-05-12 19:50 ` [bug#31436] [PATCH 3/6] gnu: Add ocl-icd Fis Trivial
2018-05-12 19:50 ` [bug#31436] [PATCH 4/6] gnu: Add beignet Fis Trivial
2018-05-12 19:51 ` [bug#31436] [PATCH 5/6] gnu: Add clinfo Fis Trivial
2018-05-12 19:52 ` [bug#31436] [PATCH 6/6] gnu: Add pocl Fis Trivial
2018-05-26 17:42 ` [bug#31436] [PATCH 0/6] gnu: Add opencl related packages Fis Trivial
2018-05-28 12:51 ` Ludovic Courtès
2018-06-25 20:22 ` Ludovic Courtès
2018-06-25 20:58 ` Fis Trivial
2018-06-26 13:44 ` Ludovic Courtès
2018-06-26 18:49 ` Fis Trivial
2018-06-26 19:37 ` [bug#31436] [PATCH 0/3] Resend some opencl packages Fis Trivial
2018-06-26 19:39 ` [bug#31436] [PATCH 1/3] gnu: Add ocl-icd Fis Trivial
2018-06-26 20:26 ` Ludovic Courtès
2018-06-26 20:57 ` Fis Trivial
2018-06-26 19:39 ` [bug#31436] [PATCH 2/3] gnu: Add clinfo Fis Trivial
2018-06-26 20:32 ` Ludovic Courtès
2018-06-26 19:40 ` [bug#31436] [PATCH 3/3] gnu: Add beignet Fis Trivial
2018-06-26 21:00 ` Ludovic Courtès [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87vaa51cwv.fsf@gnu.org \
--to=ludo@gnu.org \
--cc=31436-done@debbugs.gnu.org \
--cc=ybbs.daans@hotmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/guix.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.