Bug 229274 - lang/julia: should add devel/llvm40 as runtime dependency
Summary: lang/julia: should add devel/llvm40 as runtime dependency
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Li-Wen Hsu
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-06-24 13:47 UTC by Trond Endrestøl
Modified: 2018-07-10 22:25 UTC (History)
3 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Trond Endrestøl 2018-06-24 13:47:22 UTC
# uname -aKU
FreeBSD freebsd-head-zfs.bsd.net 12.0-CURRENT FreeBSD 12.0-CURRENT #0 r335597: Sun Jun 24 10:30:51 CEST 2018     root@freebsd-head-zfs.bsd.net:/usr/obj/usr/src/amd64.amd64/sys/VBOXGUEST  amd64 1200069 1200069

# julia --version
julia version 0.6.3

# ldd /usr/local/bin/julia
/usr/local/bin/julia:
        libjulia.so.0.6 => /usr/local/bin/../lib/libjulia.so.0.6 (0x800647000)
        libelf.so.2 => /lib/libelf.so.2 (0x800cf6000)
        libkvm.so.7 => /lib/libkvm.so.7 (0x800d10000)
        librt.so.1 => /usr/lib/librt.so.1 (0x800d23000)
        libgcc_s.so.1 => /usr/local/lib/gcc6/libgcc_s.so.1 (0x800d2b000)
        libc++.so.1 => /usr/lib/libc++.so.1 (0x800f42000)
        libcxxrt.so.1 => /lib/libcxxrt.so.1 (0x801011000)
        libm.so.5 => /lib/libm.so.5 (0x801032000)
        libc.so.7 => /lib/libc.so.7 (0x801062000)
        libutf8proc.so.2 => /usr/local/lib/libutf8proc.so.2 (0x80146e000)
        libLLVM-4.0.so => /usr/local/llvm40/lib/libLLVM-4.0.so (0x801800000) <-- What's this?
        libthr.so.3 => /lib/libthr.so.3 (0x8016b6000)
        libedit.so.0 => /usr/local/lib/libedit.so.0 (0x8016e0000)
        libncurses.so.8 => /lib/libncurses.so.8 (0x801716000)
        libz.so.6 => /lib/libz.so.6 (0x80176d000)

# pkg info -d lang/julia
julia-0.6.3_1:
        utf8proc-2.1.0
        openblas-0.2.20_2,1
        mpfr-4.0.1
        gmp-6.1.2
        arpack-ng-3.5.0_1
        gcc6-6.4.0_7
        curl-7.60.0
        pcre2-10.21_1
        libgit2-0.27.2

Looks like llvm40-4.0.1_7 aka devel/llvm40 should be added as a runtime dependency. I actually had to install llvm40 a while ago to get julia running.
Comment 1 Iblis Lin 2018-06-24 14:51:01 UTC
Thanks for your report.
I always build from source... not aware of this issue.

Patch is here:

diff --git a/Makefile b/Makefile
index 12fe96c..5eb11f7 100644
--- a/Makefile
+++ b/Makefile
@@ -84,6 +84,7 @@ LLVM_MAKE_ARGS=       USE_SYSTEM_LLVM=0
 LLVM_MAKE_ARGS_OFF=    USE_SYSTEM_LLVM=1 LLVM_CONFIG=llvm-config40
 LLVM_BUILD_DEPENDS=    cmake:devel/cmake
 LLVM_BUILD_DEPENDS_OFF=        llvm-config40:devel/llvm40
+LLVM_LIB_DEPENDS_OFF=  libLLVM-4.0.so:devel/llvm40
 LLVM_USES=     python:build perl5
 
 SYSLIBM_DESC=  Build with system libm
Comment 2 Trond Endrestøl 2018-06-24 19:05:04 UTC
(In reply to Iblis Lin from comment #1)
I also build from source, using ports-mgmt/synth.
I have only enabled the options DOCS and SYSLIBM. It's very close to the defaults.

Options        :
        ARPACK         : off
        DEBUG          : off
        DESKTOP        : off
        DOCS           : on
        EXAMPLES       : off
        GPL_LIBS       : off
        LLVM           : off
        NATIVE         : off
        OPENLIBM       : off
        SYSLIBM        : on

synth is running on one of my systems, and it will take your patch for a spin once it reaches lang/julia.
Comment 3 Trond Endrestøl 2018-06-26 14:42:02 UTC
Note this is from one of my stable/11 systems, but your patch works.

# pkg info -dfr lang/julia
julia-0.6.3_1
Name           : julia
Version        : 0.6.3_1
Installed on   : Mon Jun 25 11:58:02 2018 CEST
Origin         : lang/julia
Architecture   : FreeBSD:11:amd64
Prefix         : /usr/local
Categories     : math lang
Licenses       : MIT
Maintainer     : iblis@hs.ntnu.edu.tw
WWW            : http://julialang.org/
Comment        : Julia Language: A fresh approach to technical computing
Options        :
        ARPACK         : off
        DEBUG          : off
        DESKTOP        : off
        DOCS           : on
        EXAMPLES       : off
        GPL_LIBS       : off
        LLVM           : off
        NATIVE         : off
        OPENLIBM       : off
        SYSLIBM        : on
Shared Libs required:
        libquadmath.so.0
        libutf8proc.so.2
        libgfortran.so.3
        libLLVM-4.0.so
        libgcc_s.so.1
Shared Libs provided:
        libopenspecfun.so.1
        libjulia.so.0.6
Annotations    :
        FreeBSD_version: 1102501
        repo_type      : binary
        repository     : Synth
Flat size      : 52.1MiB
Description    :
Julia is a high-level, high-performance dynamic programming language for
technical computing, with syntax that is familiar to users of other technical
computing environments. It provides a sophisticated compiler, distributed
parallel execution, numerical accuracy, and an extensive mathematical function
library. The library, largely written in Julia itself, also integrates mature,
best-of-breed C and Fortran libraries for linear algebra, random number
generation, signal processing, and string processing.

WWW: http://julialang.org/
Depends on     :
        utf8proc-2.1.0
        openblas-0.2.20_2,1
        mpfr-4.0.1
        gmp-6.1.2
        arpack-ng-3.5.0_1
        gcc6-6.4.0_7
        curl-7.60.0
        pcre2-10.21_1
        llvm40-4.0.1_7 <-- Looks good!
        libgit2-0.27.2
Required by    :
        bsdnet-labs-2018062400
Comment 4 commit-hook freebsd_committer freebsd_triage 2018-07-10 16:38:13 UTC
A commit references this bug:

Author: lwhsu
Date: Tue Jul 10 16:37:52 UTC 2018
New revision: 474381
URL: https://svnweb.freebsd.org/changeset/ports/474381

Log:
  Add devel/llvm40 as runtime dependency

  Not bumping PORTREVISION because it is implicitly included by pkg qa scripts.

  PR:		229274
  Submitted by:	Iblis Lin <iblis@hs.ntnu.edu.tw> (maintainer)
  Reported by:	Trond.Endrestol@ximalas.info
  MFH:		2018Q3

Changes:
  head/lang/julia/Makefile
Comment 5 commit-hook freebsd_committer freebsd_triage 2018-07-10 22:25:07 UTC
A commit references this bug:

Author: lwhsu
Date: Tue Jul 10 22:24:05 UTC 2018
New revision: 474416
URL: https://svnweb.freebsd.org/changeset/ports/474416

Log:
  MFH: r474381

  Add devel/llvm40 as runtime dependency

  Not bumping PORTREVISION because it is implicitly included by pkg qa scripts.

  PR:		229274
  Submitted by:	Iblis Lin <iblis@hs.ntnu.edu.tw> (maintainer)
  Reported by:	Trond.Endrestol@ximalas.info

  Approved by:	ports-secteam (riggs)

Changes:
_U  branches/2018Q3/
  branches/2018Q3/lang/julia/Makefile