From e65048786d74e35280b81f19969c78ffbce02a1e Mon Sep 17 00:00:00 2001 From: Ron Olson Date: Tue, 3 Jul 2018 22:35:16 -0500 Subject: Broke out swift runtime libs into a runtime package, filtered out lldb libraries, removed dependency on which, updated to latest version of Swift 4.2 --- swift-lang-runtime.conf | 1 + swift-lang.conf | 1 - swift-lang.spec | 46 ++++++++++++++++++++++++++++++++++++++-------- 3 files changed, 39 insertions(+), 9 deletions(-) create mode 100644 swift-lang-runtime.conf diff --git a/swift-lang-runtime.conf b/swift-lang-runtime.conf new file mode 100644 index 0000000..d19930a --- /dev/null +++ b/swift-lang-runtime.conf @@ -0,0 +1 @@ +/usr/lib/swift/linux diff --git a/swift-lang.conf b/swift-lang.conf index 7ad92c4..ce1b5b2 100644 --- a/swift-lang.conf +++ b/swift-lang.conf @@ -1,2 +1 @@ /usr/lib/swift-lldb -/usr/lib/swift/linux diff --git a/swift-lang.spec b/swift-lang.spec index 8d2cb21..37751c6 100644 --- a/swift-lang.spec +++ b/swift-lang.spec @@ -1,11 +1,12 @@ %global debug_package %{nil} -%global swifttag 4.2-DEVELOPMENT-SNAPSHOT-2018-07-02-a -%global swiftgithash c2e1567 -%global swiftgitdate 20180702 +%global swifttag 4.2-DEVELOPMENT-SNAPSHOT-2018-07-03-a +%global swiftgithash 107e307 +%global swiftgitdate 20180703 %global swiftbuild swift-source -Name: swift-lang +%global __provides_exclude_from ^/usr/lib/swift-lldb/.*\\.so$ +Name: swift-lang Version: 4.2 -Release: 0.25.%{swiftgitdate}git%{swiftgithash}%{?dist} +Release: 0.26.%{swiftgitdate}git%{swiftgithash}%{?dist} Summary: Apple's Swift programming language License: ASL 2.0 URL: https://swift.org @@ -23,7 +24,7 @@ Source10: https://github.com/apple/swift-llbuild/archive/swift-%{swifttag} Source11: https://github.com/apple/swift-cmark/archive/swift-%{swifttag}.tar.gz#/cmark.tar.gz Source12: https://github.com/apple/swift-xcode-playground-support/archive/swift-%{swifttag}.tar.gz#/swift-xcode-playground-support.tar.gz Source13: swift-lang.conf - +Source14: swift-lang-runtime.conf Patch0: %{name}-%{version}-change-lldb-location.patch Patch1: compiler-rt-no-ustat.patch @@ -31,7 +32,6 @@ Patch2: no-ninja-build.patch Patch3: time-struct-redefined.patch -BuildRequires: which BuildRequires: clang BuildRequires: cmake BuildRequires: swig @@ -55,9 +55,11 @@ Requires: glibc-devel Requires: clang Requires: libatomic Requires: libbsd +Requires: %{name}-runtime = %{version}-%{release} ExcludeArch: s390x i686 armv7hl ppc64le aarch64 ppc64 + %description Swift is a general-purpose programming language built using a modern approach to safety, performance, and software design @@ -70,6 +72,13 @@ importantly, Swift is designed to make writing and maintaining correct programs easier for the developer. +%package runtime +Summary: Runtime files for Swift + +%description runtime +Runtime libraries for Swift programs + +# % ifarch s390x %prep %setup -q -c -n %{swiftbuild} -a 0 -a 1 -a 2 -a 3 -a 4 -a 5 -a 6 -a 7 -a 8 -a 9 -a 10 -a 11 -a 12 @@ -112,6 +121,7 @@ export VERBOSE=1 export PYTHON_DISALLOW_AMBIGUOUS_VERSION=0 swift/utils/build-script --preset=buildbot_linux,no_test install_destdir=%{_builddir} installable_package=%{_builddir}/swift-%{version}-fedora.tar.gz +# % endif %install export PYTHON_DISALLOW_AMBIGUOUS_VERSION=0 @@ -158,6 +168,7 @@ cp -r %{_builddir}/usr/lib/swift_static/* %{buildroot}/usr/lib/swift_static mkdir -p %{buildroot}/%{_sysconfdir}/ld.so.conf.d/ install -m 0644 %{SOURCE13} %{buildroot}/%{_sysconfdir}/ld.so.conf.d/swift-lang.conf +install -m 0644 %{SOURCE14} %{buildroot}/%{_sysconfdir}/ld.so.conf.d/swift-lang-runtime.conf mkdir -p %{buildroot}%{_mandir}/man1 install -m 0644 %{_builddir}/usr/share/man/man1/swift.1 %{buildroot}%{_mandir}/man1 @@ -168,15 +179,34 @@ install -m 0644 %{_builddir}/usr/share/man/man1/swift.1 %{buildroot}%{_mandir}/m %{_bindir}/swift* %{_mandir}/man1/* /usr/lib/swift-lldb/ -/usr/lib/swift/ +/usr/lib/swift/Block/ +/usr/lib/swift/CoreFoundation/ +/usr/lib/swift/clang/ +/usr/lib/swift/dispatch/ +/usr/lib/swift/migrator/ +/usr/lib/swift/os/ +/usr/lib/swift/pm/ +/usr/lib/swift/shims/ +/usr/lib/swift/linux/x86_64/ /usr/lib/swift_static/ %{_libexecdir}/swift-lldb/ %{_sysconfdir}/ld.so.conf.d/swift-lang.conf + +%files runtime +/usr/lib/swift/linux/*.so +%{_sysconfdir}/ld.so.conf.d/swift-lang-runtime.conf + + %post -p /sbin/ldconfig %postun -p /sbin/ldconfig + %changelog +* Mon Jul 03 2018 Ron Olson 4.2-0.26.20180703git107e307 +- Updated to swift-4.2-DEVELOPMENT-SNAPSHOT-2018-07-03-a, added a + filter for excluding lldb libraries from public view, and broke out the + runtime libraries into their own -runtime package. * Mon Jul 02 2018 Ron Olson 4.2-0.25.20180702gitc2e1567 - Updated to swift-4.2-DEVELOPMENT-SNAPSHOT-2018-07-02-a * Mon Jul 02 2018 Ron Olson 4.2-0.24.20180701git6079032 -- cgit