<p>I have run into this issue previously with my M1 Mac but forgot the exact solution used. But configuring my cabal build with <code>-external-libsodium-vrf</code> resolved the issue. I ran the following commands:</p>
<pre><code>cabal configure --enable-tests --enable-executable-dynamic -f -external-libsodium-vrf
cabal build plutus-pab-examples
</code></pre>
<p>Then I'm able to run</p>
<pre><code>cabal exec -- plutus-pab-examples
</code></pre>
<p>Note also that I'm running the above in <code>nix-shell</code> of <a href="https://github.com/input-output-hk/plutus-apps" rel="nofollow noreferrer">plutus-apps</a>, which I believe is required for the build to access <code>crypto-vrf</code>.</p>

CC BY-SA 4.0
2022-02-28T19:20:10.603Z
2022-02-28T19:20:10.603Z
carleryd
<p>I have been trying to get the new <a href="https://github.com/input-output-hk/plutus-apps/pull/55" rel="nofollow noreferrer">PAB</a> beta release to compile on my M1 Mac and have run into an issue.</p>
<pre><code>Build log (
/Users/isaacpadberg/.cabal/logs/ghc-8.10.4/crdn-nd-1.30.0-8154d373.log ):
Configuring executable 'cardano-node' for cardano-node-1.30.0..
Warning: The package has an extraneous version range for a dependency on an
internal library: cardano-node &gt;=0 &amp;&amp; ==1.30.0, cardano-node &gt;=0 &amp;&amp; ==1.30.0.
This version range includes the current package but isn't needed as the
current package's library will always be used.
Preprocessing executable 'cardano-node' for cardano-node-1.30.0..
Building executable 'cardano-node' for cardano-node-1.30.0..
[1 of 2] Compiling Paths_cardano_node ( dist/build/cardano-node/autogen/Paths_cardano_node.hs, dist/build/cardano-node/cardano-node-tmp/Paths_cardano_node.o )
[2 of 2] Compiling Main             ( app/cardano-node.hs, dist/build/cardano-node/cardano-node-tmp/Main.o )
Linking dist/build/cardano-node/cardano-node ...
Undefined symbols for architecture x86_64:
  &quot;_crypto_vrf_proof_to_hash&quot;, referenced from:
      _Lcjo6_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
  &quot;_crypto_vrf_prove&quot;, referenced from:
      _LcjhT_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
  &quot;_crypto_vrf_verify&quot;, referenced from:
      _Lcj0W_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
  &quot;_crypto_vrf_secretkeybytes&quot;, referenced from:
      _crdnzmcryptzmprszm2zi0zi0zm3e9b3fc3_CardanoziCryptoziVRFziPraos_signKeySizzeVRF_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
      _LcjE7_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
  &quot;_crypto_vrf_keypair_from_seed&quot;, referenced from:
      _LcjaN_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
  &quot;_crypto_vrf_sk_to_pk&quot;, referenced from:
      _Lcj8e_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
  &quot;_crypto_vrf_publickeybytes&quot;, referenced from:
      _crdnzmcryptzmprszm2zi0zi0zm3e9b3fc3_CardanoziCryptoziVRFziPraos_verKeySizzeVRF_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
      _Lcjsy_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
  &quot;_crypto_vrf_proofbytes&quot;, referenced from:
      _crdnzmcryptzmprszm2zi0zi0zm3e9b3fc3_CardanoziCryptoziVRFziPraos_certSizzeVRF_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
  &quot;_crypto_vrf_outputbytes&quot;, referenced from:
      _crdnzmcryptzmprszm2zi0zi0zm3e9b3fc3_CardanoziCryptoziVRFziPraos_zdfVRFAlgorithmPraosVRFzuzdcsizzeOutputVRF_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
      _crdnzmcryptzmprszm2zi0zi0zm3e9b3fc3_CardanoziCryptoziVRFziPraos_vrfKeySizzeVRF_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
      _crdnzmcryptzmprszm2zi0zi0zm3e9b3fc3_CardanoziCryptoziVRFziPraos_verify1_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
  &quot;_crypto_vrf_seedbytes&quot;, referenced from:
      _crdnzmcryptzmprszm2zi0zi0zm3e9b3fc3_CardanoziCryptoziVRFziPraos_zdfVRFAlgorithmPraosVRFzuzdcseedSizzeVRF_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
      _crdnzmcryptzmprszm2zi0zi0zm3e9b3fc3_CardanoziCryptoziVRFziPraos_zdfVRFAlgorithmPraosVRF4_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
      _crdnzmcryptzmprszm2zi0zi0zm3e9b3fc3_CardanoziCryptoziVRFziPraos_zdfVRFAlgorithmPraosVRF5_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
      _crdnzmcryptzmprszm2zi0zi0zm3e9b3fc3_CardanoziCryptoziVRFziPraos_zdfVRFAlgorithmPraosVRF2_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
      _LshEK_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
`gcc' failed in phase `Linker'. (Exit code: 1)
</code></pre>
<p>It seems that the crypto_vrf library is either incompatible with this processor, or its just missing.</p>
<p>Any help is greatly appreciated!</p>

CC BY-SA 4.0
2021-11-15T15:31:14.573Z
I may suggest you getting into building with nix [plutus-apps#nix-on-macos](https://github.com/input-output-hk/plutus-apps#nix-on-macos) nix should be taking care of those dependencies for you.
andycandy
<pab><error><m1>
Issue compiling pab-local-cluster on M1 processor
# Issue compiling pab-local-cluster on M1 processor

(Asked by: username_0 on 2021-11-12)

I have been trying to get the new PAB beta release to compile on my M1 Mac and have run into an issue.
Build log (
/Users/isaacpadberg/.cabal/logs/ghc-8.10.4/crdn-nd-1.30.0-8154d373.log ):
Configuring executable 'cardano-node' for cardano-node-1.30.0..
Warning: The package has an extraneous version range for a dependency on an
internal library: cardano-node >=0 && ==1.30.0, cardano-node >=0 && ==1.30.0.
This version range includes the current package but isn't needed as the
current package's library will always be used.
Preprocessing executable 'cardano-node' for cardano-node-1.30.0..
Building executable 'cardano-node' for cardano-node-1.30.0..
[1 of 2] Compiling Paths_cardano_node ( dist/build/cardano-node/autogen/Paths_cardano_node.hs, dist/build/cardano-node/cardano-node-tmp/Paths_cardano_node.o )
[2 of 2] Compiling Main             ( app/cardano-node.hs, dist/build/cardano-node/cardano-node-tmp/Main.o )
Linking dist/build/cardano-node/cardano-node ...
Undefined symbols for architecture x86_64:
  "_crypto_vrf_proof_to_hash", referenced from:
      _Lcjo6_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
  "_crypto_vrf_prove", referenced from:
      _LcjhT_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
  "_crypto_vrf_verify", referenced from:
      _Lcj0W_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
  "_crypto_vrf_secretkeybytes", referenced from:
      _crdnzmcryptzmprszm2zi0zi0zm3e9b3fc3_CardanoziCryptoziVRFziPraos_signKeySizzeVRF_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
      _LcjE7_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
  "_crypto_vrf_keypair_from_seed", referenced from:
      _LcjaN_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
  "_crypto_vrf_sk_to_pk", referenced from:
      _Lcj8e_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
  "_crypto_vrf_publickeybytes", referenced from:
      _crdnzmcryptzmprszm2zi0zi0zm3e9b3fc3_CardanoziCryptoziVRFziPraos_verKeySizzeVRF_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
      _Lcjsy_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
  "_crypto_vrf_proofbytes", referenced from:
      _crdnzmcryptzmprszm2zi0zi0zm3e9b3fc3_CardanoziCryptoziVRFziPraos_certSizzeVRF_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
  "_crypto_vrf_outputbytes", referenced from:
      _crdnzmcryptzmprszm2zi0zi0zm3e9b3fc3_CardanoziCryptoziVRFziPraos_zdfVRFAlgorithmPraosVRFzuzdcsizzeOutputVRF_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
      _crdnzmcryptzmprszm2zi0zi0zm3e9b3fc3_CardanoziCryptoziVRFziPraos_vrfKeySizzeVRF_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
      _crdnzmcryptzmprszm2zi0zi0zm3e9b3fc3_CardanoziCryptoziVRFziPraos_verify1_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
  "_crypto_vrf_seedbytes", referenced from:
      _crdnzmcryptzmprszm2zi0zi0zm3e9b3fc3_CardanoziCryptoziVRFziPraos_zdfVRFAlgorithmPraosVRFzuzdcseedSizzeVRF_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
      _crdnzmcryptzmprszm2zi0zi0zm3e9b3fc3_CardanoziCryptoziVRFziPraos_zdfVRFAlgorithmPraosVRF4_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
      _crdnzmcryptzmprszm2zi0zi0zm3e9b3fc3_CardanoziCryptoziVRFziPraos_zdfVRFAlgorithmPraosVRF5_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
      _crdnzmcryptzmprszm2zi0zi0zm3e9b3fc3_CardanoziCryptoziVRFziPraos_zdfVRFAlgorithmPraosVRF2_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
      _LshEK_info in libHScrdn-crypt-prs-2.0.0-3e9b3fc3.a(Praos.o)
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
`gcc' failed in phase `Linker'. (Exit code: 1)

It seems that the crypto_vrf library is either incompatible with this processor, or its just missing.
Any help is greatly appreciated!

**Tags:** pab, error, m1
> **Comments:**
> **username_1**: I may suggest you getting into building with nix [plutus-apps#nix-on-macos](https://github.com/input-output-hk/plutus-apps#nix-on-macos) nix should be taking care of those dependencies for you.  

---

## 1 answers

### Answer by username_2 on 2022-02-28. Score: 0

I have run into this issue previously with my M1 Mac but forgot the exact solution used. But configuring my cabal build with -external-libsodium-vrf resolved the issue. I ran the following commands:
cabal configure --enable-tests --enable-executable-dynamic -f -external-libsodium-vrf
cabal build plutus-pab-examples

Then I'm able to run
cabal exec -- plutus-pab-examples

Note also that I'm running the above in nix-shell of plutus-apps, which I believe is required for the build to access crypto-vrf.


---

