Package Details: swift-language 5.10.1-1

Git Clone URL: https://aur.archlinux.org/swift-language.git (read-only, click to copy)
Package Base: swift-language
Description: The Swift programming language and debugger
Upstream URL: https://github.com/apple/swift
Licenses: Apache-2.0
Submitter: Zrax
Maintainer: soloturn (fanjiang, refi.64, spacecowgirl, medzik, KyleYe, xiota)
Last Packager: xiota
Votes: 45
Popularity: 0.000201
First Submitted: 2016-01-08 23:39 (UTC)
Last Updated: 2024-07-02 17:33 (UTC)

Sources (35)

Pinned Comments

xiota commented on 2023-12-31 14:56 (UTC) (edited on 2024-07-13 07:31 (UTC) by xiota)

While I was able to build this in a clean chroot, consider this package to be a wip.

  • According to this comment, swift does need swift to build. So if you haven't previously built this package, you'll need aur/swift-bin.

  • This package attempts to install only swift to /usr/lib/swift.

    • Building (5.9.2) takes about 15GB. Package is 650MB. Installed size is 2GB.
    • cmark and llvm are built, but not installed. If they are installed, space requirement increases to 20GB, package is 2GB, and installed size 7GB.
    • Above space requirements count only the build tree. Does not include space needed to download and install depends. Does not include temporary files that may have been created and deleted by the build system.
    • I don't know if everything actually works correctly. Someone who knows better would have to check. (I would use swift-bin, especially since it's already needed to build this.)
  • This package does not make debug symbols. With debugging enabled, over 70GB would be required to build. I don't know package or install size because I hadn't figured out how to install at that time.

soloturn commented on 2020-09-06 22:25 (UTC) (edited on 2023-02-05 07:39 (UTC) by soloturn)

to speed up check out of the repositories, use shallow or sparse clone, e.g.:

  GITFLAGS="--depth=1" paru -S swift-language

other options to install swift are currently:

  • swift-bin, which repackages tachoknights official released centos8 build: https://aur.archlinux.org/packages/swift-bin/. the install is quick, no hours of waiting until everything is compiled.

  • latest from git, in swift-language-git. there is a binary built with github actions, but this build is not particularly stable, sometimes it uses more resources than github allows, sometimes it fails for a change upstream. the version number is taken out of the official tag on apple/swift main branch: e.g. swift-language-git-swift.DEVELOPMENT.SNAPSHOT.2020.09.28.a.r208.g6651f6e55d4-1-x86_64.pkg.tar.zst. so this one is the development tag from sep 28 + 208 commits, the commit hash is g6651f: aur - https://aur.archlinux.org/packages/swift-language-git. gh-actions: https://github.com/soloturn/swift-aur/releases/tag/latest

there was an 5.4.1 binary build, native arch, by fanjiang, built on GCE: https://github.com/ProfFan/swift-aur/releases

Latest Comments

« First ‹ Previous 1 .. 3 4 5 6 7 8 9 10 11 12 13 .. 15 Next › Last »

felix990302 commented on 2019-06-03 04:30 (UTC) (edited on 2019-06-03 04:35 (UTC) by felix990302)

@imkerberos can confirm getting same error, looks like the system installed swig 4 package conflicted with the version provided by the swift bois

imkerberos commented on 2019-05-21 06:47 (UTC) (edited on 2019-05-21 11:52 (UTC) by imkerberos)

AIL: Swift(linux-x86_64) :: Runtime/linux-fatal-backtrace.swift (2736 of 4876)
******************** TEST 'Swift(linux-x86_64) :: Runtime/linux-fatal-backtrace.swift' FAILED ********************
Script:
--
: 'RUN: at line 1';   rm -rf "/home/kerberos/.cache/yay/swift-language/src/build/Ninja-ReleaseAssert/swift-linux-x86_64/test-linux-x86_64/Runtime/Output/linux-fatal-backtrace.swift.tmp" && mkdir -p "/home/kerberos/.cache/yay/swift-language/src/build/Ninja-ReleaseAssert/swift-linux-x86_64/test-linux-x86_64/Runtime/Output/linux-fatal-backtrace.swift.tmp"
: 'RUN: at line 2';   /home/kerberos/.cache/yay/swift-language/src/build/Ninja-ReleaseAssert/swift-linux-x86_64/bin/swiftc -target x86_64-unknown-linux-gnu  -module-cache-path '/home/kerberos/.cache/yay/swift-language/src/build/Ninja-ReleaseAssert/swift-linux-x86_64/swift-test-results/x86_64-unknown-linux-gnu/clang-module-cache' -swift-version 4   /home/kerberos/.cache/yay/swift-language/src/swift/test/Runtime/linux-fatal-backtrace.swift -o /home/kerberos/.cache/yay/swift-language/src/build/Ninja-ReleaseAssert/swift-linux-x86_64/test-linux-x86_64/Runtime/Output/linux-fatal-backtrace.swift.tmp/a.out
: 'RUN: at line 3';   not --crash /home/kerberos/.cache/yay/swift-language/src/build/Ninja-ReleaseAssert/swift-linux-x86_64/test-linux-x86_64/Runtime/Output/linux-fatal-backtrace.swift.tmp/a.out 2>&1 | PYTHONPATH=/home/kerberos/.cache/yay/swift-language/src/build/Ninja-ReleaseAssert/lldb-linux-x86_64/lib/python2.7/site-packages /home/kerberos/.cache/yay/swift-language/src/swift/utils/symbolicate-linux-fatal /home/kerberos/.cache/yay/swift-language/src/build/Ninja-ReleaseAssert/swift-linux-x86_64/test-linux-x86_64/Runtime/Output/linux-fatal-backtrace.swift.tmp/a.out - | /home/kerberos/.cache/yay/swift-language/src/swift/utils/backtrace-check -u
--
Exit Code: 1

Command Output (stderr):
--
Traceback (most recent call last):
  File "/home/kerberos/.cache/yay/swift-language/src/swift/utils/symbolicate-linux-fatal", line 32, in <module>
    import lldb
  File "/home/kerberos/.cache/yay/swift-language/src/build/Ninja-ReleaseAssert/lldb-linux-x86_64/lib/python2.7/site-packages/lldb/__init__.py", line 1499, in <module>
    class SBAddress(object):
  File "/home/kerberos/.cache/yay/swift-language/src/build/Ninja-ReleaseAssert/lldb-linux-x86_64/lib/python2.7/site-packages/lldb/__init__.py", line 1665, in SBAddress
    __swig_getmethods__["module"] = GetModule
NameError: name '__swig_getmethods__' is not defined
Traceback (most recent call last):
  File "/home/kerberos/.cache/yay/swift-language/src/swift/utils/backtrace-check", line 84, in <module>
    main()
  File "/home/kerberos/.cache/yay/swift-language/src/swift/utils/backtrace-check", line 80, in main
    assert(found_stack_trace_entry)
AssertionError

--

********************
Testing Time: 645.13s
********************
Failing Tests (1):
    Swift(linux-x86_64) :: Runtime/linux-fatal-backtrace.swift

  Expected Passes    : 3613
  Expected Failures  : 43
  Unsupported Tests  : 1219
  Unexpected Failures: 1

4 warning(s) in tests.
FAILED: test/CMakeFiles/check-swift-linux-x86_64 
cd /home/kerberos/.cache/yay/swift-language/src/build/Ninja-ReleaseAssert/swift-linux-x86_64/test && /usr/bin/cmake -E remove_directory /home/kerberos/.cache/yay/swift-language/src/build/Ninja-ReleaseAssert/swift-linux-x86_64/./swift-test-results/x86_64-unknown-linux-gnu && /usr/bin/cmake -E make_directory /home/kerberos/.cache/yay/swift-language/src/build/Ninja-ReleaseAssert/swift-linux-x86_64/./swift-test-results/x86_64-unknown-linux-gnu && /usr/bin/python2.7 /home/kerberos/.cache/yay/swift-language/src/llvm/utils/lit/lit.py --incremental -sv --xunit-xml-output=/home/kerberos/.cache/yay/swift-language/src/build/Ninja-ReleaseAssert/swift-linux-x86_64/./swift-test-results/x86_64-unknown-linux-gnu/lit-tests.xml --param swift_test_subset=primary --param swift_test_mode=optimize_none /home/kerberos/.cache/yay/swift-language/src/build/Ninja-ReleaseAssert/swift-linux-x86_64/test-linux-x86_64
ninja: build stopped: subcommand failed.
./utils/build-script: fatal error: command terminated with a non-zero exit status 1, aborting
==> ERROR: A failure occurred in check().
    Aborting...
Error making: swift-language (swift swift-lldb)

adsun commented on 2019-05-16 13:06 (UTC)

I tested with version 5.0.1 and can confirm sourcekit (libsourcekitdInProc.so) now builds successfully.

kirillbobyrev commented on 2019-04-05 18:56 (UTC) (edited on 2019-04-05 18:56 (UTC) by kirillbobyrev)

diffutils should be included in the dependencies: I tried building Swift without it and the build caught a fatal error:

FAILED: test/CMakeFiles/check-swift-linux-x86_64
cd /home/kirillbobyrev/.cache/yay/swift-language/src/build/Ninja-ReleaseAssert/swift-linux-x86_64/test && /usr/bin/cmake -E remove_directory /home/kirillbobyrev/.cache/yay/swift-language/src/build/Ninja-ReleaseAssert/swift-linux-x86_64/./s
wift-test-results/x86_64-unknown-linux-gnu && /usr/bin/cmake -E make_directory /home/kirillbobyrev/.cache/yay/swift-language/src/build/Ninja-ReleaseAssert/swift-linux-x86_64/./swift-test-results/x86_64-unknown-linux-gnu && /usr/bin/python2
.7 /home/kirillbobyrev/.cache/yay/swift-language/src/llvm/utils/lit/lit.py --incremental -sv --xunit-xml-output=/home/kirillbobyrev/.cache/yay/swift-language/src/build/Ninja-ReleaseAssert/swift-linux-x86_64/./swift-test-results/x86_64-unkn
own-linux-gnu/lit-tests.xml --param swift_test_subset=primary --param swift_test_mode=optimize_none /home/kirillbobyrev/.cache/yay/swift-language/src/build/Ninja-ReleaseAssert/swift-linux-x86_64/test-linux-x86_64
ninja: build stopped: subcommand failed.
./utils/build-script: fatal error: command terminated with a non-zero exit status 1, aborting
==> ERROR: A failure occurred in check().
    Aborting...

Zrax commented on 2019-03-14 15:45 (UTC)

@cipi1965: pkgconf is already part of base-devel. See https://wiki.archlinux.org/index.php/Arch_User_Repository#Prerequisites .

cipi1965 commented on 2019-03-14 09:49 (UTC)

Please add pkg-config to make dependencies

Zrax commented on 2018-11-28 02:13 (UTC)

@zaytoven: libblocksruntime is another AUR package (https://aur.archlinux.org/packages/libblocksruntime), so you'll need to build/install it first, before building swift.

<deleted-account> commented on 2018-11-28 02:10 (UTC)

@Zrax fair enough... I'm new so I will need some guidance... I see another error.. ERROR: 'pacman' failed to install missing dependencies. happens after not finding libblocksruntime. Steps to reproduce 1. git clone <https://aur.archlinux.org/swift-language.git> && cd swift-language && makepkg -sic.

EDIT: fix: git clone path/to/libblocksruntime.git libblockruntime-repo && cd $_ && makepkg -sic && cd ../ then git clone <https://aur.archlinux.org/swift-language.git> && cd swift-language && makepkg -sic

segabor commented on 2018-11-19 09:33 (UTC)

@zaytoven What you posted is a CPP compilation error that has nothing to do with Swift. I suppose you're trying to build Trolltech QT with Swift support. The error itself shows a QT / CPP specific build error.

Zrax commented on 2018-11-19 01:09 (UTC)

@zaytoven: I believe you're looking for https://aur.archlinux.org/packages/swift-im/ (this package is for the Swift programming language compiler)