void-packages/srcpkgs/julia/template
Adam Beckmeyer 1e214583cb julia: update to 1.4.2.
[ci skip]

Changes julia to bundle its own copy of libgit2. Closes #21960. Julia
is currently binary-incompatible with the newer version of libgit2
shipped with void.
2020-06-03 20:17:51 +02:00

87 lines
2.5 KiB
Bash

# Template file for 'julia'
pkgname=julia
version=1.4.2
revision=1
archs="i686* x86_64*"
build_style=gnu-makefile
make_build_args="prefix=/usr sysconfdir=/etc datarootdir=/usr/share
USE_LLVM_SHLIB=1 USE_BINARYBUILDER=0
USE_SYSTEM_LIBUV=0 USE_SYSTEM_LIBUNWIND=0 USE_SYSTEM_PATCHELF=1 USE_SYSTEM_LIBM=0
USE_SYSTEM_DSFMT=0 USE_SYSTEM_LLVM=0 USE_SYSTEM_PCRE=1 USE_SYSTEM_BLAS=0
USE_SYSTEM_GMP=1 USE_SYSTEM_LIBGIT2=0 USE_SYSTEM_MBEDTLS=1 USE_SYSTEM_LIBSSH2=1
USE_SYSTEM_CURL=1 USE_SYSTEM_MPFR=1 USE_SYSTEM_SUITESPARSE=0 USE_SYSTEM_UTF8PROC=0
USE_SYSTEM_ZLIB=1 USE_SYSTEM_P7ZIP=1 USE_SYSTEM_LAPACK=0"
make_install_args="$make_build_args"
make_check_args="$make_build_args"
make_check_target=testall
conf_files="/etc/julia/startup.jl"
hostmakedepends="perl cmake python gcc-fortran patchelf which tar xz"
makedepends="pcre2-devel gmp-devel mpfr-devel libcurl-devel
libssh2-devel mbedtls-devel libatomic-devel zlib-devel p7zip"
depends="pcre2 gmp mpfr libcurl libssh2 mbedtls libatomic zlib p7zip"
short_desc="High-level, high-performance dynamic programming language"
maintainer="Adam Beckmeyer <adam_git@thebeckmeyers.xyz>"
license="MIT"
homepage="https://julialang.org"
distfiles="https://github.com/JuliaLang/julia/releases/download/v${version}/julia-${version}-full.tar.gz"
checksum=948c70801d5cce81eeb7f764b51b4bfbb2dc0b1b9effc2cb9fc8f8cf6c90a334
nocross=yes
# Falsely detects dependency on libllvm
skiprdeps="/usr/lib/libjulia.so.1.4 /usr/lib/julia/libllvmcalltest.so"
case "$XBPS_TARGET_MACHINE" in
*-musl)
broken="fails to compile internal LLVM"
;;
i686-musl)
makedepends+=" libexecinfo-devel"
depends+=" libexecinfo"
LDFLAGS="-lexecinfo -lc"
;;
x86_64-musl)
makedepends+=" libexecinfo-devel"
depends+=" libexecinfo"
LDFLAGS="-lexecinfo"
;;
esac
case "$XBPS_TARGET_MACHINE" in
i686*)
export M="pentium4"
export CFLAGS="-march=pentium4"
export CXXFLAGS="-march=pentium4"
export LDFLAGS+=" -Wl,--no-keep-memory"
make_build_args+=" MARCH=pentium4"
make_build_args+=" OPENBLAS_USE_THREAD=0"
;;
x86_64*)
export M="x86-64"
export CFLAGS="-march=x86-64"
export CXXFLAGS="-march=x86-64"
make_build_args+=" MARCH=x86-64"
;;
esac
post_extract() {
sed -i '/^install:/s| \$(BUILDROOT)/doc.*||' Makefile
}
post_install() {
vlicense LICENSE.md
}
julia-devel_package() {
depends="${sourcepkg}>=${version}_${revision}"
short_desc+=" - development files"
pkg_install() {
vmove usr/include
}
}
julia-doc_package() {
depends="${sourcepkg}>=${version}_${revision}"
short_desc+=" - documentation files"
pkg_install() {
vmove usr/share/doc
}
}