# Avoid downloading MKL artifact as FFTW dependency

**URL:** <https://discourse.julialang.org/t/avoid-downloading-mkl-artifact-as-fftw-dependency/108054>\
**Category:** Package Management\
**Created:** [December 26, 2023, 11:58am UTC](https://discourse.julialang.org/t/avoid-downloading-mkl-artifact-as-fftw-dependency/108054 "2023-12-26T11:58:46Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Vasily\_Pisarev](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/vasily_pisarev/32/7929_2.png) [@Vasily\_Pisarev](https://discourse.julialang.org/u/Vasily_Pisarev)\
**Post date:** [December 26, 2023, 11:58am UTC](https://discourse.julialang.org/t/avoid-downloading-mkl-artifact-as-fftw-dependency/108054/1 "2023-12-26T11:58:46Z")

</div>

I am developing a package that uses FFTW.  
Changing Manifest.toml by adding or removing packages triggers precompilation of all dependencies, during which MKL\_jll downloads MKL binary.  
BUT MKL in my case is only an optional dependence of FFTW and is not supposed to be used in my package.  
Is there a way to skip artifact downloading on precompile?

---

<div class="post-metadata">

**Author:** ![giordano](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/giordano/32/2166_2.png) [@giordano](https://discourse.julialang.org/u/giordano)\
**Post date:** [December 26, 2023, 12:27pm UTC](https://discourse.julialang.org/t/avoid-downloading-mkl-artifact-as-fftw-dependency/108054/2 "2023-12-26T12:27:51Z")

</div>

`MKL_jll` is loaded only if using MKL as provider explicitly:

> <https://github.com/JuliaMath/FFTW.jl/blob/7acdc2b8a6d4777bc73832b9afd55890bf9e2b9a/src/providers.jl#L83-L89>

So the artifact shouldn’t be loaded unless you’re asking for it.

---

<div class="post-metadata">

**Author:** ![Vasily\_Pisarev](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/vasily_pisarev/32/7929_2.png) [@Vasily\_Pisarev](https://discourse.julialang.org/u/Vasily_Pisarev)\
**Post date:** [December 26, 2023, 2:15pm UTC](https://discourse.julialang.org/t/avoid-downloading-mkl-artifact-as-fftw-dependency/108054/3 "2023-12-26T14:15:07Z")

</div>

IIUC, `Pkg.precompile()` precompiles everything in Manifest, and the artifact is downloaded at that stage.  
I’ve found that disabling automatic precompilation at Manifest change seems to solve that issue locally, but more generally it’s weird that everyone getting my package also has to download MKL unless they set a specific environment variable.
