From: "Christoph Junghans" <junghans@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-lang/ispc/, dev-lang/ispc/files/
Date: Sun, 28 Jun 2020 16:45:20 +0000 (UTC) [thread overview]
Message-ID: <1593362622.f073ca910b7838d71043c2ae752fcd0d147937bd.junghans@gentoo> (raw)
commit: f073ca910b7838d71043c2ae752fcd0d147937bd
Author: Guillaume BRUN <the.cheaterman <AT> gmail <DOT> com>
AuthorDate: Sun Jun 28 15:48:55 2020 +0000
Commit: Christoph Junghans <junghans <AT> gentoo <DOT> org>
CommitDate: Sun Jun 28 16:43:42 2020 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f073ca91
dev-lang/ispc: Add -1.13.0 ebuild
Closes: https://bugs.gentoo.org/656632
Closes: https://bugs.gentoo.org/729924
Signed-off-by: Guillaume BRUN <the.cheaterman <AT> gmail.com>
Package-Manager: Portage-2.3.99, Repoman-2.3.23
Signed-off-by: Christoph Junghans <junghans <AT> gentoo.org>
dev-lang/ispc/Manifest | 1 +
.../files/ispc-1.13.0-cmake-gentoo-release.patch | 13 +++
dev-lang/ispc/files/ispc-1.13.0-llvm-10.patch | 106 +++++++++++++++++++++
dev-lang/ispc/files/ispc-1.13.0-werror.patch | 13 +++
.../ispc/{ispc-9999.ebuild => ispc-1.13.0.ebuild} | 27 ++++--
5 files changed, 150 insertions(+), 10 deletions(-)
diff --git a/dev-lang/ispc/Manifest b/dev-lang/ispc/Manifest
index 20f32b7fe6c..09380cb968c 100644
--- a/dev-lang/ispc/Manifest
+++ b/dev-lang/ispc/Manifest
@@ -1 +1,2 @@
+DIST ispc-1.13.0.tar.gz 19202295 BLAKE2B 5fae81429acbda0d65d33e56609d05fb8b5a7db6dd0af5ff779d1e8954f6a98d1fcb0f7ecf0c1b9813630026557c21c2a70bfc87ed75959a8bd24e06fcd2e351 SHA512 d23c127beb9bb17e1ad2509f9ad51dd660c473458b939a6b64ca7f6319b3c2f25318ea2ceac00e4100a059f3f67fb97b6973f18e3432c82ff9691f2a08d15d5d
DIST ispc-1.9.2.tar.gz 19283765 BLAKE2B 500cca8a69a78ad9a21dc1e39dcb3ed01730e78deed61e4871ce5a9761829c80ac7b1b987d8e8a48c34b67ac96692b2c5026cfb5059a32c71e228c73550584eb SHA512 77a66086cbfd6c4dc855b3137a270cc40f24829255639aee5f562b0831c21938157667b20cfadc660cd67525c47e2e73b46692f7a11bf0c834dc60b69d40d76d
diff --git a/dev-lang/ispc/files/ispc-1.13.0-cmake-gentoo-release.patch b/dev-lang/ispc/files/ispc-1.13.0-cmake-gentoo-release.patch
new file mode 100644
index 00000000000..b89e6150400
--- /dev/null
+++ b/dev-lang/ispc/files/ispc-1.13.0-cmake-gentoo-release.patch
@@ -0,0 +1,13 @@
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 13e66268..27ff8364 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -137,7 +137,7 @@ set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/bin )
+
+ if(CMAKE_BUILD_TYPE)
+ # Validate build type
+- set(CONFIGURATION_TYPES "Debug;Release;RelWithDebInfo")
++ set(CONFIGURATION_TYPES "Debug;Release;RelWithDebInfo;Gentoo")
+
+ string(FIND "${CONFIGURATION_TYPES}" "${CMAKE_BUILD_TYPE}" MATCHED_CONFIG)
+ if (${MATCHED_CONFIG} EQUAL -1)
diff --git a/dev-lang/ispc/files/ispc-1.13.0-llvm-10.patch b/dev-lang/ispc/files/ispc-1.13.0-llvm-10.patch
new file mode 100644
index 00000000000..6911a76d9e1
--- /dev/null
+++ b/dev-lang/ispc/files/ispc-1.13.0-llvm-10.patch
@@ -0,0 +1,106 @@
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 13e66268..27ff8364 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -218,7 +218,7 @@ if (WASM_ENABLED)
+ list(APPEND ISPC_TARGETS wasm-i32x4)
+ endif()
+
+-set(CLANG_LIBRARY_LIST clangFrontend clangDriver clangSerialization clangParse clangSema clangAnalysis clangAST clangBasic clangEdit clangLex)
++set(CLANG_LIBRARY_LIST clang clang-cpp)
+ set(LLVM_COMPONENTS engine ipo bitreader bitwriter instrumentation linker option)
+
+ if (${LLVM_VERSION_NUMBER} VERSION_GREATER_EQUAL "10.0.0")
+@@ -402,11 +402,8 @@ if (ISPC_USE_ASAN)
+ endif()
+
+ # Link against Clang libraries
+-foreach(clangLib ${CLANG_LIBRARY_LIST})
+- find_library(${clangLib}Path NAMES ${clangLib} HINTS ${LLVM_LIBRARY_DIRS})
+- list(APPEND CLANG_LIBRARY_FULL_PATH_LIST ${${clangLib}Path})
+-endforeach()
+-target_link_libraries(${PROJECT_NAME} ${CLANG_LIBRARY_FULL_PATH_LIST})
++find_package(Clang REQUIRED)
++target_link_libraries(${PROJECT_NAME} ${CLANG_LIBRARY_LIST})
+
+ # Link against LLVM libraries
+ target_link_libraries(${PROJECT_NAME} ${LLVM_LIBRARY_LIST})
+diff --git a/src/llvmutil.cpp b/src/llvmutil.cpp
+index 06fab989..57a7130f 100644
+--- a/src/llvmutil.cpp
++++ b/src/llvmutil.cpp
+@@ -42,6 +42,7 @@
+ #include <llvm/IR/BasicBlock.h>
+ #include <llvm/IR/Instructions.h>
+ #include <llvm/IR/Module.h>
++#include <llvm/Support/raw_ostream.h>
+ #include <map>
+ #include <set>
+ #include <vector>
+@@ -1394,7 +1395,7 @@ static void lDumpValue(llvm::Value *v, std::set<llvm::Value *> &done) {
+ return;
+
+ fprintf(stderr, " ");
+- v->dump();
++ v->print(llvm::outs(), false);
+ done.insert(v);
+
+ if (inst == NULL)
+diff --git a/src/opt.cpp b/src/opt.cpp
+index d78ac374..a607594a 100644
+--- a/src/opt.cpp
++++ b/src/opt.cpp
+@@ -142,7 +142,7 @@ static llvm::Pass *CreateFixBooleanSelectPass();
+ getenv("FUNC"), strlen(getenv("FUNC")))))) { \
+ fprintf(stderr, "Start of " NAME "\n"); \
+ fprintf(stderr, "---------------\n"); \
+- bb.dump(); \
++ bb.print(llvm::outs(), false); \
+ fprintf(stderr, "---------------\n\n"); \
+ } else /* eat semicolon */
+
+@@ -152,7 +152,7 @@ static llvm::Pass *CreateFixBooleanSelectPass();
+ getenv("FUNC"), strlen(getenv("FUNC")))))) { \
+ fprintf(stderr, "End of " NAME " %s\n", modifiedAny ? "** CHANGES **" : ""); \
+ fprintf(stderr, "---------------\n"); \
+- bb.dump(); \
++ bb.print(llvm::outs(), false); \
+ fprintf(stderr, "---------------\n\n"); \
+ } else /* eat semicolon */
+ #else
+@@ -453,7 +453,7 @@ void Optimize(llvm::Module *module, int optLevel) {
+ #ifndef ISPC_NO_DUMPS
+ if (g->debugPrint) {
+ printf("*** Code going into optimization ***\n");
+- module->dump();
++ module->print(llvm::outs(), nullptr);
+ }
+ #endif
+ DebugPassManager optPM;
+@@ -666,7 +666,7 @@ void Optimize(llvm::Module *module, int optLevel) {
+ #ifndef ISPC_NO_DUMPS
+ if (g->debugPrint) {
+ printf("\n*****\nFINAL OUTPUT\n*****\n");
+- module->dump();
++ module->print(llvm::outs(), nullptr);
+ }
+ #endif
+ }
+@@ -4256,7 +4256,7 @@ char DebugPass::ID = 0;
+ bool DebugPass::runOnModule(llvm::Module &module) {
+ fprintf(stderr, "%s", str_output);
+ fflush(stderr);
+- module.dump();
++ module.print(llvm::outs(), nullptr);
+ return true;
+ }
+
+@@ -4303,7 +4303,7 @@ void DebugPassFile::run(llvm::Module &module, bool init) {
+ snprintf(fname, sizeof(fname), "%s_%d_%s.ll", init ? "init" : "ir", pnum, sanitize(std::string(pname)).c_str());
+ llvm::raw_fd_ostream OS(fname, EC, llvm::sys::fs::F_None);
+ Assert(!EC && "IR dump file creation failed!");
+- module.print(OS, 0);
++ module.print(OS, nullptr);
+ }
+
+ bool DebugPassFile::runOnModule(llvm::Module &module) {
diff --git a/dev-lang/ispc/files/ispc-1.13.0-werror.patch b/dev-lang/ispc/files/ispc-1.13.0-werror.patch
new file mode 100644
index 00000000000..3fa144b78db
--- /dev/null
+++ b/dev-lang/ispc/files/ispc-1.13.0-werror.patch
@@ -0,0 +1,13 @@
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index 13e66268..27ff8364 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -352,7 +352,7 @@ target_include_directories(${PROJECT_NAME} PRIVATE
+ ${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_CFG_INTDIR})
+ # Compile options
+ if (UNIX)
+- target_compile_options(${PROJECT_NAME} PRIVATE -Wall -Wno-sign-compare -Wno-unused-function -Werror ${LLVM_CPP_FLAGS})
++ target_compile_options(${PROJECT_NAME} PRIVATE -Wall -Wno-sign-compare -Wno-unused-function ${LLVM_CPP_FLAGS})
+ # Security options
+ target_compile_options(${PROJECT_NAME} PRIVATE -fstack-protector -fdata-sections -ffunction-sections
+ -Wformat -Wformat-security -fpie -fwrapv)
diff --git a/dev-lang/ispc/ispc-9999.ebuild b/dev-lang/ispc/ispc-1.13.0.ebuild
similarity index 65%
rename from dev-lang/ispc/ispc-9999.ebuild
rename to dev-lang/ispc/ispc-1.13.0.ebuild
index d1c2c233112..244bb728565 100644
--- a/dev-lang/ispc/ispc-9999.ebuild
+++ b/dev-lang/ispc/ispc-1.13.0.ebuild
@@ -1,11 +1,11 @@
-# Copyright 1999-2018 Gentoo Foundation
+# Copyright 1999-2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
-EAPI=6
+EAPI=7
PYTHON_COMPAT=( python2_7 )
-inherit toolchain-funcs python-any-r1
+inherit cmake toolchain-funcs python-any-r1
DESCRIPTION="Intel SPMD Program Compiler"
HOMEPAGE="https://ispc.github.com/"
@@ -34,19 +34,26 @@ DEPEND="
sys-devel/flex
"
-src_compile() {
- #make all slient commands ("@") verbose and remove -Werror (ispc/ispc#1295)
- sed -e '/^\t@/s/@//' -e 's/-Werror//' -i Makefile || die
- emake LDFLAGS="${LDFLAGS}" OPT="${CXXFLAGS}" CXX="$(tc-getCXX)" CPP="$(tc-getCPP)"
+PATCHES=(
+ "${FILESDIR}/${P}-cmake-gentoo-release.patch"
+ "${FILESDIR}/${P}-llvm-10.patch"
+ "${FILESDIR}/${P}-werror.patch"
+)
+
+src_configure() {
+ local mycmakeargs=(
+ "-DARM_ENABLED=$(usex arm)"
+ )
+ cmake_src_configure
}
src_install() {
- dobin ispc
- dodoc README.rst
+ dobin ${BUILD_DIR}/bin/ispc
+ dodoc README.md
if use examples; then
insinto "/usr/share/doc/${PF}/examples"
docompress -x "/usr/share/doc/${PF}/examples"
- doins -r examples/*
+ doins -r ${BUILD_DIR}/examples/*
fi
}
next reply other threads:[~2020-06-28 16:45 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-06-28 16:45 Christoph Junghans [this message]
-- strict thread matches above, loose matches on Subject: below --
2020-06-28 16:45 [gentoo-commits] repo/gentoo:master commit in: dev-lang/ispc/, dev-lang/ispc/files/ Christoph Junghans
2020-07-29 16:52 Andreas Sturmlechner
2021-05-26 5:21 Joonas Niilola
2022-06-12 12:02 Sam James
2022-10-01 3:12 Sam James
2023-05-01 15:15 Sam James
2023-05-03 11:26 Sam James
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=1593362622.f073ca910b7838d71043c2ae752fcd0d147937bd.junghans@gentoo \
--to=junghans@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