cruxports/libdispatch/Pkgfile

24 lines
780 B
Plaintext

# Description: grand central dispatch, from swift corelibs
# URL: https://github.com/apple/swift-corelibs-libdispatch/releases
# Maintainer: John McQuah, jmcquah at disroot dot org
# Depends on: clang libbsd
name=libdispatch
version=5.5.3
release=1
source=(https://github.com/apple/swift-corelibs-$name/archive/refs/tags/swift-$version-RELEASE.zip)
build() {
find swift-corelibs-* -name DispatchCompilerWarnings.cmake \
-exec sed -i "/-Werror/d" '{}' \;
mkdir build && cd build
cmake -G Ninja -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX=/usr \
-DBlocksRuntime_INCLUDE_DIR=/usr/include \
-DCMAKE_BUILD_WITH_INSTALL_RPATH=on ../swift-corelibs-$name-*
ninja
DESTDIR=$PKG ninja install
}