Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

OS X Mavericks make install fails #9

Closed
ghost opened this issue Nov 3, 2013 · 3 comments
Closed

OS X Mavericks make install fails #9

ghost opened this issue Nov 3, 2013 · 3 comments

Comments

@ghost
Copy link

ghost commented Nov 3, 2013

When installing with 'make install' on OSX Mavericks, the install fails due to the appfile version number substitution.

sh-3.2# make install
erl -make
create dist directory and install files
mkdir -p /usr/lib/erlang/lib/uuid- {vsn, "0.4.4"},/ebin
install -m0644 ebin/* /usr/lib/erlang/lib/uuid- {vsn, "0.4.4"},/ebin
install: /usr/lib/erlang/lib/uuid-: Inappropriate file type or format
make: *** [install] Error 71
sh-3.2#

@avtobiff
Copy link
Owner

avtobiff commented Nov 6, 2013

Thanks for your bug report.

I don't have access to any machine with OSX Maverick, hence I can't debug this.

Do you have any idea why the regular expression fails? It works for me on Debian
GNU/Linux. (The sed regular expression in case is on lines four and five in Makefile.)

@zyro
Copy link

zyro commented Jun 7, 2014

The problem is \s is part of the GNU sed extensions and is not valid in the vanilla sed bundled with OSX, so the output is the entire line identified by /vsn/.

$> sed -n -e '/vsn/ {s/.*,\s*"\([0-9][0-9.]*\)".*/\1/' \
          -e 'p' -e '}' src/uuid.app.src
  {vsn, "0.4.6"}

Replacing it with a literal space works in OSX shell, but for script cross-compatibility it's probably best to use the POSIX character class [[:blank:]]:

$> sed -n -e '/vsn/ {s/.*,[[:blank:]]*"\([0-9][0-9.]*\)".*/\1/' \
          -e 'p' -e '}' src/uuid.app.src
0.4.6

Note that I've only tested this on OSX.

@avtobiff
Copy link
Owner

Fixed with 446dd9d

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants