<p>You probably need to install the development package:</p>
<p><code>apt install liblzma-dev</code></p>

CC BY-SA 4.0
2022-11-29T01:16:39.967Z
Works for me. Thanks.
Adam
CC BY-SA 4.0
2022-01-14T09:43:13.867Z
2022-01-14T09:43:13.867Z
Erik de Castro Lopo
<p>I am in a nix-shell and attempting to build the code for week 1. After lots of promising output, it fails with this error.</p>
<blockquote><pre>
Failed to build lzma-0.0.0.3. The failure occurred during the configure step.
Build log (
/Users/jwb/.cabal/logs/ghc-8.10.2.20201118/lzm-0.0.0.3-09eda932.log ):
Configuring library for lzma-0.0.0.3..
cabal: Missing dependency on a foreign library:
* Missing (or bad) header file: lzma.h
* Missing (or bad) C library: lzma
This problem can usually be solved by installing the system package that
provides this library (you may need the "-dev" version). If the library is
already installed but in a non-standard location then you can use the flags
--extra-include-dirs= and --extra-lib-dirs= to specify where it is.If the
library file does exist, it may contain errors that are caught by the C
compiler at the preprocessing stage. In this case you can re-run configure
with the verbosity flag -v3 to see the error messages.
If the header file does exist, it may contain errors that are caught by the C
compiler at the preprocessing stage. In this case you can re-run configure
with the verbosity flag -v3 to see the error messages.
<p>cabal: Failed to build lzma-0.0.0.3 (which is required by
plutus-pioneer-program-week01-0.1.0.0). See the build log above for details.
</pre></p>
</blockquote>
<p>I did cabal update beforehand, both outside and inside nix-shell. Any suggestions?</p>

CC BY-SA 4.0
2022-01-15T03:37:54.253Z
are you sure you're in the nix-shell window? Nix should build any external dependencies you need.
Samuel Leathers
CC BY-SA 4.0
2022-01-16T16:53:29.360Z
Still learning. I ended up completely re-installing the Plutus-playground, and then compiled this code directly in the playground, which worked, and which appears to be the "correct" way for these lessons. I needed to remove the module header code as demonstrated in the current Plutus Pioneers lesson #1 (https://www.youtube.com/watch?v=K61Si6iQ-Js&list=PLNEK_Ejlx3x2nLM4fAck2JS6KhFQlXq2N&index=5 from 1:10 to 1:40)  Perhaps the week 01 code is not intended to be built as an actual real app?
XiTouch
<plutus>
lzma-0.0.0.3 missing when building week 01 code
# lzma-0.0.0.3 missing when building week 01 code

(Asked by: username_0 on 2022-01-14)

I am in a nix-shell and attempting to build the code for week 1. After lots of promising output, it fails with this error.

Failed to build lzma-0.0.0.3. The failure occurred during the configure step.
Build log (
/Users/jwb/.cabal/logs/ghc-8.10.2.20201118/lzm-0.0.0.3-09eda932.log ):
Configuring library for lzma-0.0.0.3..
cabal: Missing dependency on a foreign library:
* Missing (or bad) header file: lzma.h
* Missing (or bad) C library: lzma
This problem can usually be solved by installing the system package that
provides this library (you may need the "-dev" version). If the library is
already installed but in a non-standard location then you can use the flags
--extra-include-dirs= and --extra-lib-dirs= to specify where it is.If the
library file does exist, it may contain errors that are caught by the C
compiler at the preprocessing stage. In this case you can re-run configure
with the verbosity flag -v3 to see the error messages.
If the header file does exist, it may contain errors that are caught by the C
compiler at the preprocessing stage. In this case you can re-run configure
with the verbosity flag -v3 to see the error messages.
cabal: Failed to build lzma-0.0.0.3 (which is required by
plutus-pioneer-program-week01-0.1.0.0). See the build log above for details.


I did cabal update beforehand, both outside and inside nix-shell. Any suggestions?

**Tags:** plutus
> **Comments:**
> **username_1**: are you sure you're in the nix-shell window? Nix should build any external dependencies you need.  
> **username_0**: Still learning. I ended up completely re-installing the Plutus-playground, and then compiled this code directly in the playground, which worked, and which appears to be the "correct" way for these lessons. I needed to remove the module header code as demonstrated in the current Plutus Pioneers lesson #1 (https://www.youtube.com/watch?v=K61Si6iQ-Js&list=PLNEK_Ejlx3x2nLM4fAck2JS6KhFQlXq2N&index=5 from 1:10 to 1:40)  Perhaps the week 01 code is not intended to be built as an actual real app?  

---

## 1 answers

### Answer by username_2 on 2022-01-14. Score: 4

You probably need to install the development package:

`apt install liblzma-dev`

> **Comments:**
> **username_3**: Works for me. Thanks.  

---

