# Error when importing CUDAnative (or just about anything with CUDA)

**URL:** <https://discourse.julialang.org/t/error-when-importing-cudanative-or-just-about-anything-with-cuda/70198>\
**Category:** GPU\
**Tags:** question, package\
**Created:** [October 22, 2021, 8:21am UTC](https://discourse.julialang.org/t/error-when-importing-cudanative-or-just-about-anything-with-cuda/70198 "2021-10-22T08:21:35Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Niceno](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/niceno/32/29648_2.png) [@Niceno](https://discourse.julialang.org/u/Niceno)\
**Post date:** [October 22, 2021, 8:21am UTC](https://discourse.julialang.org/t/error-when-importing-cudanative-or-just-about-anything-with-cuda/70198/1 "2021-10-22T08:21:35Z")

</div>

Dear all,

When I try to import `CUDAnative` into Julia 1.6.3, I get the following error:

```julia
julia> import Pkg; Pkg.add("CUDAnative")
   Resolving package versions...
ERROR: Unsatisfiable requirements detected for package CUDAapi [3895d2a7]:
 CUDAapi [3895d2a7] log:
 ├─possible versions are: 0.5.0-4.0.0 or uninstalled
 ├─restricted by compatibility requirements with CUDAnative [be33ccc6] to versions: 0.5.0-4.0.0
 │ └─CUDAnative [be33ccc6] log:
 │ ├─possible versions are: 0.7.0-3.2.0 or uninstalled
 │ └─restricted to versions * by an explicit requirement, leaving only versions 0.7.0-3.2.0
 └─restricted by julia compatibility requirements to versions: uninstalled — no versions left

```

I work on an Asus Strix ROG laptop, with Nvidia GeForce RTX card. The laptop is running Ubuntu 20.04. I have installed CUDA 10.1 Toolkit prior to installing Julia, which I built from the sources on github. (I somehow believed that if I have CUDA during the Julia compilation, it (Julia) will be aware of CUDA, but I could be wrong, of course).

I believe that installation of CUDA 10.1 was successful (albeit a very frustrating task), since the command: `nvidia-smi` gives me the following output:

```julia
Fri Oct 22 10:18:19 2021       
+-----------------------------------------------------------------------------+
| NVIDIA-SMI 495.29.05 Driver Version: 495.29.05 CUDA Version: 11.5 |
|-------------------------------+----------------------+----------------------+
| GPU Name Persistence-M| Bus-Id Disp.A | Volatile Uncorr. ECC |
| Fan Temp Perf Pwr:Usage/Cap| Memory-Usage | GPU-Util Compute M. |
| | | MIG M. |
|===============================+======================+======================|
| 0 NVIDIA GeForce ... On | 00000000:01:00.0 Off | N/A |
| N/A 38C P8 7W / N/A | 303MiB / 7982MiB | 6% Default |
| | | N/A |
+-------------------------------+----------------------+----------------------+
                                                                               
+-----------------------------------------------------------------------------+
| Processes: |
| GPU GI CI PID Type Process name GPU Memory |
| ID ID Usage |
|=============================================================================|
| 0 N/A N/A 922 G /usr/lib/xorg/Xorg 45MiB |
| 0 N/A N/A 1482 G /usr/lib/xorg/Xorg 152MiB |
| 0 N/A N/A 1649 G /usr/bin/gnome-shell 38MiB |
| 0 N/A N/A 44634 G ...AAAAAAAAA= --shared-files 55MiB |
+-----------------------------------------------------------------------------+

```

which should, to my limited experience, be an indication that CUDA is properly installed and that the OS is aware of CUDA libraries.

What could be going on here?

Cheers

---

<div class="post-metadata">

**Author:** ![maleadt](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/maleadt/32/10097_2.png) [@maleadt](https://discourse.julialang.org/u/maleadt)\
**Post date:** [October 22, 2021, 8:24am UTC](https://discourse.julialang.org/t/error-when-importing-cudanative-or-just-about-anything-with-cuda/70198/2 "2021-10-22T08:24:29Z")

</div>

CUDAnative.jl is deprecated, use CUDA.jl.

---

<div class="post-metadata">

**Author:** ![Niceno](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/niceno/32/29648_2.png) [@Niceno](https://discourse.julialang.org/u/Niceno)\
**Post date:** [October 22, 2021, 8:55am UTC](https://discourse.julialang.org/t/error-when-importing-cudanative-or-just-about-anything-with-cuda/70198/3 "2021-10-22T08:55:06Z")

</div>

Wow thanks, worked like a charm 🙂
