[packages/crystal] setup bootstrap build
glen
glen at pld-linux.org
Fri Feb 22 22:11:02 CET 2019
commit 68c34ff2b51ac56e8eef8f40ef78467f66bb810c
Author: Elan Ruusamäe <glen at pld-linux.org>
Date: Fri Feb 22 23:10:14 2019 +0200
setup bootstrap build
crystal.spec | 13 ++++++++++++-
1 file changed, 12 insertions(+), 1 deletion(-)
---
diff --git a/crystal.spec b/crystal.spec
index f15fcf0..55417f0 100644
--- a/crystal.spec
+++ b/crystal.spec
@@ -1,7 +1,10 @@
#
# Conditional build:
+%bcond_with bootstrap # bootstrap build
%bcond_without tests # build without tests
+# this probably does not have to be very latest
+%define bootstrap_ver 0.27.2
Summary: Crystal Programming Language
Name: crystal
Version: 0.27.2
@@ -10,7 +13,10 @@ License: Apache v2.0
Group: Development/Languages
Source0: https://github.com/crystal-lang/crystal/archive/%{version}/%{name}-%{version}.tar.gz
# Source0-md5: 67ff7bdfc67c3b0ad2d7ea2e89753c68
+Source1: https://github.com/crystal-lang/crystal/releases/download/%{bootstrap_ver}/%{name}-%{bootstrap_ver}-1-linux-x86_64.tar.gz
+# Source1-md5: e382b8e6d60eb748dbad3d7ee59843a4
URL: https://crystal-lang.org/
+%{!?with_bootstrap:BuildRequires: crystal}
BuildRequires: gmp-devel
BuildRequires: libbsd-devel
BuildRequires: libedit-devel
@@ -21,6 +27,7 @@ BuildRequires: llvm-devel >= 3.8
BuildRequires: openssl-devel
BuildRequires: readline-devel
BuildRequires: yaml-devel
+ExclusiveArch: %{x8664}
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
%description
@@ -37,9 +44,13 @@ Crystal is a programming language with the following goals:
- Compile to efficient native code.
%prep
-%setup -q
+%setup -q %{?with_bootstrap:-a1}
%build
+%if %{with bootstrao}
+PATH=$PATH:crystal-%{bootstrap_ver}-1/bin
+%endif
+
CFLAGS="%{rpmcflags}" \
CXXFLAGS="%{rpmcxxflags}" \
%{__make} \
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/crystal.git/commitdiff/68c34ff2b51ac56e8eef8f40ef78467f66bb810c
More information about the pld-cvs-commit
mailing list