[Mac] 解決 Homebrew 無法更新 yara 的問題

[Mac] 解決 Homebrew 無法更新 yara 的問題

今天想說升級一下 Homebrew 安裝的套件,

下了 brew update 的指令,卻發現在升級 yara 時發生錯誤了:

testuser@localhost ~ $ brew upgrade
==> Upgrading 1 outdated packages, with result:
==> Upgrading yara
==> Downloading https://github.com/plusvic/yara/archive/v3.0.0.tar.gz
Already downloaded: /Library/Caches/Homebrew/yara-3.0.0.tar.gz
==> ./bootstrap.sh
==> ./configure --prefix=/usr/local/Cellar/yara/3.0.0
checking for suffix of executables...
checking whether we are cross compiling... configure: error: in `/private/tmp/yara-3NgA5t/yara-3.0.0':
configure: error: cannot run C compiled programs.
If you meant to cross compile, use `--host'.
See `config.log' for more details
READ THIS: https://github.com/Homebrew/homebrew/wiki/troubleshooting

 

嗯… 試試直接 brew install yara 安裝 yara 看看結果如何,也是失敗~

錯誤訊息差不多~

testuser@localhost ~ $ brew install yara
==> Downloading https://github.com/plusvic/yara/archive/v3.0.0.tar.gz
Already downloaded: /Library/Caches/Homebrew/yara-3.0.0.tar.gz
==> ./bootstrap.sh
==> ./configure --prefix=/usr/local/Cellar/yara/3.0.0
checking for suffix of executables...
checking whether we are cross compiling... configure: error: in `/private/tmp/yara-jgcbD8/yara-3.0.0':
configure: error: cannot run C compiled programs.
If you meant to cross compile, use `--host'.
See `config.log' for more details

 

加上 -v 參數,讓 Homebrew 印出多一點 debug 訊息看看:

testuser@localhost ~ $ brew install -v yara
==> Downloading https://github.com/plusvic/yara/archive/v3.0.0.tar.gz
Already downloaded: /Library/Caches/Homebrew/yara-3.0.0.tar.gz
==> Verifying yara-3.0.0.tar.gz checksum
tar xf /Library/Caches/Homebrew/yara-3.0.0.tar.gz
==> ./bootstrap.sh
== bootstraping yara
mkdir m4...
libtoolize...
glibtoolize: putting auxiliary files in `.'.
glibtoolize: linking file `./ltmain.sh'
glibtoolize: putting macros in AC_CONFIG_MACRO_DIR, `m4'.
glibtoolize: linking file `m4/libtool.m4'
glibtoolize: linking file `m4/ltoptions.m4'
glibtoolize: linking file `m4/ltsugar.m4'
glibtoolize: linking file `m4/ltversion.m4'
glibtoolize: linking file `m4/lt~obsolete.m4'
aclocal...
autoheader...
automake...
configure.ac:13: installing './ar-lib'
configure.ac:13: installing './compile'
configure.ac:19: installing './config.guess'
configure.ac:19: installing './config.sub'
configure.ac:5: installing './install-sh'
configure.ac:5: installing './missing'
Makefile.am: installing './depcomp'
configure.ac: installing './ylwrap'
autoconf...
==> ./configure --disable-debug --disable-dependency-tracking --prefix=/usr/local/Cellar/yara/3.0.0
configure: WARNING: unrecognized options: --disable-debug
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... ./install-sh -c -d
checking for gawk... no
checking for mawk... no
checking for nawk... no
checking for awk... awk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
./configure: line 2746: -std=gnu89: command not found
checking for style of include used by make... GNU
checking for gcc... clang
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... configure: error: in `/private/tmp/yara-DJof8p/yara-3.0.0':
configure: error: cannot run C compiled programs.
If you meant to cross compile, use `--host'.
See `config.log' for more details
==> Configuration
HOMEBREW_VERSION: 0.9.5
HEAD: e494a8407f128908a61fd0ebd7c1dc240dd29515
CPU: quad-core 64-bit ivybridge
OS X: 10.9.5-x86_64
Xcode: 6.0.1
X11: 2.7.5 => /opt/X11
==> ENV
HOMEBREW_CC: clang
HOMEBREW_CXX: clang++
CFLAGS: -std=gnu89
LDFLAGS: -L/usr/local/opt/pcre/lib -lpcre
MAKEFLAGS: -j4
CMAKE_PREFIX_PATH: /usr/local
CMAKE_INCLUDE_PATH: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/usr/include/libxml2:/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/usr/include/apache2:/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/System/Library/Frameworks/OpenGL.framework/Versions/Current/Headers
CMAKE_LIBRARY_PATH: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/System/Library/Frameworks/OpenGL.framework/Versions/Current/Libraries
CMAKE_FRAMEWORK_PATH: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk/System/Library/Frameworks
PKG_CONFIG_PATH: /usr/local/opt/pcre/lib/pkgconfig
PKG_CONFIG_LIBDIR: /usr/lib/pkgconfig:/usr/local/Library/ENV/pkgconfig/10.9
HOMEBREW_SDKROOT: /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.9.sdk
ACLOCAL_PATH: /usr/local/share/aclocal
PATH: /usr/local/Library/ENV/4.3:/usr/local/opt/pcre/bin:/usr/local/opt/libtool/bin:/usr/local/opt/autoconf/bin:/usr/local/opt/automake/bin:/usr/bin:/bin:/usr/sbin:/sbin
Error: yara 3.0.0 did not build
Logs:
/Users/testuser/Library/Logs/Homebrew/yara/01.bootstrap.sh
/Users/testuser/Library/Logs/Homebrew/yara/02.configure
/Users/testuser/Library/Logs/Homebrew/yara/02.configure.cc
/Users/testuser/Library/Logs/Homebrew/yara/config.log

 

似乎還是不太清楚問題點,不過 -v 時會寫出 log 檔所在的位置,

打開 ~/Library/Logs/Homebrew/yara/config.log 看看編譯時出了什麼問題:

testuser@localhost ~ $ vi ~/Library/Logs/Homebrew/yara/config.log

 

這邊忘了把 config.log 的內容留下來了,

當初看的時候,是看到 link pcre library 的附近出現錯誤…

試著用 brew install pcre 會說已經裝好了,

用 brew uninstall 後再 install 一次:

testuser@localhost ~ $ brew install pcre
Warning: pcre-8.35 already installed
testuser@localhost ~ $ brew uninstall pcre
Uninstalling /usr/local/Cellar/pcre/8.35...
testuser@localhost ~ $ brew install pcre
==> Downloading https://downloads.sf.net/project/machomebrew/Bottles/pcre-8.35.mavericks.bottle.tar.gz
######################################################################## 100.0%
==> Pouring pcre-8.35.mavericks.bottle.tar.gz
????  /usr/local/Cellar/pcre/8.35: 146 files, 5.8M

 

接著再裝一次 yara~Bingo,這次成功裝好了~

testuser@localhost ~ $ brew install -v yara
==> Downloading https://github.com/plusvic/yara/archive/v3.0.0.tar.gz
Already downloaded: /Library/Caches/Homebrew/yara-3.0.0.tar.gz
==> Verifying yara-3.0.0.tar.gz checksum
tar xf /Library/Caches/Homebrew/yara-3.0.0.tar.gz
==> ./bootstrap.sh
== bootstraping yara
mkdir m4...
libtoolize...
glibtoolize: putting auxiliary files in `.'.
glibtoolize: linking file `./ltmain.sh'
glibtoolize: putting macros in AC_CONFIG_MACRO_DIR, `m4'.
glibtoolize: linking file `m4/libtool.m4'
glibtoolize: linking file `m4/ltoptions.m4'
glibtoolize: linking file `m4/ltsugar.m4'
glibtoolize: linking file `m4/ltversion.m4'
glibtoolize: linking file `m4/lt~obsolete.m4'
aclocal...
autoheader...
automake...
configure.ac:13: installing './ar-lib'
configure.ac:13: installing './compile'
configure.ac:19: installing './config.guess'
configure.ac:19: installing './config.sub'
configure.ac:5: installing './install-sh'
configure.ac:5: installing './missing'
Makefile.am: installing './depcomp'
configure.ac: installing './ylwrap'
autoconf...
==> ./configure --disable-debug --disable-dependency-tracking --prefix=/usr/local/Cellar/yara/3.0.0
configure: WARNING: unrecognized options: --disable-debug
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... ./install-sh -c -d
checking for gawk... no
checking for mawk... no
checking for nawk... no
checking for awk... awk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
./configure: line 2746: -std=gnu89: command not found
checking for style of include used by make... GNU
checking for gcc... clang
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether clang accepts -g... yes
checking for clang option to accept ISO C89... none needed
checking whether clang understands -c and -o together... yes
checking dependency style of clang... none
checking for ar... ar
checking the archiver (ar) interface... ar
checking for gcc... (cached) clang
checking whether we are using the GNU C compiler... (cached) yes
checking whether clang accepts -g... (cached) yes
checking for clang option to accept ISO C89... (cached) none needed
checking whether clang understands -c and -o together... (cached) yes
checking dependency style of clang... (cached) none
checking for flex... flex
checking lex output file root... lex.yy
checking lex library... -ll
checking whether yytext is a pointer... yes
checking for bison... bison -y
checking build system type... x86_64-apple-darwin13.4.0
checking host system type... x86_64-apple-darwin13.4.0
checking how to print strings... printf
checking for a sed that does not truncate output... /usr/local/Library/ENV/4.3/sed
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for fgrep... /usr/bin/grep -F
checking for ld used by clang... /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld
checking if the linker (/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld) is GNU ld... no
checking for BSD- or MS-compatible name lister (nm)... /usr/bin/nm
checking the name lister (/usr/bin/nm) interface... BSD nm
checking whether ln -s works... yes
checking the maximum length of command line arguments... 196608
checking whether the shell understands some XSI constructs... yes
checking whether the shell understands "+="... yes
checking how to convert x86_64-apple-darwin13.4.0 file names to x86_64-apple-darwin13.4.0 format... func_convert_file_noop
checking how to convert x86_64-apple-darwin13.4.0 file names to toolchain format... func_convert_file_noop
checking for /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld option to reload object files... -r
checking for objdump... no
checking how to recognize dependent libraries... pass_all
checking for dlltool... no
checking how to associate runtime and link libraries... printf %s\n
checking for archiver @FILE support... no
checking for strip... strip
checking for ranlib... ranlib
checking command to parse /usr/bin/nm output from clang object... ok
checking for sysroot... no
checking for mt... no
checking if : is a manifest tool... no
checking for dsymutil... dsymutil
checking for nmedit... nmedit
checking for lipo... lipo
checking for otool... otool
checking for otool64... no
checking for -single_module linker flag... yes
checking for -exported_symbols_list linker flag... yes
checking for -force_load linker flag... yes
checking how to run the C preprocessor... clang -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for dlfcn.h... yes
checking for objdir... .libs
checking if clang supports -fno-rtti -fno-exceptions... yes
checking for clang option to produce PIC... -fno-common -DPIC
checking if clang PIC flag -fno-common -DPIC works... yes
checking if clang static flag -static works... no
checking if clang supports -c -o file.o... yes
checking if clang supports -c -o file.o... (cached) yes
checking whether the clang linker (/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/ld) supports shared libraries... yes
checking dynamic linker characteristics... darwin13.4.0 dyld
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... yes
checking for pthread_create in -lpthread... yes
checking that generated files are newer than configure... done
configure: creating ./config.status
config.status: creating Makefile
config.status: creating libyara/Makefile
config.status: creating config.h
config.status: executing depfiles commands
config.status: executing libtool commands
configure: WARNING: unrecognized options: --disable-debug
==> make install
Making install in libyara
/bin/sh ../libtool  --tag=CC   --mode=compile clang -DHAVE_CONFIG_H -I. -I..    -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c -o grammar.lo grammar.c
/bin/sh ../libtool  --tag=CC   --mode=compile clang -DHAVE_CONFIG_H -I. -I..    -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c -o ahocorasick.lo ahocorasick.c
/bin/sh ../libtool  --tag=CC   --mode=compile clang -DHAVE_CONFIG_H -I. -I..    -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c -o arena.lo arena.c
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c grammar.c  -fno-common -DPIC -o .libs/grammar.o
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c ahocorasick.c  -fno-common -DPIC -o .libs/ahocorasick.o
/bin/sh ../libtool  --tag=CC   --mode=compile clang -DHAVE_CONFIG_H -I. -I..    -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c -o atoms.lo atoms.c
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c arena.c  -fno-common -DPIC -o .libs/arena.o
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c atoms.c  -fno-common -DPIC -o .libs/atoms.o
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c arena.c -o arena.o >/dev/null 2>&1
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c ahocorasick.c -o ahocorasick.o >/dev/null 2>&1
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c atoms.c -o atoms.o >/dev/null 2>&1
/bin/sh ../libtool  --tag=CC   --mode=compile clang -DHAVE_CONFIG_H -I. -I..    -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c -o compiler.lo compiler.c
/bin/sh ../libtool  --tag=CC   --mode=compile clang -DHAVE_CONFIG_H -I. -I..    -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c -o exec.lo exec.c
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c compiler.c  -fno-common -DPIC -o .libs/compiler.o
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c exec.c  -fno-common -DPIC -o .libs/exec.o
/bin/sh ../libtool  --tag=CC   --mode=compile clang -DHAVE_CONFIG_H -I. -I..    -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c -o exefiles.lo exefiles.c
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c grammar.c -o grammar.o >/dev/null 2>&1
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c exefiles.c  -fno-common -DPIC -o .libs/exefiles.o
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c compiler.c -o compiler.o >/dev/null 2>&1
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c exefiles.c -o exefiles.o >/dev/null 2>&1
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c exec.c -o exec.o >/dev/null 2>&1
/bin/sh ../libtool  --tag=CC   --mode=compile clang -DHAVE_CONFIG_H -I. -I..    -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c -o filemap.lo filemap.c
/bin/sh ../libtool  --tag=CC   --mode=compile clang -DHAVE_CONFIG_H -I. -I..    -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c -o hash.lo hash.c
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c hash.c  -fno-common -DPIC -o .libs/hash.o
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c filemap.c  -fno-common -DPIC -o .libs/filemap.o
/bin/sh ../libtool  --tag=CC   --mode=compile clang -DHAVE_CONFIG_H -I. -I..    -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c -o hex_grammar.lo hex_grammar.c
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c hex_grammar.c  -fno-common -DPIC -o .libs/hex_grammar.o
/bin/sh ../libtool  --tag=CC   --mode=compile clang -DHAVE_CONFIG_H -I. -I..    -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c -o hex_lexer.lo hex_lexer.c
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c filemap.c -o filemap.o >/dev/null 2>&1
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c hex_lexer.c  -fno-common -DPIC -o .libs/hex_lexer.o
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c hash.c -o hash.o >/dev/null 2>&1
/bin/sh ../libtool  --tag=CC   --mode=compile clang -DHAVE_CONFIG_H -I. -I..    -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c -o lexer.lo lexer.c
/bin/sh ../libtool  --tag=CC   --mode=compile clang -DHAVE_CONFIG_H -I. -I..    -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c -o libyara.lo libyara.c
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c lexer.c  -fno-common -DPIC -o .libs/lexer.o
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c libyara.c  -fno-common -DPIC -o .libs/libyara.o
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c hex_grammar.c -o hex_grammar.o >/dev/null 2>&1
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c libyara.c -o libyara.o >/dev/null 2>&1
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c hex_lexer.c -o hex_lexer.o >/dev/null 2>&1
/bin/sh ../libtool  --tag=CC   --mode=compile clang -DHAVE_CONFIG_H -I. -I..    -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c -o mem.lo mem.c
/bin/sh ../libtool  --tag=CC   --mode=compile clang -DHAVE_CONFIG_H -I. -I..    -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c -o modules.lo modules.c
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c mem.c  -fno-common -DPIC -o .libs/mem.o
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c modules.c  -fno-common -DPIC -o .libs/modules.o
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c lexer.c -o lexer.o >/dev/null 2>&1
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c mem.c -o mem.o >/dev/null 2>&1
/bin/sh ../libtool  --tag=CC   --mode=compile clang -DHAVE_CONFIG_H -I. -I..    -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c -o object.lo object.c
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c object.c  -fno-common -DPIC -o .libs/object.o
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c modules.c -o modules.o >/dev/null 2>&1
/bin/sh ../libtool  --tag=CC   --mode=compile clang -DHAVE_CONFIG_H -I. -I..    -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c -o parser.lo parser.c
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c parser.c  -fno-common -DPIC -o .libs/parser.o
/bin/sh ../libtool  --tag=CC   --mode=compile clang -DHAVE_CONFIG_H -I. -I..    -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c -o proc.lo proc.c
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c proc.c  -fno-common -DPIC -o .libs/proc.o
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c object.c -o object.o >/dev/null 2>&1
/bin/sh ../libtool  --tag=CC   --mode=compile clang -DHAVE_CONFIG_H -I. -I..    -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c -o re.lo re.c
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c re.c  -fno-common -DPIC -o .libs/re.o
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c parser.c -o parser.o >/dev/null 2>&1
/bin/sh ../libtool  --tag=CC   --mode=compile clang -DHAVE_CONFIG_H -I. -I..    -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c -o re_grammar.lo re_grammar.c
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c re_grammar.c  -fno-common -DPIC -o .libs/re_grammar.o
/bin/sh ../libtool  --tag=CC   --mode=compile clang -DHAVE_CONFIG_H -I. -I..    -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c -o re_lexer.lo re_lexer.c
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c re.c -o re.o >/dev/null 2>&1
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c re_lexer.c  -fno-common -DPIC -o .libs/re_lexer.o
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c re_grammar.c -o re_grammar.o >/dev/null 2>&1
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c proc.c -o proc.o >/dev/null 2>&1
/bin/sh ../libtool  --tag=CC   --mode=compile clang -DHAVE_CONFIG_H -I. -I..    -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c -o rules.lo rules.c
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c re_lexer.c -o re_lexer.o >/dev/null 2>&1
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c rules.c  -fno-common -DPIC -o .libs/rules.o
/bin/sh ../libtool  --tag=CC   --mode=compile clang -DHAVE_CONFIG_H -I. -I..    -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c -o scan.lo scan.c
/bin/sh ../libtool  --tag=CC   --mode=compile clang -DHAVE_CONFIG_H -I. -I..    -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c -o utils.lo utils.c
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c scan.c  -fno-common -DPIC -o .libs/scan.o
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c utils.c  -fno-common -DPIC -o .libs/utils.o
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c rules.c -o rules.o >/dev/null 2>&1
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c utils.c -o utils.o >/dev/null 2>&1
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c scan.c -o scan.o >/dev/null 2>&1
/bin/sh ../libtool  --tag=CC   --mode=compile clang -DHAVE_CONFIG_H -I. -I..    -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c -o modules/tests.lo modules/tests.c
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c modules/tests.c  -fno-common -DPIC -o modules/.libs/tests.o
/bin/sh ../libtool  --tag=CC   --mode=compile clang -DHAVE_CONFIG_H -I. -I..    -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c -o modules/pe.lo modules/pe.c
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c modules/pe.c  -fno-common -DPIC -o modules/.libs/pe.o
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c modules/tests.c -o modules/tests.o >/dev/null 2>&1
libtool: compile:  clang -DHAVE_CONFIG_H -I. -I.. -O3 -Wall -std=gnu99 -I./include -std=gnu89 -c modules/pe.c -o modules/pe.o >/dev/null 2>&1
/bin/sh ../libtool  --tag=CC   --mode=link clang -O3 -Wall -std=gnu99 -I./include -std=gnu89 -export-symbols libyara.sym -version-number 3:0 -L/usr/local/opt/pcre/lib -lpcre -o libyara.la -rpath /usr/local/Cellar/yara/3.0.0/lib modules/tests.lo modules/pe.lo  grammar.lo ahocorasick.lo arena.lo atoms.lo compiler.lo exec.lo exefiles.lo filemap.lo hash.lo hex_grammar.lo hex_lexer.lo lexer.lo libyara.lo mem.lo modules.lo object.lo parser.lo proc.lo re.lo re_grammar.lo re_lexer.lo rules.lo scan.lo utils.lo  -lpthread
libtool: link: sed 's,^,_,' < libyara.sym > .libs/libyara-symbols.expsym
libtool: link: clang -dynamiclib -Wl,-undefined -Wl,dynamic_lookup -o .libs/libyara.3.dylib  modules/.libs/tests.o modules/.libs/pe.o .libs/grammar.o .libs/ahocorasick.o .libs/arena.o .libs/atoms.o .libs/compiler.o .libs/exec.o .libs/exefiles.o .libs/filemap.o .libs/hash.o .libs/hex_grammar.o .libs/hex_lexer.o .libs/lexer.o .libs/libyara.o .libs/mem.o .libs/modules.o .libs/object.o .libs/parser.o .libs/proc.o .libs/re.o .libs/re_grammar.o .libs/re_lexer.o .libs/rules.o .libs/scan.o .libs/utils.o   -L/usr/local/opt/pcre/lib -lpcre -lpthread  -O3   -install_name  /usr/local/Cellar/yara/3.0.0/lib/libyara.3.dylib -compatibility_version 4 -current_version 4.0 -Wl,-single_module -Wl,-exported_symbols_list,.libs/libyara-symbols.expsym
libtool: link: (cd ".libs" && rm -f "libyara.dylib" && ln -s "libyara.3.dylib" "libyara.dylib")
libtool: link: ar cru .libs/libyara.a  modules/tests.o modules/pe.o grammar.o ahocorasick.o arena.o atoms.o compiler.o exec.o exefiles.o filemap.o hash.o hex_grammar.o hex_lexer.o lexer.o libyara.o mem.o modules.o object.o parser.o proc.o re.o re_grammar.o re_lexer.o rules.o scan.o utils.o
libtool: link: ranlib .libs/libyara.a
libtool: link: ( cd ".libs" && rm -f "libyara.la" && ln -s "../libyara.la" "libyara.la" )
.././install-sh -c -d '/usr/local/Cellar/yara/3.0.0/lib'
.././install-sh -c -d '/usr/local/Cellar/yara/3.0.0/include'
.././install-sh -c -d '/usr/local/Cellar/yara/3.0.0/include/yara'
/bin/sh ../libtool   --mode=install /usr/bin/install -c   libyara.la '/usr/local/Cellar/yara/3.0.0/lib'
mkdir: /usr/local/Cellar/yara/3.0.0/include: File exists
/usr/bin/install -c -m 644 include/yara.h '/usr/local/Cellar/yara/3.0.0/include'
/usr/bin/install -c -m 644 include/yara/error.h include/yara/utils.h include/yara/filemap.h include/yara/compiler.h include/yara/modules.h include/yara/object.h include/yara/libyara.h '/usr/local/Cellar/yara/3.0.0/include/yara'
libtool: install: /usr/bin/install -c .libs/libyara.3.dylib /usr/local/Cellar/yara/3.0.0/lib/libyara.3.dylib
libtool: install: (cd /usr/local/Cellar/yara/3.0.0/lib && { ln -s -f libyara.3.dylib libyara.dylib || { rm -f libyara.dylib && ln -s libyara.3.dylib libyara.dylib; }; })
libtool: install: /usr/bin/install -c .libs/libyara.lai /usr/local/Cellar/yara/3.0.0/lib/libyara.la
libtool: install: /usr/bin/install -c .libs/libyara.a /usr/local/Cellar/yara/3.0.0/lib/libyara.a
libtool: install: chmod 644 /usr/local/Cellar/yara/3.0.0/lib/libyara.a
libtool: install: ranlib /usr/local/Cellar/yara/3.0.0/lib/libyara.a
clang -DHAVE_CONFIG_H -I.    -O3 -Wall -I./libyara/include -std=gnu89 -c -o threading.o threading.c
clang -DHAVE_CONFIG_H -I.    -O3 -Wall -I./libyara/include -std=gnu89 -c -o yara.o yara.c
clang -DHAVE_CONFIG_H -I.    -O3 -Wall -I./libyara/include -std=gnu89 -c -o yarac.o yarac.c
/bin/sh ./libtool  --tag=CC   --mode=link clang -O3 -Wall -I./libyara/include -std=gnu89  -L/usr/local/opt/pcre/lib -lpcre -o yarac yarac.o libyara/.libs/libyara.a -lpthread
/bin/sh ./libtool  --tag=CC   --mode=link clang -O3 -Wall -I./libyara/include -std=gnu89  -L/usr/local/opt/pcre/lib -lpcre -o yara threading.o yara.o libyara/.libs/libyara.a -lpthread
libtool: link: clang -O3 -Wall -I./libyara/include -std=gnu89 -o yarac yarac.o  -L/usr/local/opt/pcre/lib -lpcre libyara/.libs/libyara.a -lpthread
libtool: link: clang -O3 -Wall -I./libyara/include -std=gnu89 -o yara threading.o yara.o  -L/usr/local/opt/pcre/lib -lpcre libyara/.libs/libyara.a -lpthread
./install-sh -c -d '/usr/local/Cellar/yara/3.0.0/bin'
./install-sh -c -d '/usr/local/Cellar/yara/3.0.0/share/man/man1'
/bin/sh ./libtool   --mode=install /usr/bin/install -c yara yarac '/usr/local/Cellar/yara/3.0.0/bin'
/usr/bin/install -c -m 644 'yara.man' '/usr/local/Cellar/yara/3.0.0/share/man/man1/yara.1'
/usr/bin/install -c -m 644 'yarac.man' '/usr/local/Cellar/yara/3.0.0/share/man/man1/yarac.1'
libtool: install: /usr/bin/install -c yara /usr/local/Cellar/yara/3.0.0/bin/yara
libtool: install: /usr/bin/install -c yarac /usr/local/Cellar/yara/3.0.0/bin/yarac
==> Cleaning
rm /usr/local/Cellar/yara/3.0.0/lib/libyara.la
==> Finishing up
ln -s ../Cellar/yara/3.0.0/bin/yara yara
ln -s ../Cellar/yara/3.0.0/bin/yarac yarac
ln -s ../Cellar/yara/3.0.0/include/yara yara
ln -s ../Cellar/yara/3.0.0/include/yara.h yara.h
ln -s ../../../Cellar/yara/3.0.0/share/man/man1/yara.1 yara.1
ln -s ../../../Cellar/yara/3.0.0/share/man/man1/yarac.1 yarac.1
ln -s ../Cellar/yara/3.0.0/lib/libyara.3.dylib libyara.3.dylib
ln -s ../Cellar/yara/3.0.0/lib/libyara.a libyara.a
ln -s ../Cellar/yara/3.0.0/lib/libyara.dylib libyara.dylib
==> Summary
????  /usr/local/Cellar/yara/3.0.0: 18 files, 796K, built in 22 seconds

 

其實這次的問題應該是因為更新的 Mac OS Mavericks 之後,

部分 Homebrew 安裝的套件必須重新編譯安裝才行 (像 pcre)…

目前看來,就是從 log 裡面找出錯誤的套件,移除後重裝,應該問題就能解決囉~

 

//
//

(本頁面已被瀏覽過 279 次)

發佈留言

發佈留言必須填寫的電子郵件地址不會公開。 必填欄位標示為 *

這個網站採用 Akismet 服務減少垃圾留言。進一步了解 Akismet 如何處理網站訪客的留言資料