Skip to content

macos 12.3.1 install libsass==0.18.0 report ld: library not found for -lc++ #390

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

Closed
jeffery9 opened this issue May 15, 2022 · 8 comments
Closed

Comments

@jeffery9
Copy link

jeffery9 commented May 15, 2022

when install with pip install libsass==0.18.0 raise compiling error

ld: library not found for -lc++
      clang: error: linker command failed with exit code 1 (use -v to see invocation)
      error: command 'clang++' failed with exit status 1
      [end of output]
  
  note: This error originates from a subprocess, and is likely not a problem with pip.
error: legacy-install-failure

× Encountered error while trying to install package.
╰─> libsass

@jeffery9 jeffery9 changed the title macos 12.3.1 report ld: library not found for -lc++ macos 12.3.1 install libsass==0.18.0 report ld: library not found for -lc++ May 15, 2022
@asottile
Copy link
Member

0.18.0 is very very old, also you might be missing the xcode build tools?

@asottile
Copy link
Member

also show the full output and the command you ran

@jeffery9
Copy link
Author

ref to issue odoo/documentation#2003

@jeffery9
Copy link
Author

clang++ -bundle -undefined dynamic_lookup -Wl,-headerpad,0x1000 -arch x86_64 build/temp.macosx-10.14-x86_64-3.8/libsass/src/ast.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/ast_fwd_decl.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/backtrace.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/base64vlq.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/bind.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/c99func.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/cencode.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/check_nesting.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/color_maps.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/constants.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/context.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/cssize.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/emitter.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/environment.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/error_handling.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/eval.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/expand.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/extend.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/file.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/functions.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/inspect.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/json.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/lexer.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/listize.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/memory/SharedPtr.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/node.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/operators.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/output.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/parser.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/plugins.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/position.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/prelexer.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/remove_placeholders.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/sass.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/sass2scss.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/sass_context.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/sass_functions.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/sass_util.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/sass_values.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/source_map.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/subset_map.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/to_c.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/to_value.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/units.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/utf8_string.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/util.o build/temp.macosx-10.14-x86_64-3.8/libsass/src/values.o build/temp.macosx-10.14-x86_64-3.8/pysass.o -o build/lib.macosx-10.14-x86_64-3.8/_sass.cpython-38-darwin.so -fPIC -stdlib=libc++ -mmacosx-version-min=10.7
      ld: library not found for -lc++
      clang: error: linker command failed with exit code 1 (use -v to see invocation)
      error: command 'clang++' failed with exit status 1
      [end of output]
  
  note: This error originates from a subprocess, and is likely not a problem with pip.

@asottile
Copy link
Member

usually the fix is xcode-select --install

@jeffery9
Copy link
Author

 $ xcode-select --install
xcode-select: error: command line tools are already installed, use "Software Update" to install updates


$ softwareupdate -ai
Software Update Tool

Finding available software
No updates are available.

@jeffery9
Copy link
Author

pip install libsass worked.

@asottile
Copy link
Member

sounds good, yeah try not using a 3 year old version :P

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