Month: October 2019

homebrew install Error

Problem

An error “Permission denied @ apply2files – /usr/local/share/ghostscript/9.23/Resource/CIDFSubst/Deng.ttf” occurred when I tried to update homebrew.

What is homebrew?

Homebrew is a package management system to install and update software for macOS.
(Official link: https://brew.sh/index_en)

What is ghostscript?

Homebrew is a package management system to install and update software for macOS.
(Official link: https://brew.sh/index_en)
Ghostscript is invoked and started by other software including homebrew.

The Resource / CIDFSubst directory is a directory to store TrueType fonts (but there is no problem here).

Cause of the error

Because the error message says “Permission denied”, the current user does not have access. So it seems that homebrew cannot use the required files.

Solution

As an immediate solution, give access to the ghostscript directory with the following command. You will be prompted for a password.

sudo chown -R <UserName>:admin /usr/local/share/ghostscript

Now you can run without error. It remains unclear why the access was lost.

homebrew install Error

現象

brewコマンドを使用した時、homebrewのアップデートが行われ、次のエラーが出ました。”Permission denied @ apply2files – /usr/local/share/ghostscript/9.23/Resource/CIDFSubst/Deng.ttf”

homebrewとは

homebrewは、macOSで使われるパッケージマネージメントシステムであり、ソフトウェアのインストールやアップデートを行います。(公式リンク:https://brew.sh/index_ja)

ghostscriptとは

エラー文に書かれているghostscriptとは、アドビシステムズのPostScriptとPDFのインタプリタです(公式リンク:https://www.ghostscript.com/)。いくつかの他のソフトウェアから呼び出されて起動し、homebrewもまたghostscriptを使用します。

Resource/CIDFSubstディレクトリは、TrueTypeフォントを格納したディレクトリです(が、ここに問題がある訳ではありません)。

エラーの原因

Permission denied とあるので、アクセス権限が得られておらず、homebrewが必要とするファイルにアクセスできないようです。

解決法

当座の解決方法として、以下のコマンドでghostscriptディレクトリにアクセス権限を与えることができます。パスワードの入力が求められます。

sudo chown -R <UserName>:admin /usr/local/share/ghostscript

これでエラー無く実行できます。なぜ、権限が外れてしまったのかについては不明なままでした。

My Summer Activities 2019

Hello.

I took part in an internship at animation studio as a software engineer.
I won’t go into details for confidentiality reasons, but it was good experience. Everyone was kind and supportive to me. That’s why my blog update was delayed.

By the way, I got the results back from a license examination called “CG Engineer Certification Test” by CG-ARTS. To my joy, I was able to pass the test with full marks.

For fun, I went Tokyo, Osaka and Nagoya and meet friends in this summer.

I have to get down to work and write a master’s thesis, so I will update this blog at a slow pace.