public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Conrad Kostecki" <conikost@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-util/intel-graphics-compiler/files/, dev-util/intel-graphics-compiler/
Date: Sat, 28 Aug 2021 01:57:44 +0000 (UTC)	[thread overview]
Message-ID: <1630115818.64d9c9ea8fa22a2160a4479c940bcc691f322d33.conikost@gentoo> (raw)

commit:     64d9c9ea8fa22a2160a4479c940bcc691f322d33
Author:     Conrad Kostecki <conikost <AT> gentoo <DOT> org>
AuthorDate: Sat Aug 28 01:47:50 2021 +0000
Commit:     Conrad Kostecki <conikost <AT> gentoo <DOT> org>
CommitDate: Sat Aug 28 01:56:58 2021 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=64d9c9ea

dev-util/intel-graphics-compiler: update llvm handling

The current llvm handling was broken and the wrong cmake variables were
used to setup the toolchain, which has been now corrected.

Package-Manager: Portage-3.0.22, Repoman-3.0.3
Signed-off-by: Conrad Kostecki <conikost <AT> gentoo.org>

 ...s-compiler-1.0.8365-cmake-minimum-version.patch | 43 +++++++++++++
 ...-graphics-compiler-1.0.8365-cmake-project.patch | 27 +++++++++
 ...el-graphics-compiler-1.0.8365-disable-git.patch | 37 ++++++++++++
 .../intel-graphics-compiler-1.0.8365-r1.ebuild     | 70 ++++++++++++++++++++++
 4 files changed, 177 insertions(+)

diff --git a/dev-util/intel-graphics-compiler/files/intel-graphics-compiler-1.0.8365-cmake-minimum-version.patch b/dev-util/intel-graphics-compiler/files/intel-graphics-compiler-1.0.8365-cmake-minimum-version.patch
new file mode 100644
index 00000000000..dcf762872a1
--- /dev/null
+++ b/dev-util/intel-graphics-compiler/files/intel-graphics-compiler-1.0.8365-cmake-minimum-version.patch
@@ -0,0 +1,43 @@
+From 419ae48d0e2cb932a6618e9012b4164e93e58279 Mon Sep 17 00:00:00 2001
+From: Conrad Kostecki <conikost@gentoo.org>
+Date: Sat, 28 Aug 2021 00:16:23 +0200
+Subject: [PATCH] IGC: CMakeLists: adjust minimum_version
+
+As CMake warns about possible compatibility problems,
+the minimum version should be updated, as it should be compatible.
+
+Otherwise, the warning is printed:
+Compatibility with CMake < 2.8.12 will be removed from a future version of CMake.
+
+Signed-off-by: Conrad Kostecki <conrad@kostecki.com>
+---
+ visa/CMakeLists.txt                             | 2 +-
+ visa/iga/GEDLibrary/GED_external/CMakeLists.txt | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/visa/CMakeLists.txt b/visa/CMakeLists.txt
+index c70d80d5726..3e54bd93079 100644
+--- a/visa/CMakeLists.txt
++++ b/visa/CMakeLists.txt
+@@ -68,7 +68,7 @@ if(WIN32)
+   cmake_minimum_required(VERSION 3.1)
+   cmake_policy(SET CMP0043 OLD)
+ else()
+-  cmake_minimum_required(VERSION 2.8)
++  cmake_minimum_required(VERSION 2.8.12)
+ endif(WIN32)
+ 
+ # In the case where this is the IGC build we need to add a dummy custom target check_headers
+diff --git a/visa/iga/GEDLibrary/GED_external/CMakeLists.txt b/visa/iga/GEDLibrary/GED_external/CMakeLists.txt
+index d3011ddae6a..e40313fc194 100644
+--- a/visa/iga/GEDLibrary/GED_external/CMakeLists.txt
++++ b/visa/iga/GEDLibrary/GED_external/CMakeLists.txt
+@@ -10,7 +10,7 @@
+ if(WIN32)
+     cmake_minimum_required(VERSION 3.1)
+ else()
+-    cmake_minimum_required(VERSION 2.8)
++    cmake_minimum_required(VERSION 2.8.12)
+ endif(WIN32)
+ 
+ project(GEDLibrary)

diff --git a/dev-util/intel-graphics-compiler/files/intel-graphics-compiler-1.0.8365-cmake-project.patch b/dev-util/intel-graphics-compiler/files/intel-graphics-compiler-1.0.8365-cmake-project.patch
new file mode 100644
index 00000000000..92683cdfb94
--- /dev/null
+++ b/dev-util/intel-graphics-compiler/files/intel-graphics-compiler-1.0.8365-cmake-project.patch
@@ -0,0 +1,27 @@
+From f883dc94360af37ce85c8a9215c861fdc0431dee Mon Sep 17 00:00:00 2001
+From: Conrad Kostecki <conikost@gentoo.org>
+Date: Sat, 28 Aug 2021 00:09:09 +0200
+Subject: [PATCH] IGC: CMakeLists: add project
+
+If project is not added, CMake will warn about it:
+No project() command is present. The top-level CMakeLists.txt file
+must contain a literal, direct call to the project() command.
+
+Signed-off-by: Conrad Kostecki <conrad@kostecki.com>
+---
+ CMakeLists.txt | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index bfbcf52eca4..5b04555b21f 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -8,6 +8,8 @@
+ 
+ cmake_minimum_required(VERSION 3.13.4 FATAL_ERROR)
+ 
++project(IGC)
++
+ add_subdirectory(IGC)
+ 
+ list(APPEND IGC__IGC_TARGETS "igc_dll")

diff --git a/dev-util/intel-graphics-compiler/files/intel-graphics-compiler-1.0.8365-disable-git.patch b/dev-util/intel-graphics-compiler/files/intel-graphics-compiler-1.0.8365-disable-git.patch
new file mode 100644
index 00000000000..4a9a8988c5b
--- /dev/null
+++ b/dev-util/intel-graphics-compiler/files/intel-graphics-compiler-1.0.8365-disable-git.patch
@@ -0,0 +1,37 @@
+From d0f801a178755504c2f8956841823b2aa6a124c4 Mon Sep 17 00:00:00 2001
+From: Conrad Kostecki <conikost@gentoo.org>
+Date: Sat, 28 Aug 2021 00:57:59 +0200
+Subject: [PATCH] IGC: CMakeLists: drop git
+
+Dropping git, as we don't have any git release.
+
+Signed-off-by: Conrad Kostecki <conrad@kostecki.com>
+---
+ visa/iga/IGALibrary/CMakeLists.txt | 11 -----------
+ 1 file changed, 11 deletions(-)
+
+diff --git a/visa/iga/IGALibrary/CMakeLists.txt b/visa/iga/IGALibrary/CMakeLists.txt
+index 061476d94..2fd44807c 100644
+--- a/visa/iga/IGALibrary/CMakeLists.txt
++++ b/visa/iga/IGALibrary/CMakeLists.txt
+@@ -14,17 +14,6 @@ set(CMAKE_CXX_STANDARD 14)
+ 
+ ##############################################
+ # compute the version string from the git repo
+-execute_process(
+-    COMMAND git rev-parse --short HEAD
+-    OUTPUT_VARIABLE GIT_COMMIT
+-    OUTPUT_STRIP_TRAILING_WHITESPACE
+-    WORKING_DIRECTORY ${CMAKE_SOURCE_DIR})
+-#
+-execute_process(
+-    COMMAND git diff-index --quiet HEAD --
+-    RESULT_VARIABLE GIT_DIRTY
+-    WORKING_DIRECTORY ${CMAKE_SOURCE_DIR})
+-
+ set(IGA_VERSION_SUFFIX "")
+ if(GIT_COMMIT)
+     set(IGA_VERSION_DIRTY_TAG "")
+-- 
+2.33.0
+

diff --git a/dev-util/intel-graphics-compiler/intel-graphics-compiler-1.0.8365-r1.ebuild b/dev-util/intel-graphics-compiler/intel-graphics-compiler-1.0.8365-r1.ebuild
new file mode 100644
index 00000000000..c883ba1d6b6
--- /dev/null
+++ b/dev-util/intel-graphics-compiler/intel-graphics-compiler-1.0.8365-r1.ebuild
@@ -0,0 +1,70 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+CMAKE_BUILD_TYPE="Release"
+LLVM_MAX_SLOT="10"
+MY_PN="igc"
+MY_P="${MY_PN}-${PV}"
+
+inherit cmake flag-o-matic llvm
+
+DESCRIPTION="LLVM-based OpenCL compiler for OpenCL targetting Intel Gen graphics hardware"
+HOMEPAGE="https://github.com/intel/intel-graphics-compiler"
+SRC_URI="https://github.com/intel/${PN}/archive/${MY_P}.tar.gz -> ${P}.tar.gz"
+S="${WORKDIR}/${PN}-${MY_P}"
+
+LICENSE="MIT"
+SLOT="0"
+KEYWORDS="~amd64"
+IUSE="debug"
+
+DEPEND="
+	dev-libs/opencl-clang:${LLVM_MAX_SLOT}=
+	sys-devel/llvm:${LLVM_MAX_SLOT}=
+"
+
+RDEPEND="${DEPEND}"
+
+BDEPEND=">=sys-devel/lld-${LLVM_MAX_SLOT}"
+
+PATCHES=(
+	"${FILESDIR}/${PN}-1.0.9-no_Werror.patch"
+	"${FILESDIR}/${PN}-1.0.8173-opencl-clang_version.patch"
+	"${FILESDIR}/${PN}-1.0.8173-fix-missing-limits.patch"
+	"${FILESDIR}/${PN}-1.0.8365-disable-git.patch"
+	"${FILESDIR}/${PN}-1.0.8365-cmake-project.patch"
+	"${FILESDIR}/${PN}-1.0.8365-cmake-minimum-version.patch"
+)
+
+src_configure() {
+	# Since late March 2020 cmake.eclass does not set -DNDEBUG any more,
+	# and the way IGC uses this definition causes problems for some users.
+	# See bug #718824 for more information.
+	! use debug && append-cppflags -DNDEBUG
+
+	local mycmakeargs=(
+		# Those options are ensuring, that we are using
+		# the system LLVM with the correct slot.
+		-DCCLANG_SONAME_VERSION="${LLVM_MAX_SLOT}"
+		-DCMAKE_LIBRARY_PATH="$(get_llvm_prefix ${LLVM_MAX_SLOT})/$(get_libdir)"
+		-DIGC_OPTION__ARCHITECTURE_TARGET="Linux64"
+		-DIGC_OPTION__CLANG_MODE="Prebuilds"
+		-DIGC_OPTION__LLD_MODE="Prebuilds"
+		-DIGC_OPTION__LLVM_MODE="Prebuilds"
+		-DIGC_OPTION__LLVM_PREFERRED_VERSION="${LLVM_MAX_SLOT}"
+		-DIGC_OPTION__SPIRV_TRANSLATOR_MODE="Prebuilds"
+		-DIGC_OPTION__USE_KHRONOS_SPIRV_TRANSLATOR_IN_VC="ON"
+
+		# VectorCompiler needs work, as at the moment upstream
+		# only supports building vc-intrinsics in place.
+		-DIGC_BUILD__VC_ENABLED="NO"
+
+		# This will suspress some CMake warnings,
+		# which cannot be fixed at the moment.
+		-Wno-dev
+	)
+
+	cmake_src_configure
+}


             reply	other threads:[~2021-08-28  1:57 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-08-28  1:57 Conrad Kostecki [this message]
  -- strict thread matches above, loose matches on Subject: below --
2022-12-30 23:39 [gentoo-commits] repo/gentoo:master commit in: dev-util/intel-graphics-compiler/files/, dev-util/intel-graphics-compiler/ Conrad Kostecki
2022-09-25 23:12 Conrad Kostecki
2022-04-23 18:33 Conrad Kostecki
2021-10-21 22:36 Conrad Kostecki
2021-09-21 18:26 Conrad Kostecki
2021-09-03 18:25 Conrad Kostecki
2021-08-16 17:12 Conrad Kostecki
2020-09-13 22:45 Marek Szuba
2020-06-19 14:31 Marek Szuba
2019-08-05 15:26 Marek Szuba

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=1630115818.64d9c9ea8fa22a2160a4479c940bcc691f322d33.conikost@gentoo \
    --to=conikost@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /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.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox