Skip to content
This repository has been archived by the owner on May 15, 2023. It is now read-only.

Failure when installing sass_embedded in a docker container #104

Closed
omidontop opened this issue Aug 9, 2022 · 5 comments
Closed

Failure when installing sass_embedded in a docker container #104

omidontop opened this issue Aug 9, 2022 · 5 comments

Comments

@omidontop
Copy link

When adding sass-embedded to the Gemfile, the installation fails on a docker image based on jekyll/jekyll:4.2.2 and on a amd64 machine. Here's the output:

Fetching sass-embedded-1.54.3.gem
Successfully installed google-protobuf-3.21.4-x86_64-linux
Building native extensions. This could take a while...
ERROR:  Error installing sass-embedded:
        ERROR: Failed to build gem native extension.

    current directory: /usr/gem/gems/sass-embedded-1.54.3/ext/sass
/usr/local/bin/ruby -I/usr/local/lib/ruby/site_ruby/3.1.0 -rrubygems /usr/local/lib/ruby/gems/3.1.0/gems/rake-13.0.6/exe/rake RUBYARCHDIR\=/usr/gem/extensions/x86_64-linux-musl/3.1.0/sass-embedded-1.54.3 RUBYLIBDIR\=/usr/gem/extensions/x86_64-linux-musl/3.1.0/sass-embedded-1.54.3
rake aborted!
NotImplementedError: sass_embedded for x86_64-linux-musl not available at https://github.com/sass/dart-sass-embedded/releases/tag/1.54.3
/usr/gem/gems/sass-embedded-1.54.3/ext/sass/Rakefile:177:in `default_sass_embedded'
/usr/gem/gems/sass-embedded-1.54.3/ext/sass/Rakefile:19:in `block (2 levels) in <top (required)>'
/usr/gem/gems/sass-embedded-1.54.3/ext/sass/Rakefile:19:in `fetch'
/usr/gem/gems/sass-embedded-1.54.3/ext/sass/Rakefile:19:in `block in <top (required)>'
Tasks: TOP => default => install => sass_embedded
(See full trace by running task with --trace)

rake failed, exit code 1

Gem files will remain installed in /usr/gem/gems/sass-embedded-1.54.3 for inspection.
@ntkme
Copy link
Contributor

ntkme commented Aug 9, 2022

musl-libc is still not supported by dart-lang. So, currently you must use a glibc based container image.

@nex3
Copy link
Contributor

nex3 commented Aug 9, 2022

Duplicate of sass/embedded-host-node#155. Consider adding a 👍 react to dart-lang/sdk#40906 if you'd like to see Dart support musl-libc.

@nex3 nex3 closed this as not planned Won't fix, can't repro, duplicate, stale Aug 9, 2022
@fuhlig
Copy link

fuhlig commented Aug 15, 2022

Used sass@1.51.0 and sass-embedded@1.15.1 before and it worked.
Any changes to the latest release(s) (1.51.3) that changed that?

@nex3
Copy link
Contributor

nex3 commented Aug 15, 2022

There shouldn't be, no. There's no reason that Sass 1.51.0 would work in musl-linux.

@fuhlig
Copy link

fuhlig commented Aug 17, 2022

Thanks for your quick reply @nex3 !

Before this change was made in 1.51.2sass/embedded-host-node@08dd528 the installation worked.

Within our build process, a check for OS to switch between sass (CI: linux) and sass-embedded (local dev env: osx, windows):

((arch() === 'x64' && platform() === 'linux') ? require('sass') : require('sass-embedded'))

This worked fine.

Maybe the check for musl- should not throw an error and prevent installing but throw a warning with a reference to docs that describe a workaround?

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

No branches or pull requests

4 participants