summaryrefslogtreecommitdiffstats
path: root/swift-lang.spec
blob: 9c9464a5e5a4004a34a1ca1a2c6c036766580f2f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
%global debug_package %{nil}
%global swifttag DEVELOPMENT-SNAPSHOT-2018-01-17-a
Name:           swift-lang
Version:        4.1
Release:        0.20180117git1381d08%{?dist}
Summary:        Apple's Swift programming language
License:        ASL 2.0
URL:            https://swift.org
Source0:        https://github.com/apple/swift/archive/swift-%{swifttag}.tar.gz#/swift.tar.gz
Source1:        https://github.com/apple/swift-compiler-rt/archive/swift-%{swifttag}.tar.gz#/swift-compiler-rt.tar.gz
Source2:        https://github.com/apple/swift-corelibs-libdispatch/archive/swift-%{swifttag}.tar.gz#/corelibs-libdispatch.tar.gz
Source3:        https://github.com/apple/swift-corelibs-foundation/archive/swift-%{swifttag}.tar.gz#/corelibs-foundation.tar.gz
Source4:        https://github.com/apple/swift-integration-tests/archive/swift-%{swifttag}.tar.gz#/swift-integration-tests.tar.gz
Source5:        https://github.com/apple/swift-corelibs-xctest/archive/swift-%{swifttag}.tar.gz#/corelibs-xctest.tar.gz
Source6:        https://github.com/apple/swift-clang/archive/swift-%{swifttag}.tar.gz#/clang.tar.gz
Source7:        https://github.com/apple/swift-package-manager/archive/swift-%{swifttag}.tar.gz#/package-manager.tar.gz
Source8:        https://github.com/apple/swift-lldb/archive/swift-%{swifttag}.tar.gz#/lldb.tar.gz
Source9:        https://github.com/apple/swift-llvm/archive/swift-%{swifttag}.tar.gz#/llvm.tar.gz
Source10:       https://github.com/apple/swift-llbuild/archive/swift-%{swifttag}.tar.gz#/llbuild.tar.gz
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:       https://github.com/ninja-build/ninja/archive/v1.7.2.tar.gz#/ninja.tar.gz
BuildRequires: clang,libicu-devel,gcc-c++,cmake,libuuid-devel,libedit-devel,swig,pkgconfig,libbsd-devel,libxml2-devel,libsqlite3x-devel,python-devel,libblocksruntime-static,libatomic-static,libcurl-devel,perl-podlators
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 
patterns.

The goal of the Swift project is to create the best available 
language for uses ranging from systems programming, to mobile 
and desktop apps, scaling up to cloud services. Most 
importantly, Swift is designed to make writing and maintaining 
correct programs easier for the developer. 

%prep
%setup -q -c swift -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 -a 13

# The Swift build script requires directories to be named
# in a specific way so renaming the source directories is
# necessary
mv swift-clang-swift-%{swifttag} clang
mv swift-cmark-swift-%{swifttag} cmark
mv swift-compiler-rt-swift-%{swifttag} compiler-rt
mv swift-corelibs-foundation-swift-%{swifttag} swift-corelibs-foundation
mv swift-corelibs-libdispatch-swift-%{swifttag} swift-corelibs-libdispatch
mv swift-corelibs-xctest-swift-%{swifttag} swift-corelibs-xctest
mv swift-integration-tests-swift-%{swifttag} swift-integration-tests
mv swift-llbuild-swift-%{swifttag} llbuild
mv swift-lldb-swift-%{swifttag} lldb
mv swift-llvm-swift-%{swifttag} llvm
mv swift-package-manager-swift-%{swifttag} swiftpm
mv swift-swift-%{swifttag} swift
mv swift-xcode-playground-support-swift-%{swifttag} swift-xcode-playground-support
mv ninja-1.7.2 ninja

%build
swift/utils/build-script --preset=buildbot_linux,no_test install_destdir=%{buildroot} installable_package=%{buildroot}/swift-%{version}-fedora.tar.gz

%files
%exclude /swift-%{version}-fedora.tar.gz
%{_bindir}/*
%{_mandir}/man1/*
%{_datarootdir}/swift/LICENSE.txt
%{_includedir}/*
%{_usr}/lib/*

%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig

%changelog
* Tue Jan 16 2018 Ron Olson <tachoknight@gmail.com> 4.1-1-0.20180117git1381d08
- Initial package for Fedora