# PackageCompiler dependency issues (1.1; failing with dependency errors)

**URL:** https://discourse.julialang.org/t/packagecompiler-dependency-issues-1-1-failing-with-dependency-errors/25578
**Category:** General Usage
**Created:** [June 23, 2019, 5:09pm UTC](https://discourse.julialang.org/t/packagecompiler-dependency-issues-1-1-failing-with-dependency-errors/25578 "2019-06-23T17:09:25Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![srs](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/srs/32/8206_2.png) [@srs](https://discourse.julialang.org/u/srs)
#### Post date: [June 23, 2019, 5:09pm UTC](https://discourse.julialang.org/t/packagecompiler-dependency-issues-1-1-failing-with-dependency-errors/25578/1 "2019-06-23T17:09:25Z")

</div>

What is the correct way to use `PackageCompiler` in 1.1?

I naively tried:

```julia
using PackageCompiler
compile_incremental(:Plots, force=false)

```

And it keeps throwing dependency errors, like: “LoadError: … Package … is required, but does not seem to be installed”. First about `VisualRegressionTests`, then about `UnicodePlots` and `StatsPlots` and then, having installed these, about `Images`. Knowing that the dependency tree can be arbitrarily deep, I gave up at this point.

Am I doing anything wrong? Any idea why it doesn’t find these dependencies?

There is an [issue](https://github.com/JuliaLang/PackageCompiler.jl/issues/239) in `PackageCompiler` about this, which recommends using the now-defunct `notoml` branch, but that’s basically it.

I also tried it with the `GR` package and there I get some error about “Task cannot be serialized”. Might `PackageCompiler` be defunct in 1.1?

I’m on Windows.

---

<div class="post-metadata">

### Author: ![pfitzseb](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/pfitzseb/32/45566_2.png) [@pfitzseb](https://discourse.julialang.org/u/pfitzseb)
#### Post date: [June 23, 2019, 8:06pm UTC](https://discourse.julialang.org/t/packagecompiler-dependency-issues-1-1-failing-with-dependency-errors/25578/2 "2019-06-23T20:06:01Z")

</div>

Try the master branch with `pkg> dev`:  
[https://github.com/JuliaLang/PackageCompiler.jl/issues/184#issuecomment-464727539](https://github.com/JuliaLang/PackageCompiler.jl/issues/184#issuecomment-464727539)

---

<div class="post-metadata">

### Author: ![fredrikekre](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/fredrikekre/32/1688_2.png) [@fredrikekre](https://discourse.julialang.org/u/fredrikekre)
#### Post date: [June 23, 2019, 8:24pm UTC](https://discourse.julialang.org/t/packagecompiler-dependency-issues-1-1-failing-with-dependency-errors/25578/3 "2019-06-23T20:24:02Z")

</div>

> [@pfitzseb](#):
>
> Try the master branch with `pkg> dev`

Better to use/recommend `add PackageCompiler#master`.

---

<div class="post-metadata">

### Author: ![pfitzseb](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/pfitzseb/32/45566_2.png) [@pfitzseb](https://discourse.julialang.org/u/pfitzseb)
#### Post date: [June 24, 2019, 7:07am UTC](https://discourse.julialang.org/t/packagecompiler-dependency-issues-1-1-failing-with-dependency-errors/25578/4 "2019-06-24T07:07:33Z")

</div>

No, there’s a bug in PackageCompiler which means that you get that serialization error unless you `dev` (yes, this is very weird, and no, I don’t know why it happens).

---

<div class="post-metadata">

### Author: ![srs](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/srs/32/8206_2.png) [@srs](https://discourse.julialang.org/u/srs)
#### Post date: [June 24, 2019, 1:40pm UTC](https://discourse.julialang.org/t/packagecompiler-dependency-issues-1-1-failing-with-dependency-errors/25578/5 "2019-06-24T13:40:49Z")

</div>

> [@pfitzseb](#):
>
> Try the master branch with `pkg> dev` :

Thanks a lot! This fixes the serialization errors!

I’m still getting the various dependency errors precompiling `Plots`, though. Anyone else here seeing these?

---

<div class="post-metadata">

### Author: ![KestutisMa](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/kestutisma/32/7835_2.png) [@KestutisMa](https://discourse.julialang.org/u/KestutisMa)
#### Post date: [June 24, 2019, 6:10pm UTC](https://discourse.julialang.org/t/packagecompiler-dependency-issues-1-1-failing-with-dependency-errors/25578/6 "2019-06-24T18:10:47Z")

</div>

1. Yes, same dependencies errors using Julia v1.1.1 ([julialang.org](http://julialang.org) official binaries) on Linux. Also tried `pkg> instantiate`, but it didn’t find any missing dependencies.

2. Also, if somebody is using Julia binaries installed from Linux distribution’s repositories (in this case Arch Linux), there is error building Arpack while doing `compile_incremental(:Plots, force=false)`, also when tried to build manually, but still:

```julia
(v1.1) pkg> build Arpack
  Building Arpack → `~/.julia/packages/Arpack/cu5By/deps/build.log`
┌ Error: Error building `Arpack`: 
│ ERROR: LoadError: LibraryProduct(nothing, ["libarpack"], :libarpack, "Prefix(/home/kest/.julia/packages/Arpack/cu5By/deps/usr)") is not satisfied, cannot generate deps.jl!
│ Stacktrace:
│ [1] #write_deps_file#152(::Bool, ::Function, ::String, ::Array{LibraryProduct,1}) at /home/kest/.julia/packages/BinaryProvider/TcAwt/src/Products.jl:414
│ [2] (::getfield(BinaryProvider, Symbol("#kw##write_deps_file")))(::NamedTuple{(:verbose,),Tuple{Bool}}, ::typeof(write_deps_file), ::String, ::Array{LibraryProduct,1}) at ./none:0
│ [3] top-level scope at none:0
│ [4] include(::String) at ./client.jl:403
│ [5] top-level scope at none:0
│ in expression starting at /home/kest/.julia/packages/Arpack/cu5By/deps/build.jl:74
└ @ Pkg.Operations /build/julia/src/julia-1.1.1/usr/share/julia/stdlib/v1.1/Pkg/src/Operations.jl:1075

```

But error is not occurring using official Julia binaries from [julialang.org](http://julialang.org)! Maybe different GCC versions used to compile Julia caused that (could be related: [Installation error when Julia is built from source · Issue #5 · JuliaLinearAlgebra/Arpack.jl · GitHub](https://github.com/JuliaLinearAlgebra/Arpack.jl/issues/5)).

1. Answering:

> [@PackageCompiler dependency issues (1.1; failing with dependency errors)](https://discourse.julialang.org/t/packagecompiler-dependency-issues-1-1-failing-with-dependency-errors/25578/4):
>
> No, there’s a bug in PackageCompiler which means that you get that serialization error unless you dev (yes, this is very weird, and no, I don’t know why it happens).

@pfitzseb, I am using `add PackageCompiler@master` and no serialization errors, maybe this could be the cause:  
“The package `dev` command works similar to `add` but instead of locking the package to the state it was when you added it, the environment using the package will continuously use the latests changes to the package.” [My New Workflow with Julia 1.0. A practical guide to how you can work… | by Erik Engheim | Medium](https://medium.com/@Jernfrost/my-new-workflow-with-julia-1-0-99711103d97c)
