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

ld: unknown option: -z error for osx build #59

Open
chenrui333 opened this issue Apr 17, 2022 · 2 comments
Open

ld: unknown option: -z error for osx build #59

chenrui333 opened this issue Apr 17, 2022 · 2 comments

Comments

@chenrui333
Copy link

👋 trying to build the latest release, but run into some build issue. The error log is as below:

build error
  ==> make check LDFLAGS= CFLAGS_EXTRA=
  clang  -D_FORTIFY_SOURCE=2 -fPIC   -c -o main.o main.c
  clang  -D_FORTIFY_SOURCE=2 -fPIC   -c -o crypto_scrypt-hexconvert.o crypto_scrypt-hexconvert.c
  ln -s -f libscrypt.so.0 libscrypt.so
  clang -o reference main.o b64.o crypto_scrypt-hexconvert.o  -D_FORTIFY_SOURCE=2 -fPIC -Wl,-z,relro -L.  -lscrypt
  ld: unknown option: -z
  clang: error: linker command failed with exit code 1 (use -v to see invocation)
  make: *** [reference] Error 1

full build log, https://github.com/Homebrew/homebrew-core/runs/5154594733
relates to Homebrew/homebrew-core#94934

@technion
Copy link
Owner

technion commented May 5, 2022

Hi,

Unfortunately I have no access to Mac environment and I'm going to need a Mac user to provide advise and a PR for this.

@risicle
Copy link

risicle commented May 21, 2022

The issue is that relro is an ELF thing and doesn't really mean anything on a Mach-O system as far as I can tell.

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

3 participants