aboutsummaryrefslogtreecommitdiffstats
path: root/community
diff options
context:
space:
mode:
authorLeon Marz <main@lmarz.org>2021-12-04 11:44:36 +0100
committerLeo <thinkabit.ukim@gmail.com>2021-12-04 12:41:11 +0000
commit76169412f5f81beab47c5a4d3d83379965fd72ff (patch)
treeef685af799f61ccb88756ec0c91301fbe3b2be02 /community
parent008e9d4bb489ee2a108f7c7cdfe2c675deec2a22 (diff)
downloadaports-76169412f5f81beab47c5a4d3d83379965fd72ff.tar.gz
aports-76169412f5f81beab47c5a4d3d83379965fd72ff.tar.bz2
aports-76169412f5f81beab47c5a4d3d83379965fd72ff.tar.xz
community/ispc: move from testing
Diffstat (limited to 'community')
-rw-r--r--community/ispc/0001-cmake-fixes.patch41
-rw-r--r--community/ispc/APKBUILD56
2 files changed, 97 insertions, 0 deletions
diff --git a/community/ispc/0001-cmake-fixes.patch b/community/ispc/0001-cmake-fixes.patch
new file mode 100644
index 0000000000..88c42ea174
--- /dev/null
+++ b/community/ispc/0001-cmake-fixes.patch
@@ -0,0 +1,41 @@
+From 6e75a3a671ae9f96372949af07df30db2d69a1dd Mon Sep 17 00:00:00 2001
+From: Leon Marz <main@lmarz.org>
+Date: Thu, 1 Jul 2021 15:34:07 +0200
+Subject: [PATCH] cmake fixes
+
+---
+ CMakeLists.txt | 4 +++-
+ 1 file changed, 3 insertions(+), 1 deletion(-)
+
+diff --git a/CMakeLists.txt b/CMakeLists.txt
+index ef88317..1443620 100644
+--- a/CMakeLists.txt
++++ b/CMakeLists.txt
+@@ -196,6 +196,7 @@ set(OUTPUT_DEBUG Debug/bin)
+ set(OUTPUT_RELEASE Release/bin)
+ set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}/bin )
+
++if(false)
+ if(CMAKE_BUILD_TYPE)
+ # Validate build type
+ set(CONFIGURATION_TYPES "Debug;Release;RelWithDebInfo")
+@@ -208,6 +209,7 @@ else(NOT CMAKE_BUILD_TYPE)
+ set(CMAKE_BUILD_TYPE "Release")
+ message(STATUS "Build type not specified: Use Release by default.")
+ endif(CMAKE_BUILD_TYPE)
++endif()
+
+ list(APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/ispcrt/cmake)
+ include(${CMAKE_CURRENT_SOURCE_DIR}/cmake/FixWindowsPath.cmake)
+@@ -525,7 +527,7 @@ else()
+ else()
+ find_package(Curses REQUIRED)
+ find_package(ZLIB REQUIRED)
+- find_library(NCURSES_TINFO_LIBRARY tinfo)
++ find_library(NCURSES_TINFO_LIBRARY ncursesw)
+ target_link_libraries(${PROJECT_NAME} pthread ${ZLIB_LIBRARIES} ${NCURSES_TINFO_LIBRARY} ${CURSES_LIBRARIES})
+ endif()
+ endif()
+--
+2.34.1
+
diff --git a/community/ispc/APKBUILD b/community/ispc/APKBUILD
new file mode 100644
index 0000000000..a6a4497cc0
--- /dev/null
+++ b/community/ispc/APKBUILD
@@ -0,0 +1,56 @@
+# Contributor: Leon Marz <main@lmarz.org>
+# Maintainer: Leon Marz <main@lmarz.org>
+pkgname=ispc
+pkgver=1.16.1
+pkgrel=1
+pkgdesc="Intel SPMD Program Compiler"
+url="https://ispc.github.io"
+arch="x86_64 armv7 aarch64" # ispc only supports these arches
+license="BSD-3-Clause"
+_llvmver=llvm12
+makedepends="cmake
+ bison
+ clang-dev
+ clang-static
+ flex
+ $_llvmver-dev
+ $_llvmver-static
+ $_llvmver-test-utils
+ m4
+ ncurses-dev
+ zlib-dev"
+source="$pkgname-$pkgver.tar.gz::https://github.com/ispc/ispc/archive/v$pkgver.tar.gz
+ 0001-cmake-fixes.patch
+ "
+options="!check" # ctest does not find a testsuite
+
+build() {
+ _x86_enabled=OFF
+ _arm_enabled=OFF
+ case "$CARCH" in
+ x86_64) _x86_enabled=ON ;;
+ armv7|aarch64) _arm_enabled=ON ;;
+ esac
+
+ cmake -B build \
+ -DCMAKE_BUILD_TYPE=None \
+ -DCMAKE_INSTALL_PREFIX=/usr \
+ -DBUILD_SHARED_LIBS=True \
+ -DCLANG_EXECUTABLE="$(command -v clang)" \
+ -DCLANGPP_EXECUTABLE="$(command -v clang++)" \
+ -DX86_ENABLED=$_x86_enabled \
+ -DARM_ENABLED=$_arm_enabled \
+ -DISPC_INCLUDE_EXAMPLES=OFF \
+ -DISPC_NO_DUMPS=ON
+
+ cmake --build build
+}
+
+package() {
+ DESTDIR="$pkgdir" cmake --install build
+}
+
+sha512sums="
+89b844a15a888ae7074c4baa47f46d1d7176501f215c9a8c3b4bf9ad1960dc77d53f1f448d5253ad0c6a91e5088af243c3dfd148e619f9abeb6a16f715e3b463 ispc-1.16.1.tar.gz
+1773cd37dac6de75512bc1285be2c4870b7ce2dfcf16c42d4788ff0a17d8a71127ebcec1110210e775a355034d32cbe91ecdffbc6cf5155f456141b23953d8f5 0001-cmake-fixes.patch
+"