# Compile Slicer in Ubuntu(20.04) fails

**URL:** https://discourse.slicer.org/t/compile-slicer-in-ubuntu-20-04-fails/23940
**Category:** Development
**Tags:** build
**Created:** [June 19, 2022, 11:07am UTC](https://discourse.slicer.org/t/compile-slicer-in-ubuntu-20-04-fails/23940 "2022-06-19T11:07:48Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![SteveLiu](https://avatars.discourse-cdn.com/v4/letter/s/13edae/32.png) [@SteveLiu](https://discourse.slicer.org/u/SteveLiu)
#### Post date: [June 19, 2022, 11:07am UTC](https://discourse.slicer.org/t/compile-slicer-in-ubuntu-20-04-fails/23940/1 "2022-06-19T11:07:48Z")

</div>

Operating system: Ubuntu20.04 (VirtualBox)  
Slicer version: latest version  
Expected behavior: make the project  
Actual behavior: make the project failure

git: git version 2.25.1  
cmake: cmake version 3.16.3

I created a new Ubuntu20.04 system in virtualbox. Downloaded the pre-requisites and made the project accroding to: [GNU/Linux systems — 3D Slicer documentation](https://slicer.readthedocs.io/en/latest/developer_guide/build_instructions/linux.html#any-distribution)

I am quite pointless about how to solve the error because of so many dependencies.  
This is the output from terminal: [ubuntu make slicer.txt - Google Drive](https://drive.google.com/file/d/1y3Khxtt8afd8uRKwjc61vx8_Caf9RFS1/view?usp=sharing)

 ![image](https://us1.discourse-cdn.com/flex002/uploads/slicer/original/3X/9/2/923098bf8e8869486420bc7895a5ca1c0cf0cf94.png)

---

<div class="post-metadata">

### Author: ![mau\_igna\_06](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/mau_igna_06/32/9056_2.png) [@mau\_igna\_06](https://discourse.slicer.org/u/mau_igna_06)
#### Post date: [June 19, 2022, 3:00pm UTC](https://discourse.slicer.org/t/compile-slicer-in-ubuntu-20-04-fails/23940/2 "2022-06-19T15:00:38Z")

</div>

Is dcmtk on your cmake variables?

---

<div class="post-metadata">

### Author: ![SteveLiu](https://avatars.discourse-cdn.com/v4/letter/s/13edae/32.png) [@SteveLiu](https://discourse.slicer.org/u/SteveLiu)
#### Post date: [June 19, 2022, 3:09pm UTC](https://discourse.slicer.org/t/compile-slicer-in-ubuntu-20-04-fails/23940/3 "2022-06-19T15:09:23Z")

</div>

Yes I didn’t change the default variables for Cmake. I was building release version and according to “common error” set git protocol=false

---

<div class="post-metadata">

### Author: ![mau\_igna\_06](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/mau_igna_06/32/9056_2.png) [@mau\_igna\_06](https://discourse.slicer.org/u/mau_igna_06)
#### Post date: [June 19, 2022, 3:10pm UTC](https://discourse.slicer.org/t/compile-slicer-in-ubuntu-20-04-fails/23940/4 "2022-06-19T15:10:48Z")

</div>

Did you try not doing that second thing?

---

<div class="post-metadata">

### Author: ![SteveLiu](https://avatars.discourse-cdn.com/v4/letter/s/13edae/32.png) [@SteveLiu](https://discourse.slicer.org/u/SteveLiu)
#### Post date: [June 19, 2022, 3:14pm UTC](https://discourse.slicer.org/t/compile-slicer-in-ubuntu-20-04-fails/23940/5 "2022-06-19T15:14:56Z")

</div>

Yes. I tried but did not work.  
Btw I use make -jN -k to use more cpu. I don’t know is it the problem. I am trying to use just make to build it again.

---

<div class="post-metadata">

### Author: ![pieper](https://sea2.discourse-cdn.com/flex002/user_avatar/discourse.slicer.org/pieper/32/8_2.png) [@pieper](https://discourse.slicer.org/u/pieper)
#### Post date: [June 19, 2022, 7:03pm UTC](https://discourse.slicer.org/t/compile-slicer-in-ubuntu-20-04-fails/23940/6 "2022-06-19T19:03:46Z")

</div>

I did a fresh build on ubuntu 20.04 and did not run into this error so it’s possibly something with your virtual box maybe running out of disk space or memory. I did `make -j20` on a 12 core machine. Try completely deleting your superbuild directory and starting from scratch in case there were any failed build files left behind by accident.
