1 |
commit: d3dd554487c3b4517f5e7c4b6cfdb12fe1b19c0f |
2 |
Author: Sergei Trofimovich <slyfox <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sun Sep 2 09:53:10 2018 +0000 |
4 |
Commit: Sergei Trofimovich <slyfox <AT> gentoo <DOT> org> |
5 |
CommitDate: Sun Sep 2 10:53:24 2018 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=d3dd5544 |
7 |
|
8 |
dev-lang/crystal: bump up to 0.26.1 |
9 |
|
10 |
Package-Manager: Portage-2.3.48, Repoman-2.3.10 |
11 |
|
12 |
dev-lang/crystal/Manifest | 3 + |
13 |
dev-lang/crystal/crystal-0.26.1.ebuild | 106 +++++++++++++++++++++ |
14 |
...tal-0.26.1-gentoo-tests-network-sandbox-3.patch | 26 +++++ |
15 |
.../crystal-0.26.1-gentoo-tests-sandbox.patch | 22 +++++ |
16 |
4 files changed, 157 insertions(+) |
17 |
|
18 |
diff --git a/dev-lang/crystal/Manifest b/dev-lang/crystal/Manifest |
19 |
index 7eda964d98e..04860184158 100644 |
20 |
--- a/dev-lang/crystal/Manifest |
21 |
+++ b/dev-lang/crystal/Manifest |
22 |
@@ -6,4 +6,7 @@ DIST crystal-0.24.2.tar.gz 1745462 BLAKE2B 8f3d5cf9e274558a5622aae44c6f7d54d0b30 |
23 |
DIST crystal-0.25.0.tar.gz 1957613 BLAKE2B 4c2467e39a9bc6745b74c00f755490a2f726e775c2a0d15562af27d2a6771c95c44f79e6b59ad45f61a59566529854d75c980c55a6886538fa98663879477258 SHA512 20f2864919c7710e5aee8112e1c6ab54a2e50b244ac63d374edfed41ab659b11c062f76dbfc38e763a08bdbea9e0a39f3b5cac5e00bf453be3a31d3b0a023917 |
24 |
DIST crystal-0.25.1-1-linux-i686.tar.gz 39882213 BLAKE2B 35d0045a72ced6ba7348105c9b88e564f85b075af78decd52c40b47b338cd1c7c1b01565430f9aa21251cfd1266041268e037eb616a24475acfa22b1b8ae1448 SHA512 79601b6c586184e064798c4daca3de77f7c81fbc4d0062a558824533f9272f04899c0041b17dce072757f20f7940c99303c6ff1143448b6452e8216ca4bb43dd |
25 |
DIST crystal-0.25.1-1-linux-x86_64.tar.gz 38004788 BLAKE2B 580ccad2227e6467c4c61ce9adf4aeb99c55f694c71a02b9d959c31deba66e428f5c5e7d920dd42d01524ccaef04b9eae3b068f2c6ff16414fa3fd36f462414f SHA512 ec33781b767f8f9f0a6d00f73109fbe9d683a23fca9cc8b462acda3eb024fc970d0daf8c36fb2239297f77510d2e3f544f58ec1cf53d08ea856bc6307f81d1dd |
26 |
+DIST crystal-0.26.0-1-linux-i686.tar.gz 39814913 BLAKE2B 8c73e33b52a7c5d9ae24ead5d5adbd038f63fc76f904b20ec8dc4da1b1ed6f53283970b06ec7af7ecac7f58c55dc911fe56bcb9897a44a86fc88deb43249a5af SHA512 f0ba602a07b608ac7b3c0f841cbcc70b44d42ce87f405ce9d1a09df7b8c1764e13bca9471b2499a51d22cebc8228e949086893fd3c946d17e7b36ae4e8ac4f75 |
27 |
+DIST crystal-0.26.0-1-linux-x86_64.tar.gz 37986465 BLAKE2B dc8e05519653f82d09d8bd3a84fedd9f4720880bc61a110709643850bbcfa95738292cca8168a8c5c550abe9b178ce28fd59321c66862a1cc81007cc1cb22223 SHA512 c252d2d585fe49c755397b8f8c7965c855e8f8102598b34a83cc6e5ae821a22f3dccce8b7787dd0f00fa39fad3d2dffc23c6105c9cefe525da7855550c790ab2 |
28 |
DIST crystal-0.26.0.tar.gz 1992091 BLAKE2B dfc96e3e9a71dbec07235a982bbb34ea81bb3adbb39f6c8f8c9bb855ac97e5faf4d47d4a78901317798941b84117399aeee6af53c6c06ae21b9504ca617a2899 SHA512 45a62a2496d477cd72666e98b36bdcbfff958a8f5f0e71f04101f2ba72fc87117d53c8c098a72edb55e9be192b68b73529d5f76e4c660033332ed6e88a372519 |
29 |
+DIST crystal-0.26.1.tar.gz 1994987 BLAKE2B 2292fbdf119e181313000e035802581ae206083aa5c9651a01e131d74e701ea75dc713b44274769decfc9f0f300d8fc2e6c24a94f60380b79c3cdb1a10e73369 SHA512 5e020b0f262f9bedaaae60010f669d7987a77d3416bf0dd057e29eb11adbe8fceb1c4f55a822e623d32e302a01ccc99218d2c3fe474d4ce0dde4312c196ccfa6 |
30 |
|
31 |
diff --git a/dev-lang/crystal/crystal-0.26.1.ebuild b/dev-lang/crystal/crystal-0.26.1.ebuild |
32 |
new file mode 100644 |
33 |
index 00000000000..d02b47f0788 |
34 |
--- /dev/null |
35 |
+++ b/dev-lang/crystal/crystal-0.26.1.ebuild |
36 |
@@ -0,0 +1,106 @@ |
37 |
+# Copyright 1999-2018 Gentoo Foundation |
38 |
+# Distributed under the terms of the GNU General Public License v2 |
39 |
+ |
40 |
+EAPI=6 |
41 |
+ |
42 |
+inherit bash-completion-r1 llvm multiprocessing toolchain-funcs |
43 |
+ |
44 |
+BV=0.26.0 |
45 |
+BV_AMD64=${BV}-1-linux-x86_64 |
46 |
+BV_X86=${BV}-1-linux-i686 |
47 |
+ |
48 |
+DESCRIPTION="The Crystal Programming Language" |
49 |
+HOMEPAGE="https://crystal-lang.org" |
50 |
+SRC_URI="https://github.com/crystal-lang/crystal/archive/${PV}.tar.gz -> ${P}.tar.gz |
51 |
+ amd64? ( https://github.com/crystal-lang/crystal/releases/download/${BV/}/crystal-${BV_AMD64}.tar.gz ) |
52 |
+ x86? ( https://github.com/crystal-lang/crystal/releases/download/${BV}/crystal-${BV_X86}.tar.gz )" |
53 |
+ |
54 |
+LICENSE="Apache-2.0" |
55 |
+SLOT="0" |
56 |
+KEYWORDS="~amd64" |
57 |
+IUSE="doc debug examples blocking-stdio-hack +xml +yaml" |
58 |
+ |
59 |
+LLVM_MAX_SLOT=6 |
60 |
+ |
61 |
+# dev-libs/boehm-gc[static-libs] dependency problem, check the issue: https://github.com/manastech/crystal/issues/1382 |
62 |
+DEPEND=" |
63 |
+ sys-devel/llvm:${LLVM_MAX_SLOT} |
64 |
+ dev-libs/boehm-gc[static-libs,threads] |
65 |
+ dev-libs/libatomic_ops |
66 |
+ dev-libs/libevent |
67 |
+ dev-libs/libpcre |
68 |
+ sys-libs/libunwind |
69 |
+ dev-libs/pcl |
70 |
+ dev-libs/gmp:0 |
71 |
+" |
72 |
+RDEPEND="${DEPEND} |
73 |
+ xml? ( dev-libs/libxml2 ) |
74 |
+ yaml? ( dev-libs/libyaml ) |
75 |
+" |
76 |
+ |
77 |
+PATCHES=( |
78 |
+ "${FILESDIR}"/${PN}-0.25.0-verbose.patch |
79 |
+ "${FILESDIR}"/${PN}-0.26.1-gentoo-tests-sandbox.patch |
80 |
+ "${FILESDIR}"/${PN}-0.24.2-gentoo-tests-network-sandbox.patch |
81 |
+ "${FILESDIR}"/${PN}-0.26.0-gentoo-tests-network-sandbox-2.patch |
82 |
+ "${FILESDIR}"/${PN}-0.26.1-gentoo-tests-network-sandbox-3.patch |
83 |
+) |
84 |
+ |
85 |
+src_prepare() { |
86 |
+ default |
87 |
+ |
88 |
+ use blocking-stdio-hack && eapply "${FILESDIR}"/"${PN}"-0.22.0-blocking-stdio-hack.patch |
89 |
+} |
90 |
+ |
91 |
+src_compile() { |
92 |
+ emake \ |
93 |
+ $(usex debug "" release=1) \ |
94 |
+ progress=true \ |
95 |
+ stats=1 \ |
96 |
+ threads=$(makeopts_jobs) \ |
97 |
+ verbose=1 \ |
98 |
+ \ |
99 |
+ CC=$(tc-getCC) \ |
100 |
+ CXX=$(tc-getCXX) \ |
101 |
+ AR=$(tc-getAR) \ |
102 |
+ \ |
103 |
+ PATH="${WORKDIR}"/${PN}-${BV}/bin:"${PATH}" \ |
104 |
+ CRYSTAL_PATH=src \ |
105 |
+ CRYSTAL_CONFIG_VERSION=${PV} \ |
106 |
+ CRYSTAL_CONFIG_PATH="lib:${EPREFIX}/usr/$(get_libdir)/crystal" |
107 |
+ use doc && emake docs |
108 |
+} |
109 |
+ |
110 |
+src_test() { |
111 |
+ emake spec \ |
112 |
+ $(usex debug "" release=1) \ |
113 |
+ progress=true \ |
114 |
+ stats=1 \ |
115 |
+ threads=$(makeopts_jobs) \ |
116 |
+ verbose=1 \ |
117 |
+ \ |
118 |
+ CC=$(tc-getCC) \ |
119 |
+ CXX=$(tc-getCXX) \ |
120 |
+ AR=$(tc-getAR) \ |
121 |
+ \ |
122 |
+ CRYSTAL_PATH=src \ |
123 |
+ CRYSTAL_CONFIG_VERSION=${PV} |
124 |
+} |
125 |
+ |
126 |
+src_install() { |
127 |
+ insinto /usr/$(get_libdir)/crystal |
128 |
+ doins -r src/. |
129 |
+ dobin .build/crystal |
130 |
+ |
131 |
+ insinto /usr/share/zsh/site-functions |
132 |
+ newins etc/completion.zsh _crystal |
133 |
+ |
134 |
+ use examples && dodoc -r samples |
135 |
+ |
136 |
+ if use doc ; then |
137 |
+ docinto api |
138 |
+ dodoc -r docs/. |
139 |
+ fi |
140 |
+ |
141 |
+ newbashcomp etc/completion.bash ${PN} |
142 |
+} |
143 |
|
144 |
diff --git a/dev-lang/crystal/files/crystal-0.26.1-gentoo-tests-network-sandbox-3.patch b/dev-lang/crystal/files/crystal-0.26.1-gentoo-tests-network-sandbox-3.patch |
145 |
new file mode 100644 |
146 |
index 00000000000..eb1b84ce618 |
147 |
--- /dev/null |
148 |
+++ b/dev-lang/crystal/files/crystal-0.26.1-gentoo-tests-network-sandbox-3.patch |
149 |
@@ -0,0 +1,26 @@ |
150 |
+diff --git a/spec/std/http/server/server_spec.cr b/spec/std/http/server/server_spec.cr |
151 |
+index 9de0c3f..59882db 100644 |
152 |
+--- a/spec/std/http/server/server_spec.cr |
153 |
++++ b/spec/std/http/server/server_spec.cr |
154 |
+@@ -400,7 +400,9 @@ module HTTP |
155 |
+ end |
156 |
+ |
157 |
+ describe "#bind_tls" do |
158 |
+- it "binds SSL server context" do |
159 |
++ # gentoo's FEATURES=network-sandbox blocks external network: |
160 |
++ # connect: Connection timed out (Errno) |
161 |
++ pending "binds SSL server context" do |
162 |
+ server = Server.new do |context| |
163 |
+ context.response.puts "Test Server (#{context.request.headers["Host"]?})" |
164 |
+ context.response.close |
165 |
+@@ -512,7 +514,9 @@ module HTTP |
166 |
+ end |
167 |
+ {% end %} |
168 |
+ |
169 |
+- it "handles exception during SSL handshake (#6577)" do |
170 |
++ # gentoo's FEATURES=network-sandbox blocks external network: |
171 |
++ # connect: Connection timed out (Errno) |
172 |
++ pending "handles exception during SSL handshake (#6577)" do |
173 |
+ server = SilentErrorHTTPServer.new do |context| |
174 |
+ context.response.print "ok" |
175 |
+ context.response.close |
176 |
|
177 |
diff --git a/dev-lang/crystal/files/crystal-0.26.1-gentoo-tests-sandbox.patch b/dev-lang/crystal/files/crystal-0.26.1-gentoo-tests-sandbox.patch |
178 |
new file mode 100644 |
179 |
index 00000000000..cab165c3905 |
180 |
--- /dev/null |
181 |
+++ b/dev-lang/crystal/files/crystal-0.26.1-gentoo-tests-sandbox.patch |
182 |
@@ -0,0 +1,22 @@ |
183 |
+--- a/spec/std/file_spec.cr |
184 |
++++ b/spec/std/file_spec.cr |
185 |
+@@ -1164,3 +1164,4 @@ describe "File" do |
186 |
+ # TODO: there is no file which is reliably unwritable on windows |
187 |
+- pending_win32 "raises if file cannot be accessed" do |
188 |
++ # On linux(or sandbox?) it's "Permission denied", not "Operation not permitted" |
189 |
++ pending "raises if file cannot be accessed" do |
190 |
+ expect_raises Errno, "Operation not permitted" do |
191 |
+--- a/spec/std/process_spec.cr |
192 |
++++ b/spec/std/process_spec.cr |
193 |
+@@ -135,3 +135,4 @@ describe Process do |
194 |
+ describe "environ" do |
195 |
+- it "clears the environment" do |
196 |
++ #gentoo's sandbox keeps sandbox environment |
197 |
++ pending "clears the environment" do |
198 |
+ value = Process.run("env", clear_env: true) do |proc| |
199 |
+@@ -142,3 +143,4 @@ describe Process do |
200 |
+ |
201 |
+- it "sets an environment variable" do |
202 |
++ #gentoo's sandbox keeps sandbox environment |
203 |
++ pending "sets an environment variable" do |
204 |
+ env = {"FOO" => "bar"} |