Obsolete
/
recipes
Archived
3
0
Fork 0
This repository has been archived on 2022-01-17. You can view files and clone it, but cannot push or open issues/pull-requests.
recipes/crystal/recipe.spec

53 lines
1.3 KiB
Plaintext
Raw Normal View History

name: crystal
2019-10-18 13:25:18 +02:00
version: 0.31.1
release: 1
2019-08-23 14:11:11 +02:00
sources: https://github.com/crystal-lang/crystal/archive/%{version}.tar.gz -> %{name}-%{version}.tar.gz
2019-10-18 13:25:18 +02:00
build-dependencies:
- llvm-6-dev
dependencies:
- libyaml
- libevent
- pcre
2019-10-18 13:25:18 +02:00
- llvm-6
- libressl
2019-08-23 14:11:11 +02:00
@build
cd %{name}-%{version}
make release=1 \
FLAGS="--release --no-debug" \
CRYSTAL_PATH="$(pwd)/src" \
CRYSTAL_CONFIG_VERSION="%{version}" \
2019-10-18 13:25:18 +02:00
CRYSTAL_CONFIG_PATH="lib:%{prefix}/lib/crystal" \
2019-08-23 14:11:11 +02:00
CRYSTAL_CACHE_DIR="/tmp/crystal" \
LLVM_CONFIG=/usr/bad/llvm-6/bin/llvm-config
make docs CRYSTAL_CACHE_DIR="/tmp/crystal"
@install
2019-08-23 14:11:11 +02:00
cd %{name}-%{version}
mkdir -p \
2019-10-18 13:25:18 +02:00
"%{pkg}%{prefix}/bin" \
"%{pkg}%{prefix}/lib" \
"%{pkg}%{prefix}/share/man/man1"
2019-08-23 14:11:11 +02:00
2019-10-18 13:25:18 +02:00
install -m755 ".build/crystal" "%{pkg}%{prefix}/bin/crystal"
2019-08-23 14:11:11 +02:00
2019-10-18 13:25:18 +02:00
cp -r src "%{pkg}%{prefix}/lib/crystal"
2019-08-23 14:11:11 +02:00
(
2019-10-18 13:25:18 +02:00
cd "%{pkg}%{prefix}/lib/crystal"
2019-08-23 14:11:11 +02:00
rm -rf ext/sigfault.* llvm/ext/llvm_ext.o
)
2019-10-18 13:25:18 +02:00
mkdir -p "%{pkg}%{prefix}/share/doc/crystal"
cp -r docs "%{pkg}%{prefix}/share/doc/crystal/api"
cp -r samples "%{pkg}%{prefix}/share/doc/crystal/"
2019-08-23 14:11:11 +02:00
2019-10-18 13:25:18 +02:00
install -m644 man/crystal.1 "%{pkg}%{prefix}/share/man/man1/"
2019-08-23 14:11:11 +02:00
# Well probably want those at some point… in due time, and in splits.
2019-10-18 13:25:18 +02:00
#install -m644 etc/completion.bash "%{pkg}%{prefix}/share/bash-completion/completions/crystal"
#install -m644 etc/completion.zsh "%{pkg}%{prefix}/share/zsh/site-functions/_crystal"