Help us understand the problem. What is going on with this article?

macOS High Sierra 10.13.6 + homebrew で leveldb をインストール

More than 1 year has passed since last update.

macOS High Sierra 10.13.6 + homebrew で leveldb をインストール

セミナー用のガイダンス

leveldb

leveldb のためのformulaがあるか検索

$ brew search leveldb
==> Formulae
leveldb                                  redis-leveldb

存在したので更にoption をチェックする

$ brew options leveldb
--with-test
    Verify the build with make check

leveldbのインストール

ということなので、--with-test オプションを指定してインストール

$ brew install leveldb --with-test
==> Installing dependencies for leveldb: gperftools, snappy
==> Installing leveldb dependency: gperftools
==> Downloading https://homebrew.bintray.com/bottles/gperftools-2.7.high_sierra.
######################################################################## 100.0%
==> Pouring gperftools-2.7.high_sierra.bottle.tar.gz
🍺  /usr/local/Cellar/gperftools/2.7: 103 files, 4.3MB
==> Installing leveldb dependency: snappy
==> Downloading https://homebrew.bintray.com/bottles/snappy-1.1.7_1.high_sierra.
######################################################################## 100.0%
==> Pouring snappy-1.1.7_1.high_sierra.bottle.tar.gz
🍺  /usr/local/Cellar/snappy/1.1.7_1: 18 files, 118KB
==> Installing leveldb --with-test
==> Downloading https://github.com/google/leveldb/archive/v1.20.tar.gz
==> Downloading from https://codeload.github.com/google/leveldb/tar.gz/v1.20
######################################################################## 100.0%
==> make
Last 15 lines from /Users/percipere/Library/Logs/Homebrew/leveldb/01.make:
2018-07-21 19:39:28 +0900

make

mkdir out-shared
clang++ -I. -I./include -std=c++0x  -DOS_MACOSX -DLEVELDB_PLATFORM_POSIX -DLEVELDB_ATOMIC_PRESENT -DSNAPPY -O2 -DNDEBUG -fPIC -c db/db_bench.cc -o out-shared/db/db_bench.o
error: unable to open output file 'out-shared/db/db_bench.o': 'No such file or directory'
1 error generated.
make: *** [out-shared/db/db_bench.o] Error 1
make: *** Waiting for unfinished jobs....

READ THIS: https://docs.brew.sh/Troubleshooting

エラー対応

db_bench.oが無いというエラーが発生
ファイル名からは大きな影響が無いかもしれないので、とりあえず再度実行してみる

$ brew install leveldb --with-test
==> Downloading https://github.com/google/leveldb/archive/v1.20.tar.gz
Already downloaded: /Users/percipere/Library/Caches/Homebrew/leveldb-1.20.tar.gz
==> make
==> make check
🍺  /usr/local/Cellar/leveldb/1.20_2: 26 files, 1.2MB, built in 2 minutes 13 seconds

完了:smile:

Why not register and get more from Qiita?
  1. We will deliver articles that match you
    By following users and tags, you can catch up information on technical fields that you are interested in as a whole
  2. you can read useful information later efficiently
    By "stocking" the articles you like, you can search right away
Comments
Sign up for free and join this conversation.
If you already have a Qiita account
Why do not you register as a user and use Qiita more conveniently?
You need to log in to use this function. Qiita can be used more conveniently after logging in.
You seem to be reading articles frequently this month. Qiita can be used more conveniently after logging in.
  1. We will deliver articles that match you
    By following users and tags, you can catch up information on technical fields that you are interested in as a whole
  2. you can read useful information later efficiently
    By "stocking" the articles you like, you can search right away