0

I am trying to install rebar3 using linuxbrew on Ubuntu 16.04.

After I execute brew install rebar3

distutils.errors.CompileError: command 'gcc-5' failed with exit status 1 /home/linuxbrew/.linuxbrew/Cellar/gobject-introspection/1.56.0/share/gobject-introspection-1.0/Makefile.introspection:159: recipe for target 'Pango-1.0.gir' failed

This error occurs when trying to install pango dependency.

My $PATH has /home/linuxbrew/.linuxbrew/bin:/home/linuxbrew/.linuxbrew/sbin:/home/linuxbrew/.linuxbrew/bin in it.

After I get this error, I manually installed pango using sudo apt-get install libghc-pango-dev

GCC version - 5.4.0

Kernel - 4.13.0-37

But still I get the same error again and again.

Cœur
  • 37,241
  • 25
  • 195
  • 267
Sachith Muhandiram
  • 2,819
  • 10
  • 45
  • 94

2 Answers2

1

libghc means it's a binding for haskell.

I believe you need libpango1.0-dev

Odobenus Rosmarus
  • 5,870
  • 2
  • 18
  • 21
1

rebar3 is just one file. Have a look at the documentation on how to install it.

Linuxbrew doesn't work quite as well as Homebrew (in macOS), so for a lot of packages you will find out losing more time trying to make it work than just using alternatives.

In any case, if you choose that route it will be something like (1) downloading the rebar3 binary, (2) making it executable and (3) putting it somewhere that's available anywhere — in your user's PATH.


Another approach would be to use Nix: nix-env --install --prebuilt-only rebar3 — way easier although the introduction to it takes more time.

x80486
  • 6,627
  • 5
  • 52
  • 111
  • Yes, I tried to install rebar3 alone, but it didn't work either. `/home/sachith/rebar3/_build/default/lib/erlware_commons/src/ec_dictionary.erl:none: no such file or directory` – Sachith Muhandiram Mar 16 '18 at 02:35
  • When I try `nix` as you suggested, **error: build of '/nix/store/wdn5dk0a4ggqj740xabdjr58gxzda397-rebar3-3.4.3.drv' failed** – Sachith Muhandiram Mar 16 '18 at 03:20
  • 1
    `rebar3` does not bundle Erlang. You need to install it beforehand. Then you can simply do `wget https://s3.amazonaws.com/rebar3/rebar3 && chmod +x rebar3` and in that same folder execute: `./rebar3 --version`...then you should get something like: `rebar 3.5.0 on Erlang/OTP 20 Erts 9.2`. – x80486 Mar 16 '18 at 13:48