<p>Library modules provided by github/libbitcoin (incl. forked version of libsecp256k1) are by default installed using prefix <code>/usr/local</code>. <code>configure</code> script, that is run during build process, however, doesn't by default search for dependencies in <code>/usr/local</code>. So in order to make <code>configure</code> find other modules, one has to change the prefix for each module or tell the <code>configure</code> script where to look for the libraries - e. g. by setting variable PKG_CONFIG_PATH before running the script:<br>
<code>export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig</code>.<br>
<code>pkgconfig</code> directory contains configuration files with all needed information for those affected dependencies, so if the variable is set correctly, <code>configure</code> script will find them and compilation will be successful.</p>

<p>P. S. the compilation of <code>libsecp256k1</code> needs to be done with flag <code>--enable-module-recovery</code> so as to be compatible with libbitcoin.</p>

CC BY-SA 3.0
2018-04-14T23:00:04.067Z
2018-04-14T23:00:04.067Z
jakob
<p>I'm trying to build libbitcoin libraries on Arch linux.
First I tried to download AUR packages. I successfully installed libsecp256k1 and libbitcoin. But if I try to compile libbitcoin-system and libbitcoin-database, compilation fails. The problem is conflict between libsecp256k1 and secp256k1 packages. The first is dependency of system and second of libbitcoin. If I trick the checking of secp256k1/libsecp256k1 library presence, the compilation fails on unit-testing. I'm also quite confused when looking on AUR repository. There is always  and -git (e.g. libbitcoin-database and libbitcoin-database-git). I tried every possible combination, but was never successful.</p>

<p>I also tried to download sources from github. First of all: I don't know whether to run standard <code>./autogen.sh &amp;&amp; ./configure &amp;&amp; make -j4 &amp;&amp; sudo make install</code> or rather <code>sudo ./install.sh</code>.
<br>
Again I successfully installed library secp256k1 and libbitcoin using the first approach, but when running ./configure in libbitcoin-database, i get error
<br></p>

<pre><code>configure: error: Package requirements (libbitcoin &gt;= 4.0.0) were not met
</code></pre>

<p>Please has anybody successfully installed libbitcoin libraries on Arch linux?</p>

CC BY-SA 3.0
2017-10-20T21:11:28.470Z
Welcome to Bitcoin SE!  You may want to try asking this question to an Arch community forum.  I wouldn't say that this question is off topic here (so by all means, leave it), but since your problem seems Arch-specific you'll likely get better answers elsewhere.  Also, when you find your answer, please post it here.  It's perfectly acceptable to answer your own question, and helps out the whole community.
Jestin
<linux><database><compiling><libbitcoin>
Building libbitcoin libraries on Arch linux fails
jakob
# Building libbitcoin libraries on Arch linux fails

(Asked by: username_0 on 2017-10-20)

I'm trying to build libbitcoin libraries on Arch linux.
First I tried to download AUR packages. I successfully installed libsecp256k1 and libbitcoin. But if I try to compile libbitcoin-system and libbitcoin-database, compilation fails. The problem is conflict between libsecp256k1 and secp256k1 packages. The first is dependency of system and second of libbitcoin. If I trick the checking of secp256k1/libsecp256k1 library presence, the compilation fails on unit-testing. I'm also quite confused when looking on AUR repository. There is always and -git (e.g. libbitcoin-database and libbitcoin-database-git). I tried every possible combination, but was never successful.

I also tried to download sources from github. First of all: I don't know whether to run standard `./autogen.sh && ./configure && make -j4 && sudo make install` or rather `sudo ./install.sh`.
  
Again I successfully installed library secp256k1 and libbitcoin using the first approach, but when running ./configure in libbitcoin-database, i get error

```
configure: error: Package requirements (libbitcoin >= 4.0.0) were not met

```

Please has anybody successfully installed libbitcoin libraries on Arch linux?

**Tags:** linux, database, compiling, libbitcoin

> **Comments:**
> **username_1**: Welcome to Bitcoin SE!  You may want to try asking this question to an Arch community forum.  I wouldn't say that this question is off topic here (so by all means, leave it), but since your problem seems Arch-specific you'll likely get better answers elsewhere.  Also, when you find your answer, please post it here.  It's perfectly acceptable to answer your own question, and helps out the whole community.  

---

## 1 answers

### Answer by username_0 on 2018-04-14. Score: 2 | Accepted answer

Library modules provided by github/libbitcoin (incl. forked version of libsecp256k1) are by default installed using prefix `/usr/local`. `configure` script, that is run during build process, however, doesn't by default search for dependencies in `/usr/local`. So in order to make `configure` find other modules, one has to change the prefix for each module or tell the `configure` script where to look for the libraries - e. g. by setting variable PKG\_CONFIG\_PATH before running the script:  
`export PKG_CONFIG_PATH=/usr/local/lib/pkgconfig`.  
`pkgconfig` directory contains configuration files with all needed information for those affected dependencies, so if the variable is set correctly, `configure` script will find them and compilation will be successful.

P. S. the compilation of `libsecp256k1` needs to be done with flag `--enable-module-recovery` so as to be compatible with libbitcoin.


---

