cedar-policy / cedar-spec

Definitional implementation of Cedar language and utilities for DRT
https://www.cedarpolicy.com
Apache License 2.0
74 stars 10 forks source link

Support builds On Mac #330

Open seanmcl opened 2 months ago

seanmcl commented 2 months ago

Before opening, please confirm:

Bug Category

Other

Describe the bug

I followed the instructions for osx. Got to here:

$ source cedar-drt/set_env_vars.sh
info: downloading component 'lean'
info: installing component 'lean'
cedar-drt/set_env_vars.sh:25: command not found: ldd
awk: syntax error at source line 1
 context is
    BEGIN {exit !( >>>  < <<<  2.27)}
awk: illegal statement at source line 1

ldd is indeed not a thing on mac.

Expected behavior

installation succeeds

Reproduction steps

$  git clone git@github.com:seanmcl/cedar-spec.git
$ brew install elan-init
$ elan default leanprover/lean4:stable
$ cd cedar-spec
$ source cedar-drt/set_env_vars.sh

Code Snippet

// Put your code below this line.

Log output

// Put your output below this line

Additional configuration

No response

Operating System

osx

Additional information and screenshots

No response

mwhicks1 commented 2 weeks ago

FYI, that error message can be ignored, very likely. The script is calling ldd to check for an old glibc, which is unlikely to be there on a Mac that was able to install Lean. Maybe we can gate the check with whether you are running on Linux or MacOs.

mwhicks1 commented 2 weeks ago

(I was able to build on my Mac just fine.)