Homebrew.jl
Homebrew.jl copied to clipboard
Error for building fontconfig
@staticfloat
OSX Sierra + Julia 0.6.2 (fresh install)
When building Homebrew, it failed with the following error message
==> Installing fontconfig from staticfloat/juliatranslated
==> Downloading https://homebrew.bintray.com/bottles/fontconfig-2.12.6.el_capita
Already downloaded: /Users/xiaoweiz/Library/Caches/Homebrew.jl/fontconfig-2.12.6.el_capitan.bottle.tar.gz
==> Pouring fontconfig-2.12.6.el_capitan.bottle.tar.gz
==> Regenerating font cache, this may take a while
==> /Users/xiaoweiz/.julia/v0.6/Homebrew/deps/usr/Cellar/fontconfig/2.12.6/bin/f
Last 15 lines from /Users/xiaoweiz/Library/Logs/Homebrew/fontconfig/post_install.01.fc-cache:
-frv
/usr/share/fonts: skipping, no such directory
/System/Library/Fonts: caching, new cache contents: 281 fonts, 0 dirs
/Library/Fonts: /Library/Fonts: failed to write cache
caching, new cache contents: 419 fonts, 1 dirs
/Library/Fonts/Microsoft: caching, new cache contents: 207 fonts, 0 dirs
/Users/xiaoweiz/Library/Fonts: /Users/xiaoweiz/Library/Fonts: failed to write cache
caching, new cache contents: 2579 fonts, 0 dirs
/Users/xiaoweiz/.local/share/fonts: skipping, no such directory
/Users/xiaoweiz/.fonts: skipping, no such directory
/usr/local/var/cache/fontconfig: not cleaning unwritable cache directory
/Users/xiaoweiz/.cache/fontconfig: not cleaning unwritable cache directory
/Users/xiaoweiz/.fontconfig: not cleaning non-existent cache directory
/Users/xiaoweiz/.julia/v0.6/Homebrew/deps/usr/Cellar/fontconfig/2.12.6/bin/fc-cache: failed
Warning: The post-install step did not complete successfully
You can try again using `brew postinstall staticfloat/juliatranslated/fontconfig`
==> Summary
🍺 /Users/xiaoweiz/.julia/v0.6/Homebrew/deps/usr/Cellar/fontconfig/2.12.6: 493 files, 3.2MB
===================================[ ERROR: Homebrew ]====================================
LoadError: failed process: Process(`/Users/xiaoweiz/.julia/v0.6/Homebrew/deps/usr/bin/brew install --ignore-dependencies staticfloat/juliatranslated/fontconfig`, ProcessExited(1)) [1]
while loading /Users/xiaoweiz/.julia/v0.6/Homebrew/deps/build.jl, in expression starting on line 2
+1
Curiously, the step succeeds when run directly from the shell
shell> ./fc-cache -frv /usr/share/fonts: skipping, no such directory
/System/Library/Fonts: caching, new cache contents: 337 fonts, 0 dirs /Library/Fonts: caching, new cache contents: 370 fonts, 0 dirs
/Users/skleinbo/Library/Fonts: caching, new cache contents: 0 fonts, 0 dirs
/System/Library/Assets/com_apple_MobileAsset_Font4: caching, new cache contents: 0 fonts, 0 dirs
/Users/skleinbo/.local/share/fonts: skipping, no such directory
/Users/skleinbo/.fonts: skipping, no such directory
/usr/local/var/cache/fontconfig: not cleaning unwritable cache directory
/Users/skleinbo/.cache/fontconfig: cleaning cache directory
/Users/skleinbo/.fontconfig: not cleaning non-existent cache directory
./fc-cache: succeeded
+1
Try:
using Homebrew
Homebrew.brew(`reinstall fontconfig`)
Pkg.build("Homebrew")
@stillyslalom That didn't help.
julia> Homebrew.brew(`reinstall fontconfig`)
==> Reinstalling staticfloat/juliatranslated/fontconfig
==> Downloading https://homebrew.bintray.com/bottles/fontconfig-2.12.6.high_sierra.bottle.tar.gz
Already downloaded: /Users/cmey/Library/Caches/Homebrew.jl/fontconfig-2.12.6.high_sierra.bottle.tar.gz
==> Pouring fontconfig-2.12.6.high_sierra.bottle.tar.gz
==> Regenerating font cache, this may take a while
==> /Users/cmey/.julia/v0.6/Homebrew/deps/usr/Cellar/fontconfig/2.12.6/bin/fc-cache -frv
Last 15 lines from /Users/cmey/Library/Logs/Homebrew/fontconfig/post_install.01.fc-cache:
/Users/cmey/.julia/v0.6/Homebrew/deps/usr/Cellar/fontconfig/2.12.6/bin/fc-cache
-frv
/usr/share/fonts: skipping, no such directory
/System/Library/Fonts: caching, new cache contents: 337 fonts, 0 dirs
/Library/Fonts: /Library/Fonts: failed to write cache
caching, new cache contents: 375 fonts, 0 dirs
/Users/cmey/Library/Fonts: caching, new cache contents: 146 fonts, 0 dirs
/Users/cmey/.local/share/fonts: skipping, no such directory
/Users/cmey/.fonts: skipping, no such directory
/usr/local/var/cache/fontconfig: not cleaning unwritable cache directory
/Users/cmey/.cache/fontconfig: not cleaning unwritable cache directory
/Users/cmey/.fontconfig: not cleaning non-existent cache directory
/Users/cmey/.julia/v0.6/Homebrew/deps/usr/Cellar/fontconfig/2.12.6/bin/fc-cache: failed
Warning: The post-install step did not complete successfully
You can try again using `brew postinstall staticfloat/juliatranslated/fontconfig`
==> Summary
🍺 /Users/cmey/.julia/v0.6/Homebrew/deps/usr/Cellar/fontconfig/2.12.6: 493 files, 3.2MB
ERROR: failed process: Process(`/Users/cmey/.julia/v0.6/Homebrew/deps/usr/bin/brew reinstall fontconfig`, ProcessExited(1)) [1]
Stacktrace:
[1] pipeline_error(::Base.Process) at ./process.jl:682
[2] run(::Cmd) at ./process.jl:651
[3] #brew#4(::Bool, ::Bool, ::Bool, ::Bool, ::Bool, ::Function, ::Cmd) at /Users/cmey/.julia/v0.6/Homebrew/src/API.jl:19
[4] brew(::Cmd) at /Users/cmey/.julia/v0.6/Homebrew/src/API.jl:11
@skleinbo That helped! I did:
shell> cd /Users/cmey/.julia/v0.6/Homebrew/deps/usr/Cellar/fontconfig/2.12.6/bin
shell> ./fc-cache -frv
julia> Pkg.build("Homebrew") # worked fine this time
+1 for problem and solution by @skleinbo.
as noted here, the following is a workaround, which works for me
$ ~/.julia/v0.6/Homebrew/deps/usr/Cellar/fontconfig/2.12.6/bin/fc-cache -frv
(posted in the wrong thread, sorry!)
Heads up this is still needed in Julia 1.0.2. The path that worked for me was
➜ ~ ~/.julia/packages/Homebrew/l8kUw/deps/usr/Cellar/fontconfig/2.13.1/bin/fc-cache -frv
Still a problem in Julia 1.1.1. The updated command to manually fix it is below. I don't know how to fix it in code here.
Problem: during the build of Cairo:
│ /Users/cmeyer/.julia/packages/Homebrew/s09IX/deps/usr/Cellar/fontconfig/2.13.1/bin/fc-cache: failed
│ Warning: The post-install step did not complete successfully
Fix is to run this, in your terminal:
~/.julia/packages/Homebrew/s09IX/deps/usr/Cellar/fontconfig/2.13.1/bin/fc-cache -frv
Output:
/Users/cmeyer/.julia/packages/Homebrew/s09IX/deps/usr/Cellar/fontconfig/2.13.1/bin/fc-cache: succeeded
Then:
(v1.1) pkg> build Cairo # works fine this time
(v1.1) pkg> build # you probably want to rebuild all packages that depend on Cairo