1 |
commit: fd96ea70c618437312b122ae3cf5c9922f1f2565 |
2 |
Author: Sergei Trofimovich <slyfox <AT> gentoo <DOT> org> |
3 |
AuthorDate: Wed Jan 30 22:49:03 2019 +0000 |
4 |
Commit: Sergei Trofimovich <slyfox <AT> gentoo <DOT> org> |
5 |
CommitDate: Thu Jan 31 07:20:25 2019 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=fd96ea70 |
7 |
|
8 |
dev-lang/crystal: bump up to 0.27.1 |
9 |
|
10 |
Package-Manager: Portage-2.3.59, Repoman-2.3.12 |
11 |
Signed-off-by: Sergei Trofimovich <slyfox <AT> gentoo.org> |
12 |
|
13 |
dev-lang/crystal/Manifest | 1 + |
14 |
dev-lang/crystal/crystal-0.27.1.ebuild | 121 +++++++++++++++++++++ |
15 |
.../crystal/files/crystal-0.27.1-verbose.patch | 7 ++ |
16 |
3 files changed, 129 insertions(+) |
17 |
|
18 |
diff --git a/dev-lang/crystal/Manifest b/dev-lang/crystal/Manifest |
19 |
index 7c76aef7d30..db092cd4722 100644 |
20 |
--- a/dev-lang/crystal/Manifest |
21 |
+++ b/dev-lang/crystal/Manifest |
22 |
@@ -13,3 +13,4 @@ DIST crystal-0.26.1.tar.gz 1994987 BLAKE2B 2292fbdf119e181313000e035802581ae2060 |
23 |
DIST crystal-0.27.0-1-linux-i686.tar.gz 39751745 BLAKE2B 22adf22a2e423f4b0fddda1d8d9bbfb68a4b51f18da9705b6515a500610781251561577dd25c6509aa2b6860b1b329bc7e3d213743330b91206b50239e053a89 SHA512 4fb819a67f3e2c965b454af53cf0bad9606a6a13f85f1bfbe59057291ea293099892344cd31127f5b35e3b25fc6e3f591bda508587fc32f5ef1433aeff0ca706 |
24 |
DIST crystal-0.27.0-1-linux-x86_64.tar.gz 37933811 BLAKE2B 76bb57b556f14ae8ce219ef490e58ff03571f36fcb4343672ff10ddd6e275e9c5c26a028d63f0592c1a081f2f5dc8241106d8a99add1a7936f52b9e3a57f96e6 SHA512 c403c4080830b928621da07f409ba5433109ee0fc81589f87e79d2e04fcbce8facfa205b7e8c78ab9bb772b4444c938b3bcf691596ee0b2d54c3f3d97150e008 |
25 |
DIST crystal-0.27.0.tar.gz 2025777 BLAKE2B 0a5cc02a516586b033c65efd8e28a13ac0ed67fddbd1a1f0a88a484dff825bec8f6b03b16938c750e99e0c7c1c12a3fd3fc87e61d038b25b7707e0e7f2913fae SHA512 02b0e1d43d699d1dd91f4b979c8ab8909264e5f1fcc344f6110bebb808c0ee764a943368cce9d33a258adb9631ed4f445e1f771d5a9e50fcd337fc8b319616cf |
26 |
+DIST crystal-0.27.1.tar.gz 2061304 BLAKE2B 1776525925a25f72cf83f1a6076ab8b2bf1602c9d8c6a1fff8869c200faa35de008655f046ff60fb3733c8c3577f3544184080ee39acedfde006b9fd63d6c844 SHA512 8c6dd9489aff5d4b3e119ef6f531a3248c20f3da97c44dd3febe551adc67f5d87aa4f7679cbcc0dcde0374f3f5a3c523da6dff32a7ac95a9db1406102e980822 |
27 |
|
28 |
diff --git a/dev-lang/crystal/crystal-0.27.1.ebuild b/dev-lang/crystal/crystal-0.27.1.ebuild |
29 |
new file mode 100644 |
30 |
index 00000000000..d1888dfde89 |
31 |
--- /dev/null |
32 |
+++ b/dev-lang/crystal/crystal-0.27.1.ebuild |
33 |
@@ -0,0 +1,121 @@ |
34 |
+# Copyright 1999-2019 Gentoo Authors |
35 |
+# Distributed under the terms of the GNU General Public License v2 |
36 |
+ |
37 |
+EAPI=6 |
38 |
+ |
39 |
+inherit bash-completion-r1 llvm multiprocessing toolchain-funcs |
40 |
+ |
41 |
+BV=0.27.0-1 |
42 |
+BV_AMD64=${BV}-linux-x86_64 |
43 |
+BV_X86=${BV}-linux-i686 |
44 |
+ |
45 |
+DESCRIPTION="The Crystal Programming Language" |
46 |
+HOMEPAGE="https://crystal-lang.org" |
47 |
+SRC_URI="https://github.com/crystal-lang/crystal/archive/${PV}.tar.gz -> ${P}.tar.gz |
48 |
+ amd64? ( https://github.com/crystal-lang/crystal/releases/download/${BV/-*}/crystal-${BV_AMD64}.tar.gz ) |
49 |
+ x86? ( https://github.com/crystal-lang/crystal/releases/download/${BV/-*}/crystal-${BV_X86}.tar.gz )" |
50 |
+ |
51 |
+LICENSE="Apache-2.0" |
52 |
+SLOT="0" |
53 |
+KEYWORDS="~amd64" |
54 |
+IUSE="doc debug examples blocking-stdio-hack +xml +yaml" |
55 |
+ |
56 |
+# Not compatible with llvm-7 |
57 |
+LLVM_MAX_SLOT=6 |
58 |
+ |
59 |
+# dev-libs/boehm-gc[static-libs] dependency problem, check the issue: https://github.com/manastech/crystal/issues/1382 |
60 |
+DEPEND=" |
61 |
+ sys-devel/llvm:${LLVM_MAX_SLOT} |
62 |
+ dev-libs/boehm-gc[static-libs,threads] |
63 |
+ dev-libs/libatomic_ops |
64 |
+ dev-libs/libevent |
65 |
+ dev-libs/libpcre |
66 |
+ sys-libs/libunwind |
67 |
+ dev-libs/pcl |
68 |
+ dev-libs/gmp:0 |
69 |
+" |
70 |
+RDEPEND="${DEPEND} |
71 |
+ xml? ( dev-libs/libxml2 ) |
72 |
+ yaml? ( dev-libs/libyaml ) |
73 |
+" |
74 |
+ |
75 |
+PATCHES=( |
76 |
+ "${FILESDIR}"/${PN}-0.27.1-verbose.patch |
77 |
+ "${FILESDIR}"/${PN}-0.26.1-gentoo-tests-sandbox.patch |
78 |
+ "${FILESDIR}"/${PN}-0.26.1-gentoo-tests-network-sandbox-3.patch |
79 |
+ "${FILESDIR}"/${PN}-0.27.0-extra-spec-flags.patch |
80 |
+ "${FILESDIR}"/${PN}-0.27.0-max-age-0-test.patch |
81 |
+ "${FILESDIR}"/${PN}-0.27.0-gentoo-tests-long-unix.patch |
82 |
+ "${FILESDIR}"/${PN}-0.27.0-gentoo-tests-long-unix-2.patch |
83 |
+ "${FILESDIR}"/${PN}-0.27.0-tcp-server-test.patch |
84 |
+) |
85 |
+ |
86 |
+src_prepare() { |
87 |
+ default |
88 |
+ |
89 |
+ use blocking-stdio-hack && eapply "${FILESDIR}"/"${PN}"-0.22.0-blocking-stdio-hack.patch |
90 |
+} |
91 |
+ |
92 |
+src_compile() { |
93 |
+ local bootstrap_path=${WORKDIR}/${PN}-${BV}/bin |
94 |
+ if [[ ! -d ${bootstrap_path} ]]; then |
95 |
+ eerror "Binary tarball does not contain expected directory:" |
96 |
+ die "'${bootstrap_path}' path does not exist." |
97 |
+ fi |
98 |
+ |
99 |
+ emake \ |
100 |
+ $(usex debug "" release=1) \ |
101 |
+ progress=true \ |
102 |
+ stats=1 \ |
103 |
+ threads=$(makeopts_jobs) \ |
104 |
+ verbose=1 \ |
105 |
+ \ |
106 |
+ CC=$(tc-getCC) \ |
107 |
+ CXX=$(tc-getCXX) \ |
108 |
+ AR=$(tc-getAR) \ |
109 |
+ \ |
110 |
+ PATH="${bootstrap_path}:${PATH}" \ |
111 |
+ CRYSTAL_PATH=src \ |
112 |
+ CRYSTAL_CONFIG_VERSION=${PV} \ |
113 |
+ CRYSTAL_CONFIG_PATH="lib:${EPREFIX}/usr/$(get_libdir)/crystal" |
114 |
+ use doc && emake docs |
115 |
+} |
116 |
+ |
117 |
+src_test() { |
118 |
+ # EXTRA_SPEC_FLAGS is useful to debug individual tests |
119 |
+ # as part of full build: |
120 |
+ # USE=debug EXTRA_SPEC_FLAGS='-e parse_set_cookie' emerge -1 crystal |
121 |
+ emake spec \ |
122 |
+ $(usex debug "" release=1) \ |
123 |
+ progress=true \ |
124 |
+ stats=1 \ |
125 |
+ threads=$(makeopts_jobs) \ |
126 |
+ verbose=1 \ |
127 |
+ \ |
128 |
+ CC=$(tc-getCC) \ |
129 |
+ CXX=$(tc-getCXX) \ |
130 |
+ AR=$(tc-getAR) \ |
131 |
+ \ |
132 |
+ CRYSTAL_PATH=src \ |
133 |
+ CRYSTAL_CONFIG_VERSION=${PV} \ |
134 |
+ \ |
135 |
+ "EXTRA_SPEC_FLAGS=${EXTRA_SPEC_FLAGS}" |
136 |
+} |
137 |
+ |
138 |
+src_install() { |
139 |
+ insinto /usr/$(get_libdir)/crystal |
140 |
+ doins -r src/. |
141 |
+ dobin .build/crystal |
142 |
+ |
143 |
+ insinto /usr/share/zsh/site-functions |
144 |
+ newins etc/completion.zsh _crystal |
145 |
+ |
146 |
+ use examples && dodoc -r samples |
147 |
+ |
148 |
+ if use doc ; then |
149 |
+ docinto api |
150 |
+ dodoc -r docs/. |
151 |
+ fi |
152 |
+ |
153 |
+ newbashcomp etc/completion.bash ${PN} |
154 |
+} |
155 |
|
156 |
diff --git a/dev-lang/crystal/files/crystal-0.27.1-verbose.patch b/dev-lang/crystal/files/crystal-0.27.1-verbose.patch |
157 |
new file mode 100644 |
158 |
index 00000000000..33c3c5d61c4 |
159 |
--- /dev/null |
160 |
+++ b/dev-lang/crystal/files/crystal-0.27.1-verbose.patch |
161 |
@@ -0,0 +1,7 @@ |
162 |
+--- a/Makefile |
163 |
++++ b/Makefile |
164 |
+@@ -29,3 +29,3 @@ SOURCES := $(shell find src -name '*.cr') |
165 |
+ SPEC_SOURCES := $(shell find spec -name '*.cr') |
166 |
+-override FLAGS += -D preview_overflow -D compiler_rt $(if $(release),--release )$(if $(stats),--stats )$(if $(progress),--progress )$(if $(threads),--threads $(threads) )$(if $(debug),-d )$(if $(static),--static )$(if $(LDFLAGS),--link-flags="$(LDFLAGS)" ) |
167 |
++override FLAGS += -D preview_overflow -D compiler_rt $(if $(release),--release )$(if $(stats),--stats )$(if $(progress),--progress )$(if $(threads),--threads $(threads) )$(if $(debug),-d )$(if $(static),--static )$(if $(LDFLAGS),--link-flags="$(LDFLAGS)" )$(if $(verbose),--verbose ) |
168 |
+ SPEC_FLAGS := $(if $(verbose),-v )$(if $(junit_output),--junit_output $(junit_output) ) |