Merge branch 'master' into epel7

This commit is contained in:
Josh Stone 2017-04-27 16:15:57 -07:00
commit 10f2e52a1e
4 changed files with 85 additions and 45 deletions

8
.gitignore vendored
View File

@ -43,3 +43,11 @@
/rust-1.15.1-s390x-unknown-linux-gnu.tar.gz
/rust-1.15.1-x86_64-unknown-linux-gnu.tar.gz
/rustc-1.16.0-src.tar.gz
/rustc-1.17.0-src.tar.gz
/rust-1.16.0-aarch64-unknown-linux-gnu.tar.gz
/rust-1.16.0-armv7-unknown-linux-gnueabihf.tar.gz
/rust-1.16.0-i686-unknown-linux-gnu.tar.gz
/rust-1.16.0-powerpc64le-unknown-linux-gnu.tar.gz
/rust-1.16.0-powerpc64-unknown-linux-gnu.tar.gz
/rust-1.16.0-s390x-unknown-linux-gnu.tar.gz
/rust-1.16.0-x86_64-unknown-linux-gnu.tar.gz

104
rust.spec
View File

@ -8,10 +8,10 @@
# To bootstrap from scratch, set the channel and date from src/stage0.txt
# e.g. 1.10.0 wants rustc: 1.9.0-2016-05-24
# or nightly wants some beta-YYYY-MM-DD
%global bootstrap_rust 1.15.1
%global bootstrap_cargo 0.16.0
%global bootstrap_rust 1.16.0
%global bootstrap_cargo 0.17.0
%global bootstrap_channel %{bootstrap_rust}
%global bootstrap_date 2017-02-09
%global bootstrap_date 2017-03-11
# Only the specified arches will use bootstrap binaries.
#global bootstrap_arches %%{rust_arches}
@ -26,23 +26,28 @@
# We can also choose to just use Rust's bundled LLVM, in case the system LLVM
# is insufficient. Rust currently requires LLVM 3.7+.
%if 0%{?rhel}
%if 0%{?rhel} && !0%{?epel}
%bcond_without bundled_llvm
%else
%bcond_with bundled_llvm
%endif
# LLDB only works on some architectures
%ifarch %{arm} aarch64 %{ix86} x86_64
# LLDB isn't available everywhere...
%if 0%{?rhel}
%bcond_with lldb
%else
%if !0%{?rhel}
%bcond_without lldb
%else
%bcond_with lldb
%endif
%else
%bcond_with lldb
%endif
Name: rust
Version: 1.16.0
Version: 1.17.0
Release: 1%{?dist}
Summary: The Rust Programming Language
License: (ASL 2.0 or MIT) and (BSD and ISC and MIT)
@ -115,22 +120,28 @@ BuildRequires: zlib-devel
BuildRequires: python2
BuildRequires: curl
%if %with bundled_llvm
%if 0%{?epel}
BuildRequires: cmake3
%else
BuildRequires: cmake
%endif
%if %with bundled_llvm
Provides: bundled(llvm) = 3.9
%else
BuildRequires: llvm-devel >= 3.7
%if 0%{?fedora} >= 26 || 0%{?epel}
%global llvm llvm3.9
%global llvm_root %{_libdir}/%{llvm}
%else
%global llvm llvm
%global llvm_root %{_prefix}
%endif
BuildRequires: %{llvm}-devel >= 3.7
%if %with llvm_static
BuildRequires: llvm-static
BuildRequires: %{llvm}-static
BuildRequires: libffi-devel
%else
# Make sure llvm-config doesn't see it.
BuildConflicts: llvm-static
BuildConflicts: %{llvm}-static
%endif
%endif
@ -178,6 +189,14 @@ Requires: rust-rpm-macros
%global _find_debuginfo_opts -g
%undefine _include_minidebuginfo
# Use hardening ldflags.
%global rustflags -Clink-arg=-Wl,-z,relro,-z,now
%if %{without bundled_llvm} && "%{llvm_root}" != "%{_prefix}"
# https://github.com/rust-lang/rust/issues/40717
%global rustflags %{rustflags} -Clink-arg=-L%{llvm_root}/lib
%endif
%description
Rust is a systems programming language that runs blazingly fast, prevents
segfaults, and guarantees thread safety.
@ -193,10 +212,19 @@ This package includes the standard libraries for building applications
written in Rust.
%package debugger-common
Summary: Common debugger pretty printers for Rust
BuildArch: noarch
%description debugger-common
This package includes the common functionality for %{name}-gdb and %{name}-lldb.
%package gdb
Summary: GDB pretty printers for Rust
BuildArch: noarch
Requires: gdb
Requires: %{name}-debugger-common = %{version}-%{release}
%description gdb
This package includes the rust-gdb script, which allows easier debugging of Rust
@ -207,8 +235,13 @@ programs.
%package lldb
Summary: LLDB pretty printers for Rust
BuildArch: noarch
# It could be noarch, but lldb has limited availability
#BuildArch: noarch
Requires: lldb
Requires: python-lldb
Requires: %{name}-debugger-common = %{version}-%{release}
%description lldb
This package includes the rust-lldb script, which allows easier debugging of Rust
@ -259,7 +292,7 @@ sed -i.jemalloc -e '1i // ignore-test jemalloc is disabled' \
src/test/compile-fail/allocator-rust-dylib-is-jemalloc.rs \
src/test/run-pass/allocator-default.rs
%if 0%{?epel}
%if %{with bundled_llvm} && 0%{?epel}
mkdir -p cmake-bin
ln -s /usr/bin/cmake3 cmake-bin/cmake
%global cmake_path $PWD/cmake-bin
@ -278,9 +311,6 @@ sed -i.ffi -e '$a #[link(name = "ffi")] extern {}' \
%build
%{?cmake_path:export PATH=%{cmake_path}:$PATH}
# Use hardening ldflags.
%global rustflags -Clink-arg=-Wl,-z,relro,-z,now
export RUSTFLAGS="%{rustflags}"
# We're going to override --libdir when configuring to get rustlib into a
@ -292,7 +322,7 @@ export RUSTFLAGS="%{rustflags}"
--libdir=%{common_libdir} \
--build=%{rust_triple} --host=%{rust_triple} --target=%{rust_triple} \
--enable-local-rust --local-rust-root=%{local_rust_root} \
%{!?with_bundled_llvm: --llvm-root=%{_prefix} --disable-codegen-tests \
%{!?with_bundled_llvm: --llvm-root=%{llvm_root} --disable-codegen-tests \
%{!?with_llvm_static: --enable-llvm-link-shared } } \
--disable-jemalloc \
--disable-rpath \
@ -300,14 +330,14 @@ export RUSTFLAGS="%{rustflags}"
--enable-vendor \
--release-channel=%{channel}
%make_build %{!?rhel:-Onone}
./x.py dist
%install
%{?cmake_path:export PATH=%{cmake_path}:$PATH}
export RUSTFLAGS="%{rustflags}"
%make_install
DESTDIR=%{buildroot} ./x.py dist --install
# The libdir libraries are identical to those under rustlib/, and we need
# the latter in place to support dynamic linking for compiler plugins, so we'll
@ -346,10 +376,8 @@ rm -f %{buildroot}%{rustlibdir}/etc/lldb_*.py*
%{?cmake_path:export PATH=%{cmake_path}:$PATH}
export RUSTFLAGS="%{rustflags}"
# Note, many of the tests execute in parallel threads,
# so it's better not to use a parallel make here.
# The results are not stable on koji, so mask errors and just log it.
make check || :
./x.py test || :
%post -p /sbin/ldconfig
@ -379,36 +407,40 @@ make check || :
%{rustlibdir}/%{rust_triple}/lib/*.rlib
%files gdb
%{_bindir}/rust-gdb
%files debugger-common
%dir %{rustlibdir}
%dir %{rustlibdir}/etc
%{rustlibdir}/etc/debugger_*.py*
%files gdb
%{_bindir}/rust-gdb
%{rustlibdir}/etc/gdb_*.py*
%if %with lldb
%files lldb
%{_bindir}/rust-lldb
%dir %{rustlibdir}
%dir %{rustlibdir}/etc
%{rustlibdir}/etc/debugger_*.py*
%{rustlibdir}/etc/lldb_*.py*
%endif
%files doc
%docdir %{_docdir}/%{name}
%dir %{_docdir}/%{name}
%license %{_docdir}/%{name}/html/FiraSans-LICENSE.txt
%license %{_docdir}/%{name}/html/Heuristica-LICENSE.txt
%license %{_docdir}/%{name}/html/LICENSE-APACHE.txt
%license %{_docdir}/%{name}/html/LICENSE-MIT.txt
%license %{_docdir}/%{name}/html/SourceCodePro-LICENSE.txt
%license %{_docdir}/%{name}/html/SourceSerifPro-LICENSE.txt
%doc %{_docdir}/%{name}/html/
%dir %{_docdir}/%{name}/html
%{_docdir}/%{name}/html/*/
%{_docdir}/%{name}/html/*.html
%{_docdir}/%{name}/html/*.css
%{_docdir}/%{name}/html/*.js
%{_docdir}/%{name}/html/*.woff
%license %{_docdir}/%{name}/html/*.txt
%changelog
* Thu Apr 27 2017 Josh Stone <jistone@redhat.com> - 1.17.0-1
- Update to 1.17.0.
* Thu Mar 16 2017 Josh Stone <jistone@redhat.com> - 1.16.0-1
- Update to 1.16.0.
- Use rustbuild instead of the old makefiles.

View File

@ -1 +1 @@
SHA512 (rustc-1.16.0-src.tar.gz) = 096b1b7406be9bc61161bb7cdd2061f2bc2174c161a31f4ed6ceecf7fc379f315fc2f7cb9f6c134ea4f8519c27bf6e5a3f712cf1e56d5785831d8c8374eb0ba5
SHA512 (rustc-1.17.0-src.tar.gz) = 781799b29d83b4f0f433814bd818df034526db8e7f88c2df51d3b814eacafe8098d4bbe47ace951e1943325b3267b244007cf04f1f11083645b25aeacd40ebb6

View File

@ -1,8 +1,8 @@
SHA512 (rustc-1.16.0-src.tar.gz) = 096b1b7406be9bc61161bb7cdd2061f2bc2174c161a31f4ed6ceecf7fc379f315fc2f7cb9f6c134ea4f8519c27bf6e5a3f712cf1e56d5785831d8c8374eb0ba5
SHA512 (rust-1.15.1-aarch64-unknown-linux-gnu.tar.gz) = 734103680ffdc175a5a5f3278a338f839031119aa16c2440bee18668e9dffefe470aab1d78d13377e2e0bbd726b2044402aac6369d66653bf1715f4638f61693
SHA512 (rust-1.15.1-armv7-unknown-linux-gnueabihf.tar.gz) = d3606e416571e741857c834bc8080e985e3269856577d342eebd2ebef2b7c3e6c0d085c2d03059a880f2e32c835f6d69277953eeac86b897bd67f4fc8893d961
SHA512 (rust-1.15.1-i686-unknown-linux-gnu.tar.gz) = 13d602842e7a2ef360c80d3ec84ecd5d6c742ea6dad642394a2a57b28554a7758905b37daaf2bcc549428c5f9383307270f8508e8685748b906fc2b9230bc4ad
SHA512 (rust-1.15.1-powerpc64le-unknown-linux-gnu.tar.gz) = e2608b6e9b34aa1c5f3de09a4785e4efe67170af06fa9f975b096d64e7debd012952e8c5c54d067ad0ed2704acb5cf1b62721e0e3f14a767fa61b1cd51f6bad2
SHA512 (rust-1.15.1-powerpc64-unknown-linux-gnu.tar.gz) = 33552de33ad63330cb6e104f77105bf9b16eb20e43b8dee3303032b14e2540ac58b27f59e4ad5bb4c87f76a891c59e188a074db48e2e95ef4463d274d5721269
SHA512 (rust-1.15.1-s390x-unknown-linux-gnu.tar.gz) = 083ad5b3cdaf5d7b56d4a6b02dbca8bbb9b0fb9a79a5d4799e5e6295a9a1248eef0ddb05df780f611b80537bd0372f47a2bbbe23063cd00c5eac616dd29eb043
SHA512 (rust-1.15.1-x86_64-unknown-linux-gnu.tar.gz) = e089c455b1a7507aeed4652f05c0672c4e996e708c46f4405191f4b3a9d08403cab27f1a5a63f865d9a8f099f6ca980d2d2eef37aaa5e7e5bd751a3224e88b84
SHA512 (rustc-1.17.0-src.tar.gz) = 781799b29d83b4f0f433814bd818df034526db8e7f88c2df51d3b814eacafe8098d4bbe47ace951e1943325b3267b244007cf04f1f11083645b25aeacd40ebb6
SHA512 (rust-1.16.0-aarch64-unknown-linux-gnu.tar.gz) = 6f1cd5a9884c2a595c43fda7ce283035ebe901510615006163eba3dea757169ca76239b2c64b506d2c396debb01b4bfe8d7b1c5ea9138ba646bb19f5a55b33bc
SHA512 (rust-1.16.0-armv7-unknown-linux-gnueabihf.tar.gz) = 4aead298cec7c25c256da84be22790eb38e527f4478d180ccb7cffaf88736c4f7e762a30deba53e14feda049b1814ccdd91c38a86ce2106d8518de4079740739
SHA512 (rust-1.16.0-i686-unknown-linux-gnu.tar.gz) = 7a780a107d98c6a8883f95dbb5a5ec95bad52fb1e735afba29b47411b450d464cbc8dfe73d35de1eb18b9a1f9ea727daa1ca9d3042e2a98c67ad570d328e139d
SHA512 (rust-1.16.0-powerpc64le-unknown-linux-gnu.tar.gz) = e1afc94bc6f80eeb6371d7037afd3fdaea189b6d0c2c5b569f6fb5976d7a7d105da57d2cf46b067a418f15083e62418fe6f3d6b40f6e2357d018b692fdb3a1a7
SHA512 (rust-1.16.0-powerpc64-unknown-linux-gnu.tar.gz) = e93a509a84c433893c7ceb68720bbc30f097afd933178dc513273a32d3c6a37b4e234c11216bf730ac4fa28fc1ce9538b7e0ecde46c165145e72171a2cb7170a
SHA512 (rust-1.16.0-s390x-unknown-linux-gnu.tar.gz) = 45184f2b4d6ed21c90bef96380008d4787effa46986172053b366f7424e22c097577e720c88faa2acfbbb7dd41ed36596bfc691dcd8bf8d96278e34ec75666a2
SHA512 (rust-1.16.0-x86_64-unknown-linux-gnu.tar.gz) = f3d381c0e47e0af02eb116376422c3e48295c2854c6ad8c03d4c13e662f3cc1fdddf25923f7b3ef358c5cf670ed67d75e2197162434a81d5f9499e6e0e2d1054