2018-03-23 10:32:36 +01:00
|
|
|
#
|
|
|
|
# spec file for package alacritty
|
|
|
|
#
|
|
|
|
# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
|
|
|
|
#
|
|
|
|
# All modifications and additions to the file contributed by third parties
|
|
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
|
|
# upon. The license for this file, and modifications and additions to the
|
|
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
|
|
# license for the pristine package is not an Open Source License, in which
|
|
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
|
|
# published by the Open Source Initiative.
|
|
|
|
|
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
|
|
#
|
|
|
|
|
|
|
|
|
2018-03-25 07:04:17 +02:00
|
|
|
%define rev dcc4b750381cd2096b6001cbf94e95a6e6b52ed0
|
2018-03-23 10:32:36 +01:00
|
|
|
Name: alacritty
|
|
|
|
Version: 0.1.0
|
|
|
|
Release: 0
|
2018-03-28 14:01:25 +02:00
|
|
|
Summary: A GPU-accelerated terminal emulator
|
2018-03-23 10:32:36 +01:00
|
|
|
License: Apache-2.0
|
|
|
|
Group: System/X11/Terminals
|
|
|
|
URL: https://github.com/jwilm/alacritty/
|
|
|
|
Source: https://github.com/jwilm/alacritty/archive/%{rev}.tar.gz#/%{name}-%{version}.tar.gz
|
|
|
|
Source1: vendor.tar.xz
|
|
|
|
BuildRequires: cargo
|
|
|
|
BuildRequires: cmake
|
|
|
|
BuildRequires: fontconfig-devel
|
|
|
|
BuildRequires: freetype-devel
|
|
|
|
BuildRequires: rust
|
|
|
|
BuildRequires: rust-std
|
|
|
|
BuildRequires: xclip
|
|
|
|
|
|
|
|
%description
|
2018-03-25 21:00:29 +02:00
|
|
|
Alacritty is a terminal emulator written in Rust that leverages the GPU for
|
|
|
|
rendering.
|
2018-03-23 10:32:36 +01:00
|
|
|
|
|
|
|
%package bash-completion
|
|
|
|
Summary: Bash Completion for %{name}
|
2018-04-30 14:13:24 +02:00
|
|
|
Group: System/X11/Terminals
|
2018-03-23 10:32:36 +01:00
|
|
|
Requires: bash-completion
|
|
|
|
Supplements: packageand(%{name}:bash)
|
|
|
|
BuildArch: noarch
|
|
|
|
|
|
|
|
%description bash-completion
|
|
|
|
The official bash completion script for alacritty. It includes support
|
|
|
|
for every argument that can currently be passed to alacritty.
|
|
|
|
|
|
|
|
%package fish-completion
|
|
|
|
Summary: Fish Completion for %{name}
|
2018-04-30 14:13:24 +02:00
|
|
|
Group: System/X11/Terminals
|
2018-03-23 10:32:36 +01:00
|
|
|
Supplements: packageand(%{name}:fish)
|
|
|
|
BuildArch: noarch
|
|
|
|
|
|
|
|
%description fish-completion
|
|
|
|
The official fish completion script for alacritty.
|
|
|
|
|
|
|
|
%package zsh-completion
|
|
|
|
Summary: ZSH Completion for %{name}
|
2018-04-30 14:13:24 +02:00
|
|
|
Group: System/X11/Terminals
|
2018-03-23 10:32:36 +01:00
|
|
|
Supplements: packageand(%{name}:zsh)
|
|
|
|
BuildArch: noarch
|
|
|
|
|
|
|
|
%description zsh-completion
|
|
|
|
The official zsh completion script for alacritty.
|
|
|
|
|
|
|
|
%prep
|
2018-03-28 14:01:25 +02:00
|
|
|
%setup -q -n %{name}-%{rev} -a1
|
2018-03-23 10:32:36 +01:00
|
|
|
mkdir cargo-home
|
|
|
|
cat >cargo-home/config <<EOF
|
|
|
|
[source.crates-io]
|
|
|
|
replace-with = "vendored-sources"
|
|
|
|
|
|
|
|
[source."https://github.com/jwilm/libfontconfig"]
|
|
|
|
git = "https://github.com/jwilm/libfontconfig"
|
|
|
|
branch = "updated-2017-10-8"
|
|
|
|
replace-with = "vendored-sources"
|
|
|
|
|
|
|
|
[source."https://github.com/jwilm/rust-fontconfig"]
|
|
|
|
git = "https://github.com/jwilm/rust-fontconfig"
|
|
|
|
branch = "updated-2017-10-8"
|
|
|
|
replace-with = "vendored-sources"
|
|
|
|
|
|
|
|
[source.vendored-sources]
|
|
|
|
directory = "./vendor"
|
|
|
|
EOF
|
2018-04-30 14:13:24 +02:00
|
|
|
%ifarch aarch64 ppc64le
|
|
|
|
# Remove checksum of config.guess and config.sub since aarch64 and ppc64le modify them
|
|
|
|
sed -i 's#"expat/conftools/config.guess":"ebaffe1c6683ae2c3dcabb87825a83b892f00391514756f7640c4a3dcafbad4f",##g' ./vendor/expat-sys/.cargo-checksum.json
|
|
|
|
sed -i 's#"expat/conftools/config.sub":"523cb028db907d1fbbcecdcac6737f9e2eeba48fb639231dbc5ae69238f276c9",##g' ./vendor/expat-sys/.cargo-checksum.json
|
|
|
|
%endif
|
2018-03-23 10:32:36 +01:00
|
|
|
|
|
|
|
%build
|
|
|
|
export CARGO_HOME=$PWD/cargo-home
|
|
|
|
cargo build --release %{?_smp_mflags}
|
|
|
|
|
|
|
|
%install
|
|
|
|
export CARGO_HOME=$PWD/cargo-home
|
|
|
|
cargo install --root=%{buildroot}/%{_prefix}
|
|
|
|
|
|
|
|
# rm duplicate license and useless toml file
|
|
|
|
rm -fr %{buildroot}%{_datadir}
|
|
|
|
rm %{buildroot}%{_prefix}/.crates.toml
|
|
|
|
|
|
|
|
# install man page and completions
|
|
|
|
install -Dm 0644 %{name}.man %{buildroot}/%{_mandir}/man1/%{name}.1
|
|
|
|
install -Dm 0644 %{name}-completions.bash %{buildroot}/%{_datadir}/bash-completion/completions/%{name}
|
|
|
|
install -Dm 0644 %{name}-completions.fish %{buildroot}/%{_datadir}/fish/vendor_completions.d/%{name}.fish
|
|
|
|
install -Dm 0644 %{name}-completions.zsh %{buildroot}/%{_datadir}/zsh/site-functions/_%{name}
|
|
|
|
|
|
|
|
%files
|
|
|
|
%license LICENSE-APACHE
|
|
|
|
%{_bindir}/%{name}
|
|
|
|
%{_mandir}/man1/%{name}.1%{?ext_man}
|
|
|
|
|
|
|
|
%files bash-completion
|
|
|
|
%{_datadir}/bash-completion
|
|
|
|
|
|
|
|
%files fish-completion
|
|
|
|
%{_datadir}/fish
|
|
|
|
|
|
|
|
%files zsh-completion
|
|
|
|
%{_datadir}/zsh
|
|
|
|
|
|
|
|
%changelog
|