diff options
author | xiota | 2023-10-30 03:37:50 -0700 |
---|---|---|
committer | xiota | 2023-10-30 03:53:26 -0700 |
commit | dc659fbc261c8d7aff2cb4f18f0b44d0ca05b796 (patch) | |
tree | 7923bd09c8836d9bfdf5489fe91afd5ba5425aa3 | |
parent | 08cfbcc544e1d5ce44d8c8fc8d6f4c226c628fcf (diff) | |
download | aur-dc659fbc261c8d7aff2cb4f18f0b44d0ca05b796.tar.gz |
link changed folder names
add some missing depends
fix build/package paths (no permission during build)
-rw-r--r-- | .SRCINFO | 30 | ||||
-rw-r--r-- | .gitignore | 42 | ||||
-rw-r--r-- | PKGBUILD | 143 |
3 files changed, 109 insertions, 106 deletions
@@ -8,6 +8,8 @@ pkgbase = swift-language makedepends = clang makedepends = cmake makedepends = git + makedepends = lld + makedepends = llvm makedepends = ninja makedepends = patch makedepends = python-six @@ -21,23 +23,22 @@ pkgbase = swift-language depends = ncurses options = !strip source = git+https://github.com/apple/swift#tag=swift-5.9-RELEASE - source = apple-cmark::git+https://github.com/apple/swift-cmark#tag=swift-5.9-RELEASE - source = llbuild::git+https://github.com/apple/swift-llbuild#tag=swift-5.9-RELEASE + source = 0001-arch-aur-patches.patch + source = apple-llvm-project::git+https://github.com/apple/llvm-project#tag=swift-5.9-RELEASE source = swift-argument-parser::git+https://github.com/apple/swift-argument-parser#tag=1.2.2 - source = swift-driver::git+https://github.com/apple/swift-driver#tag=swift-5.9-RELEASE - source = swift-tools-support-core::git+https://github.com/apple/swift-tools-support-core#tag=swift-5.9-RELEASE - source = swiftpm::git+https://github.com/apple/swift-package-manager#tag=swift-5.9-RELEASE - source = swift-syntax::git+https://github.com/apple/swift-syntax#tag=swift-5.9-RELEASE - source = swift-stress-tester::git+https://github.com/apple/swift-stress-tester#tag=swift-5.9-RELEASE - source = swift-corelibs-xctest::git+https://github.com/apple/swift-corelibs-xctest#tag=swift-5.9-RELEASE + source = swift-cmark::git+https://github.com/apple/swift-cmark#tag=swift-5.9-RELEASE source = swift-corelibs-foundation::git+https://github.com/apple/swift-corelibs-foundation#tag=swift-5.9-RELEASE source = swift-corelibs-libdispatch::git+https://github.com/apple/swift-corelibs-libdispatch#tag=swift-5.9-RELEASE + source = swift-corelibs-xctest::git+https://github.com/apple/swift-corelibs-xctest#tag=swift-5.9-RELEASE + source = swift-driver::git+https://github.com/apple/swift-driver#tag=swift-5.9-RELEASE source = swift-integration-tests::git+https://github.com/apple/swift-integration-tests#tag=swift-5.9-RELEASE - source = apple-llvm-project::git+https://github.com/apple/llvm-project#tag=swift-5.9-RELEASE - source = 0001-arch-aur-patches.patch - source = indexstore-db::git+https://github.com/apple/indexstore-db#tag=swift-5.9-RELEASE - source = yams::git+https://github.com/jpsim/Yams#tag=5.0.1 - source = sourcekit-lsp::git+https://github.com/apple/sourcekit-lsp#tag=swift-5.9-RELEASE + source = swift-llbuild::git+https://github.com/apple/swift-llbuild#tag=swift-5.9-RELEASE + source = swift-package-manager::git+https://github.com/apple/swift-package-manager#tag=swift-5.9-RELEASE + source = swift-stress-tester::git+https://github.com/apple/swift-stress-tester#tag=swift-5.9-RELEASE + source = swift-syntax::git+https://github.com/apple/swift-syntax#tag=swift-5.9-RELEASE + source = swift-tools-support-core::git+https://github.com/apple/swift-tools-support-core#tag=swift-5.9-RELEASE + source = apple-indexstore-db::git+https://github.com/apple/indexstore-db#tag=swift-5.9-RELEASE + source = apple-sourcekit-lsp::git+https://github.com/apple/sourcekit-lsp#tag=swift-5.9-RELEASE source = swift-asn1::git+https://github.com/apple/swift-asn1#tag=0.7.0 source = swift-atomics::git+https://github.com/apple/swift-atomics#tag=1.0.2 source = swift-certificates::git+https://github.com/apple/swift-certificates#tag=0.4.1 @@ -57,7 +58,9 @@ pkgbase = swift-language source = swift-system::git+https://github.com/apple/swift-system#tag=1.1.1 source = swift-tools-support-core::git+https://github.com/apple/swift-tools-support-core#tag=swift-5.9-RELEASE source = swift-xcode-playground-support::git+https://github.com/apple/swift-xcode-playground-support#tag=swift-5.9-RELEASE + source = yams::git+https://github.com/jpsim/Yams#tag=5.0.1 sha256sums = SKIP + sha256sums = 3941d6e2ff26ee0bf2d0ae37ed618d1cb36af85e256b0b84dd4e5d8549ec2982 sha256sums = SKIP sha256sums = SKIP sha256sums = SKIP @@ -71,7 +74,6 @@ pkgbase = swift-language sha256sums = SKIP sha256sums = SKIP sha256sums = SKIP - sha256sums = 3941d6e2ff26ee0bf2d0ae37ed618d1cb36af85e256b0b84dd4e5d8549ec2982 sha256sums = SKIP sha256sums = SKIP sha256sums = SKIP diff --git a/.gitignore b/.gitignore index 0799bc2043c5..018a3de08144 100644 --- a/.gitignore +++ b/.gitignore @@ -1,38 +1,4 @@ -/src/ -/pkg/ -*.tar.xz* -*.tar.gz* -/apple-cmark/ -/apple-llvm-project/ -/indexstore-db/ -/llbuild/ -/sourcekit-lsp/ -/swift-argument-parser/ -/swift-atomics/ -/swift-cmark-gfm/ -/swift-collections/ -/swift-corelibs-foundation/ -/swift-corelibs-libdispatch/ -/swift-corelibs-xctest/ -/swift-crypto/ -/swift-docc-render-artifact/ -/swift-docc-symbolkit/ -/swift-docc/ -/swift-driver/ -/swift-format/ -/swift-installer-scripts/ -/swift-integration-tests/ -/swift-lmdb/ -/swift-markdown/ -/swift-nio-ssl/ -/swift-nio/ -/swift-numerics/ -/swift-stress-tester/ -/swift-syntax/ -/swift-system/ -/swift-tools-support-core/ -/swift-xcode-playground-support/ -/swift/ -/swiftpm/ -/yams/ - +* +!PKGBUILD +!.SRCINFO +!.gitignore @@ -5,60 +5,64 @@ # Contributor: Gábor Sebestyén <segabor@gmail.com> # Contributor: Andrew Sun <adsun701@gmail.com> -pkgname=swift-language +_pkgname="swift-language" +pkgname="$_pkgname" _swiftver=swift-5.9-RELEASE pkgver=5.9 pkgrel=1 - pkgdesc="The Swift programming language and debugger" arch=('x86_64') url="https://swift.org/" license=('apache2') -depends=('icu' 'libedit' 'libxml2' 'python' 'libbsd' 'ncurses' ) -makedepends=('clang' 'cmake' 'git' 'ninja' 'patch' 'python-six' 'rsync' 'swig') +depends=('icu' 'libedit' 'libxml2' 'python' 'libbsd' 'ncurses') +makedepends=('clang' 'cmake' 'git' 'lld' 'llvm' 'ninja' 'patch' 'python-six' 'rsync' 'swig') + source=( "git+https://github.com/apple/swift#tag=${_swiftver}" - "apple-cmark::git+https://github.com/apple/swift-cmark#tag=${_swiftver}" - "llbuild::git+https://github.com/apple/swift-llbuild#tag=${_swiftver}" - "swift-argument-parser::git+https://github.com/apple/swift-argument-parser#tag=1.2.2" - "swift-driver::git+https://github.com/apple/swift-driver#tag=${_swiftver}" - "swift-tools-support-core::git+https://github.com/apple/swift-tools-support-core#tag=${_swiftver}" - "swiftpm::git+https://github.com/apple/swift-package-manager#tag=${_swiftver}" - "swift-syntax::git+https://github.com/apple/swift-syntax#tag=${_swiftver}" - "swift-stress-tester::git+https://github.com/apple/swift-stress-tester#tag=${_swiftver}" - "swift-corelibs-xctest::git+https://github.com/apple/swift-corelibs-xctest#tag=${_swiftver}" - "swift-corelibs-foundation::git+https://github.com/apple/swift-corelibs-foundation#tag=${_swiftver}" - "swift-corelibs-libdispatch::git+https://github.com/apple/swift-corelibs-libdispatch#tag=${_swiftver}" - "swift-integration-tests::git+https://github.com/apple/swift-integration-tests#tag=${_swiftver}" - "apple-llvm-project::git+https://github.com/apple/llvm-project#tag=${_swiftver}" - "0001-arch-aur-patches.patch" + '0001-arch-aur-patches.patch' + + "apple-llvm-project"::"git+https://github.com/apple/llvm-project#tag=${_swiftver}" + "swift-argument-parser"::"git+https://github.com/apple/swift-argument-parser#tag=1.2.2" + "swift-cmark"::"git+https://github.com/apple/swift-cmark#tag=${_swiftver}" + "swift-corelibs-foundation"::"git+https://github.com/apple/swift-corelibs-foundation#tag=${_swiftver}" + "swift-corelibs-libdispatch"::"git+https://github.com/apple/swift-corelibs-libdispatch#tag=${_swiftver}" + "swift-corelibs-xctest"::"git+https://github.com/apple/swift-corelibs-xctest#tag=${_swiftver}" + "swift-driver"::"git+https://github.com/apple/swift-driver#tag=${_swiftver}" + "swift-integration-tests"::"git+https://github.com/apple/swift-integration-tests#tag=${_swiftver}" + "swift-llbuild"::"git+https://github.com/apple/swift-llbuild#tag=${_swiftver}" + "swift-package-manager"::"git+https://github.com/apple/swift-package-manager#tag=${_swiftver}" + "swift-stress-tester"::"git+https://github.com/apple/swift-stress-tester#tag=${_swiftver}" + "swift-syntax"::"git+https://github.com/apple/swift-syntax#tag=${_swiftver}" + "swift-tools-support-core"::"git+https://github.com/apple/swift-tools-support-core#tag=${_swiftver}" + # swift src to check afterwards - "indexstore-db::git+https://github.com/apple/indexstore-db#tag=${_swiftver}" - "yams::git+https://github.com/jpsim/Yams#tag=5.0.1" - "sourcekit-lsp::git+https://github.com/apple/sourcekit-lsp#tag=${_swiftver}" - "swift-asn1::git+https://github.com/apple/swift-asn1#tag=0.7.0" - "swift-atomics::git+https://github.com/apple/swift-atomics#tag=1.0.2" - "swift-certificates::git+https://github.com/apple/swift-certificates#tag=0.4.1" - "swift-cmark-gfm::git+https://github.com/apple/swift-cmark#tag=${_swiftver}" - "swift-collections::git+https://github.com/apple/swift-collections#tag=1.0.1" - "swift-crypto::git+https://github.com/apple/swift-crypto#tag=2.5.0" - "swift-docc::git+https://github.com/apple/swift-docc#tag=${_swiftver}" - "swift-docc-render-artifact::git+https://github.com/apple/swift-docc-render-artifact#tag=${_swiftver}" - "swift-docc-symbolkit::git+https://github.com/apple/swift-docc-symbolkit#tag=${_swiftver}" - "swift-format::git+https://github.com/apple/swift-format#tag=${_swiftver}" - "swift-installer-scripts::git+https://github.com/apple/swift-installer-scripts#tag=${_swiftver}" - "swift-lmdb::git+https://github.com/apple/swift-lmdb#tag=${_swiftver}" - "swift-markdown::git+https://github.com/apple/swift-markdown#tag=${_swiftver}" - "swift-nio::git+https://github.com/apple/swift-nio#tag=2.31.2" - "swift-nio-ssl::git+https://github.com/apple/swift-nio-ssl#tag=2.15.0" - "swift-numerics::git+https://github.com/apple/swift-numerics#tag=1.0.1" - "swift-system::git+https://github.com/apple/swift-system#tag=1.1.1" - "swift-tools-support-core::git+https://github.com/apple/swift-tools-support-core#tag=${_swiftver}" - "swift-xcode-playground-support::git+https://github.com/apple/swift-xcode-playground-support#tag=${_swiftver}" + "apple-indexstore-db"::"git+https://github.com/apple/indexstore-db#tag=${_swiftver}" + "apple-sourcekit-lsp"::"git+https://github.com/apple/sourcekit-lsp#tag=${_swiftver}" + "swift-asn1"::"git+https://github.com/apple/swift-asn1#tag=0.7.0" + "swift-atomics"::"git+https://github.com/apple/swift-atomics#tag=1.0.2" + "swift-certificates"::"git+https://github.com/apple/swift-certificates#tag=0.4.1" + "swift-cmark-gfm"::"git+https://github.com/apple/swift-cmark#tag=${_swiftver}" + "swift-collections"::"git+https://github.com/apple/swift-collections#tag=1.0.1" + "swift-crypto"::"git+https://github.com/apple/swift-crypto#tag=2.5.0" + "swift-docc"::"git+https://github.com/apple/swift-docc#tag=${_swiftver}" + "swift-docc-render-artifact"::"git+https://github.com/apple/swift-docc-render-artifact#tag=${_swiftver}" + "swift-docc-symbolkit"::"git+https://github.com/apple/swift-docc-symbolkit#tag=${_swiftver}" + "swift-format"::"git+https://github.com/apple/swift-format#tag=${_swiftver}" + "swift-installer-scripts"::"git+https://github.com/apple/swift-installer-scripts#tag=${_swiftver}" + "swift-lmdb"::"git+https://github.com/apple/swift-lmdb#tag=${_swiftver}" + "swift-markdown"::"git+https://github.com/apple/swift-markdown#tag=${_swiftver}" + "swift-nio"::"git+https://github.com/apple/swift-nio#tag=2.31.2" + "swift-nio-ssl"::"git+https://github.com/apple/swift-nio-ssl#tag=2.15.0" + "swift-numerics"::"git+https://github.com/apple/swift-numerics#tag=1.0.1" + "swift-system"::"git+https://github.com/apple/swift-system#tag=1.1.1" + "swift-tools-support-core"::"git+https://github.com/apple/swift-tools-support-core#tag=${_swiftver}" + "swift-xcode-playground-support"::"git+https://github.com/apple/swift-xcode-playground-support#tag=${_swiftver}" + "yams"::"git+https://github.com/jpsim/Yams#tag=5.0.1" ) -noextract=() sha256sums=( 'SKIP' + '3941d6e2ff26ee0bf2d0ae37ed618d1cb36af85e256b0b84dd4e5d8549ec2982' + 'SKIP' 'SKIP' 'SKIP' @@ -72,7 +76,7 @@ sha256sums=( 'SKIP' 'SKIP' 'SKIP' - '3941d6e2ff26ee0bf2d0ae37ed618d1cb36af85e256b0b84dd4e5d8549ec2982' + 'SKIP' 'SKIP' 'SKIP' @@ -106,31 +110,62 @@ sha256sums=( options=(!strip) prepare () { - ( cd apple-llvm-project && patch -p1 -i "$srcdir/0002-stdint.patch" ) -} + ln -sfP 'apple-indexstore-db' 'indexstore-db' + ln -sfP 'apple-llvm-project' 'llvm-project' + ln -sfP 'apple-sourcekit-lsp' 'sourcekit-lsp' + ln -sfP 'swift-argument-parser' 'argument-parser' + ln -sfP 'swift-asn1' 'asn1' + ln -sfP 'swift-atomics' 'atomics' + ln -sfP 'swift-certificates' 'certificates' + ln -sfP 'swift-cmark' 'cmark' + ln -sfP 'swift-cmark' 'cmark' + ln -sfP 'swift-collections' 'collections' + ln -sfP 'swift-corelibs-foundation' 'corelibs-foundation' + ln -sfP 'swift-corelibs-libdispatch' 'corelibs-libdispatch' + ln -sfP 'swift-corelibs-xctest' 'corelibs-xctest' + ln -sfP 'swift-crypto' 'crypto' + ln -sfP 'swift-docc' 'docc' + ln -sfP 'swift-docc-render-artifact' 'docc-render-artifact' + ln -sfP 'swift-docc-symbolkit' 'docc-symbolkit' + ln -sfP 'swift-driver' 'driver' + ln -sfP 'swift-experimental-string-processing' 'experimental-string-processing' + ln -sfP 'swift-format' 'format' + ln -sfP 'swift-installer-scripts' 'installer-scripts' + ln -sfP 'swift-integration-tests' 'integration-tests' + ln -sfP 'swift-llbuild' 'llbuild' + ln -sfP 'swift-llvm-bindings' 'llvm-bindings' + ln -sfP 'swift-lmdb' 'lmdb' + ln -sfP 'swift-markdown' 'markdown' + ln -sfP 'swift-nio' 'nio' + ln -sfP 'swift-nio-ssl' 'nio-ssl' + ln -sfP 'swift-numerics' 'numerics' + ln -sfP 'swift-package-manager' 'package-manager' + ln -sfP 'swift-stress-tester' 'stress-tester' + ln -sfP 'swift-syntax' 'syntax' + ln -sfP 'swift-system' 'system' + ln -sfP 'swift-tools-support-core' 'tools-support-core' + ln -sfP 'swift-xcode-playground-support' 'xcode-playground-support' -#pkgver() { -# cd "$srcdir/swift" -# git describe --long | sed 's/\([^-]*-g\)/r\1/;s/-/./g' -#} + ( cd swift && patch -Np1 -F100 -i "${srcdir:?}/0001-arch-aur-patches.patch" ) +} build() { - 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/apple-llvm-project/clang" -type f -print0 | xargs -0 sed -i 's|/usr/include/x86_64-linux-gnu|/usr/include|g' - find "$srcdir/apple-llvm-project/clang-tools-extra" -type f -print0 | xargs -0 sed -i 's|/usr/include/x86_64-linux-gnu|/usr/include|g' + 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:?}/apple-llvm-project/clang" -type f -print0 | xargs -0 sed -i 's|/usr/include/x86_64-linux-gnu|/usr/include|g' + find "${srcdir:?}/apple-llvm-project/clang-tools-extra" -type f -print0 | xargs -0 sed -i 's|/usr/include/x86_64-linux-gnu|/usr/include|g' # By default in /etc/makepkg.conf this is "-D_FORTIFY_SOURCE=2" # Which will break `compiler-rt` unset CPPFLAGS export DISTCC_HOSTS='--randomize localhost red,cpp,lzo green,cpp,lzo blue,cpp,lzo' - python swift/utils/build-script --preset=buildbot_linux,no_test install_destdir="$pkgdir" + python swift/utils/build-script --preset=buildbot_linux,no_test install_destdir="${srcdir:?}/destdir" } package() { - ls -la + ls -la "${srcdir:?}/destdir" + mv "${srcdir:?}/destdir"/* "${pkgdir:?}" } # vim:set ts=2 sw=2 et: |