やりたいこと
別のツールを動かすのに必要なので、sparsehashを、GitHub https://github.com/sparsehash/sparsehash/releases/tag/sparsehash-2.0.4 (クリックがうまくゆかなかったらコピペしてください) から、画面下のsource code (zip) をダウンロード、MacOS10.15.7へインストールしようとしています。
Install
1Briefly, the shell commands `./configure; make; make install' should 2configure, build, and install this package. The following 3more-detailed instructions are generic; see the `README' file for 4instructions specific to this package. Some packages provide this 5`INSTALL' file but do not implement all of the features documented 6below. The lack of an optional feature in a given package is not 7necessarily a bug. More recommendations for GNU packages can be found 8in *note Makefile Conventions: (standards)Makefile Conventions.
Read_me
1COMPILING --------- To compile test applications with these classes, run ./configure followed by make. To install these header files on your system, run 'make install'. (On Windows, the instructions are different; see README_windows.txt.) See INSTALL for more details. This code should work on any modern C++ system. It has been tested on Linux (Ubuntu, Fedora, RedHat, Debian), Solaris 10 x86, FreeBSD 6.0, OS X 10.3 and 10.4, and Windows under both VC++7 and VC++8.
に従って、
bash
1$ ./configure; make; make install
でインストールしようとしているのですが、なかなかうまくゆきません。
困っていること
$ configureは、bash $ ./configure CXX="gcc"
でうまく行ったのですが、
$ makeが、bash $ CXX="gcc" make
などを試していますが、下記のエラーになってしまいます。
error
1(前半部分略) 2std::__1::char_traits<char> >(std::__1::basic_ostream<char, std::__1::char_traits<char> >&, char const*, unsigned long) in template_util_unittest.o 3 "___gxx_personality_v0", referenced from: 4 std::__1::basic_ostream<char, std::__1::char_traits<char> >& std::__1::__put_character_sequence<char, std::__1::char_traits<char> >(std::__1::basic_ostream<char, std::__1::char_traits<char> >&, char const*, unsigned long) in template_util_unittest.o 5 std::__1::ostreambuf_iterator<char, std::__1::char_traits<char> > std::__1::__pad_and_output<char, std::__1::char_traits<char> >(std::__1::ostreambuf_iterator<char, std::__1::char_traits<char> >, char const*, char const*, char const*, std::__1::ios_base&, char) in template_util_unittest.o 6 Dwarf Exception Unwind Info (__eh_frame) in template_util_unittest.o 7ld: symbol(s) not found for architecture x86_64 8clang: error: linker command failed with exit code 1 (use -v to see invocation) 9make[1]: *** [template_util_unittest] Error 1 10make: *** [all] Error 2
教えてほしいこと
・C++ でインストールできるはずなのに、コマンドで指定できず、clangが走って失敗しているのだと思うのですが、どのようにすれば、MacOS10.15のmake で、C++を指定できるのでしょうか。
・別のパッケージのインストールでは、bash $ CXX=g++ ./configure
の方がうまく動いたことがあり、使い分けがわかれば教えていただきたく思います。
よろしくお願いいたします。
あなたの回答
tips
プレビュー