Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
aports
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Monitor
Service Desk
Analyze
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
alpine
aports
Commits
6ef8a4d4
Commit
6ef8a4d4
authored
3 years ago
by
Jakub Jirutka
Browse files
Options
Downloads
Patches
Plain Diff
community/crystal: run std_spec tests and samples
This is based on the upstream's CI config.
parent
d3248ff7
Loading
Loading
1 merge request
!26526
community/crystal: upgrade to 1.2.0
Pipeline
#97152
canceled
3 years ago
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
community/crystal/APKBUILD
+13
-5
13 additions, 5 deletions
community/crystal/APKBUILD
community/crystal/fix-crystal-sh.patch
+13
-0
13 additions, 0 deletions
community/crystal/fix-crystal-sh.patch
with
26 additions
and
5 deletions
community/crystal/APKBUILD
+
13
−
5
View file @
6ef8a4d4
...
...
@@ -9,7 +9,6 @@ _llvmver=12
pkgdesc
=
"The Crystal Programming Language"
url
=
"https://crystal-lang.org/"
arch
=
"x86_64 aarch64"
options
=
"!check"
# disable for now till it fixed upstream
license
=
"Apache-2.0"
depends
=
"
gc-dev
...
...
@@ -40,6 +39,7 @@ subpackages="$pkgname-doc
source
=
"
$pkgname
-
$pkgver
.tar.gz::https://github.com/crystal-lang/
$pkgname
/archive/
$pkgver
.tar.gz
https://dev.alpinelinux.org/archive/crystal/crystal-
$_bootver
-x86_64-alpine-linux-musl.tar.gz
https://dev.alpinelinux.org/archive/crystal/crystal-
$_bootver
-aarch64-alpine-linux-musl.tar.gz
fix-crystal-sh.patch
"
builddir
=
"
$srcdir
/
$pkgname
-
$pkgver
"
...
...
@@ -48,6 +48,7 @@ _shardsdir="/usr/lib/$pkgname/shards"
export
CRYSTAL_CONFIG_VERSION
=
"
$pkgver
"
export
CRYSTAL_CACHE_DIR
=
"
$srcdir
/.cache"
export
LLVM_CONFIG
=
"/usr/lib/llvm
$_llvmver
/bin/llvm-config"
# Build static crystal binary and upload it to dev.a.o, so it can be used
# for building crystal next time (needed for bootstrapping).
...
...
@@ -77,12 +78,15 @@ snapshot() {
prepare
()
{
default_prepare
# FIXME: These specs fail with invalid memory access.
rm
spec/compiler/compiler_spec.cr
cat
>
Makefile.local
<<-
EOF
progress = 1
threads =
${
JOBS
:-
2
}
verbose = 1
FLAGS = --verbose --target
$CTARGET
${
BUILD_STATIC
:+
"--link-flags=-no-pie"
}
LLVM_CONFIG =
/usr/lib/llvm
$_llvmver
/bin/llvm-config
LLVM_CONFIG =
$LLVM_CONFIG
EOF
}
...
...
@@ -91,14 +95,17 @@ build() {
CRYSTAL_CONFIG_BUILD_COMMIT
=
\
CRYSTAL_CONFIG_PATH
=
"lib:
$_shardsdir
:
$_coredir
"
\
PATH
=
"
$srcdir
/
$pkgname
-
$_bootver
-
$CBUILD
/bin:
$PATH
"
\
LLVM_CONFIG
=
"/usr/lib/llvm
$_llvmver
/bin/llvm-config"
\
release
=
1
\
static
=
${
BUILD_STATIC
:-}
}
check
()
{
make spec
LLVM_CONFIG
=
"llvm-config"
PATH
=
".build:
$PATH
"
\
SPEC_FLAGS
=
"--no-color --verbose"
make std_spec
threads
=
1
SPEC_FLAGS
=
'--no-color --verbose'
find samples
-name
'*.cr'
| xargs
-tn
1 ./bin/crystal build
--no-codegen
# Takes ~1 hour on x86_64, ~1.5 hour on aarch64.
#make compiler_spec threads=1 SPEC_FLAGS='--no-color --verbose'
}
package
()
{
...
...
@@ -136,4 +143,5 @@ sha512sums="
305aee00d8b59cc004785b69d2b044e388fc0e68b3da1f2a385473eff63bab7eb191d56aa4761e7a969509d8c5ede1c6d696847fde609fbfcfb46e13af193422 crystal-1.2.0.tar.gz
4c47961882a68485450b7b001ffc844d150b534bafec5f95c782d4a5bf33422f7b0a0be8be153e779bf2200da540aa1505e8345b07e9e8ef779b08e1b21a76b3 crystal-1.1.1-x86_64-alpine-linux-musl.tar.gz
de33f8f51355e8091cc67ef9d3f29b2422311fd420c33968f9e95729c0367134d19aaeae603123306ed768bb3d098d9ab367f601ebd9c4e9fe265bae9f77489a crystal-1.1.1-aarch64-alpine-linux-musl.tar.gz
2ba9e26eb1e6d20681e7f2ad78e0ebd75ae0dc614624c8de90c918046d0451f43173a23981dbebb47d1da2cf58663e8b1169d7f32799b054fc0f6a6cb112b7c5 fix-crystal-sh.patch
"
This diff is collapsed.
Click to expand it.
community/crystal/fix-crystal-sh.patch
0 → 100644
+
13
−
0
View file @
6ef8a4d4
Don't print error message when there's no system-provided crystal.
--- a/bin/crystal
+++ b/bin/crystal
@@ -150,7 +150,7 @@
if [ -z "$CRYSTAL_CONFIG_LIBRARY_PATH" ] || [ -z "$CRYSTAL_LIBRARY_PATH" ]; then
CRYSTAL_INSTALLED_LIBRARY_PATH="$(
export PATH="$(remove_path_item "$(remove_path_item "$PATH" "$SCRIPT_ROOT")" "bin")"
- crystal env CRYSTAL_LIBRARY_PATH || echo ""
+ crystal env CRYSTAL_LIBRARY_PATH 2>/dev/null || echo ""
)"
export CRYSTAL_LIBRARY_PATH=${CRYSTAL_LIBRARY_PATH:-$CRYSTAL_INSTALLED_LIBRARY_PATH}
export CRYSTAL_CONFIG_LIBRARY_PATH=${CRYSTAL_CONFIG_LIBRARY_PATH:-$CRYSTAL_INSTALLED_LIBRARY_PATH}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment