I'm trying to run my own little smart contract in the plutus-pioneer-program
[fourth iteration] docker container and I'm having some problems. I've just added an extra folder alongside the other weeks. I've built this same code on other environments just fine but I got a new laptop with an M2 chip recently so my setup all broke and I figured running it in this environment would be the fastest way forward. I've narrowed the issue down to the playground-common
package that my build depends on. The problem is that when I run cabal build all
in my folder I get this error:
Build log (
/root/.cabal/logs/ghc-8.10.7/scrypt-0.5.0-833a2feabba78b918876049577f7c64bc2870cc56e8d7720fba2aa8ea196973a.log
):
Configuring library for scrypt-0.5.0..
cabal-3.6.2.0: Missing dependency on a foreign library:
* Missing (or bad) header file: crypto_scrypt.h
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 scrypt-0.5.0 (which is required by
elysium-contract-0.1.0.0). See the build log above for details.
I havent changed anything else in the project other than adding an additional folder under code
. Has something changed with the playground-common
package?
I also tried adding this configuration to a cabal.project.local
file, but no luck:
flags: -scrypt
tests: False
benchmarks: False
optimization: 2
Using cabal version 3.4
, base ^>=4.14.1.3.0
Other config:
, base ^>=4.14.1.3.0
, bytestring
, cardano-api
, containers
, data-default
, playground-common
, plutus-ledger-api
, plutus-tx-plugin
, plutus-tx
, serialise
, text
default-language: Haskell2010
ghc-options: -Wall -fobject-code -fno-ignore-interface-pragmas
-fno-omit-interface-pragmas -fno-strictness
-fno-spec-constr -fno-specialise -fexpose-all-unfoldings
-fplugin-opt PlutusTx.Plugin:defer-errors