summarylogtreecommitdiffstats
path: root/PKGBUILD
diff options
context:
space:
mode:
authorsoloturn2020-07-06 21:24:37 +0200
committersoloturn2020-07-06 21:24:37 +0200
commit37ca08c187146aade62c268615834d46d52f5d11 (patch)
treedd107606751cb0a9444df05e7407812d8e32328c /PKGBUILD
parent6c48f5aaa30f8ccd3bda8179149c7c38504f35ba (diff)
downloadaur-swift-language.tar.gz
patch not build ninja, icu
Diffstat (limited to 'PKGBUILD')
-rw-r--r--PKGBUILD14
1 files changed, 10 insertions, 4 deletions
diff --git a/PKGBUILD b/PKGBUILD
index 9c0d152da66..4cea368aff0 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -29,6 +29,7 @@ source=(
"swift-corelibs-libdispatch-${_swiftver}.tar.gz::https://github.com/apple/swift-corelibs-libdispatch/archive/swift-${_swiftver}.tar.gz"
"swift-integration-tests-${_swiftver}.tar.gz::https://github.com/apple/swift-integration-tests/archive/swift-${_swiftver}.tar.gz"
"swift-package-manager-${_swiftver}.tar.gz::https://github.com/apple/swift-package-manager/archive/swift-${_swiftver}.tar.gz"
+ '0001-not-build-ninja-icu.patch'
)
sha256sums=(
'SKIP'
@@ -40,6 +41,7 @@ sha256sums=(
'SKIP'
'SKIP'
'SKIP'
+ 'SKIP'
)
prepare() {
@@ -64,6 +66,8 @@ prepare() {
rm -rf swift swiftpm
mv swift-swift-${_swiftver} swift
mv swift-package-manager-swift-${_swiftver} swiftpm
+
+ ( cd swift && patch -p1 -i "$srcdir/0001-not-build-ninja-icu.patch" )
}
_common_build_params=(
@@ -83,10 +87,12 @@ _build_script_wrapper() {
}
build() {
- cd "$srcdir/swift"
-
- export PATH="$PATH:/usr/bin/core_perl"
- _build_script_wrapper -R "${_common_build_params[@]}"
+ cd "$srcdir"
+ # Fix /usr/include error
+ find "$srcdir/swift/stdlib/public/SwiftShims" -type f -print0 | xargs -0 sed -i 's|/usr/include/x86_64-linux-gnu|/usr/include|g'
+ find "$srcdir/llvm-project/clang" -type f -print0 | xargs -0 sed -i 's|/usr/include/x86_64-linux-gnu|/usr/include|g'
+ find "$srcdir/llvm-project/clang-tools-extra" -type f -print0 | xargs -0 sed -i 's|/usr/include/x86_64-linux-gnu|/usr/include|g'
+ LDFLAGS='-ldl -lpthread' python swift/utils/build-script --preset=buildbot_linux,no_test install_destdir="$srcdir/build" installable_package="$srcdir/swift-arch-pkg.tar.gz"
}
check() {