tech-pkg archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: Lang/elixir shebang interpreter to a shebang
On Tue, May 21, 2019 at 12:18:12PM +0400, clment bouvier wrote:
> Hello,
>
> I'm testing the lang/elixir package.
> Mix tool is a kind of build tool provided with elixir. It is just a simple shell script with a shebang to an « elixir interpreter ».
> The problem is the following:
> « elixir » is not a binary interpreter but just a shell script wrapper (with #!/bin/sh) calling erl , a beam vm (Erlang virtual machine).
> mix crashes with "command not found error".
>
> Mainstream uses #!/usr/bin/env elixir in mix.
>
> lang/elixir uses REPLACE_FILES and REPLACE_INTERPRETER in the Makefile to change the pathname to the script interpreter.
>
> REPLACE_INTERPRETER+= elixir
> REPLACE.elixir.old= .*elixir
> REPLACE.elixir.new= ${PREFIX}/bin/elixir
> REPLACE_FILES.elixir= bin/mix
>
> So the mix command does not work as expected.
>
> I found pkg/51152 with the same kind of « bug ».
>
> What are the options to correct it?
>
> Clément.
>
Some shells are able to execute mix successfully, e.g. shells/mksh. NetBSD's
/bin/sh does not like the whole "interpreter with interpreter" situation.
Using another shell to run mix works as a temporary solution.
Another workaround is invoking mix as an argument to elixir, i.e.
`elixir ${PREFIX}/bin/mix`.
nia
Home |
Main Index |
Thread Index |
Old Index