mozilla-services / heka

DEPRECATED: Data collection and processing made easy.
http://hekad.readthedocs.org/
Other
3.39k stars 529 forks source link

Heka fails to build OS X #1598

Open haf opened 9 years ago

haf commented 9 years ago
$  source build.sh
-- GeoIP.h found. Enabling GeoIP plugin.
-- Docker plugins enabled.
-- sphinx-build was not found, the documentation will not be generated.
CMake Warning (dev) at cmake/ExternalProject.cmake:202 (if):
  Policy CMP0054 is not set: Only interpret if() arguments as variables or
  keywords when unquoted.  Run "cmake --help-policy CMP0054" for policy
  details.  Use the cmake_policy command to set the policy and suppress this
  warning.

  Quoted keywords like "COMMAND" will no longer be interpreted as keywords
  when the policy is set to NEW.  Since the policy is not set the OLD
  behavior will be used.
Call Stack (most recent call first):
  cmake/ExternalProject.cmake:1524 (_ep_parse_arguments)
  cmake/externals.cmake:19 (externalproject_add)
  CMakeLists.txt:100 (include)
This warning is for project developers.  Use -Wno-dev to suppress it.

-- Configuring done
-- Generating done
-- Build files have been written to: /Users/henrik.feldt/dev/gocode/src/github.com/mozilla-services/heka/build
[  4%] Built target raven-go
[  8%] Built target heka-mozsvc-plugins
[ 12%] Built target xmlpath
[ 16%] Built target go-simplejson
[ 20%] Built target whisper-go
[ 23%] Built target gogoprotobuf
[ 26%] Built target g2s
[ 29%] Built target amqp
[ 32%] Built target raw
[ 36%] Built target slices
[ 40%] Built target sets
[ 43%] Built target snappy-go
[ 47%] Built target sarama
[ 51%] Built target goamz
[ 55%] Built target gomock
[ 58%] Built target go-notify
[ 62%] Built target go-uuid
[ 66%] Built target gospec
[ 70%] Built target toml
[ 74%] Built target geoip
[ 78%] Built target go-ircevent
[ 82%] Built target go-dockerclient
[ 82%] Built target GoPackages
[ 86%] Built target lua_sandbox
[ 86%] Built target heka_source
[ 86%] Built target message_matcher_parser
[100%] Built target mocks
# github.com/mozilla-services/heka/cmd/hekad
ld: warning: directory not found for option '-L/opt/local/lib'
Undefined symbols for architecture x86_64:
  "_lua_pcall", referenced from:
      _process_message in 000004.o
      _timer_event in 000004.o
  "_lua_tointeger", referenced from:
      _process_message in 000004.o
  "_lua_tonumber", referenced from:
      _write_message in 000004.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
/usr/local/Cellar/go/1.4.2/libexec/pkg/tool/darwin_amd64/6l: running clang failed: unsuccessful exit status 0x100
make[2]: *** [CMakeFiles/hekad] Error 2
make[1]: *** [CMakeFiles/hekad.dir/all] Error 2
make: *** [all] Error 2
hblanks commented 9 years ago

@haf By any chance do you have an existing installation of lua or luajit on your machine? Also, what version of OS X, clang, and heka are you operating on?

haf commented 9 years ago

Yup:

brew info lua
lua: stable 5.2.3 (bottled)
Powerful, lightweight programming language
http://www.lua.org/
/usr/local/Cellar/lua/5.1.5 (15 files, 276K)
  Poured from bottle
/usr/local/Cellar/lua/5.2.3_1 (13 files, 308K)
  Poured from bottle
/usr/local/Cellar/lua/5.2.3_2 (77 files, 1.0M) *
  Poured from bottle
From: https://github.com/Homebrew/homebrew/blob/master/Library/Formula/lua.rb
==> Options
--universal
    Build a universal binary
--with-completion
    Enables advanced readline support
--without-luarocks
    Don't build with Luarocks support embedded
--without-sigaction
    Revert to ANSI signal instead of improved POSIX sigaction
==> Caveats
Please be aware due to the way Luarocks is designed any binaries installed
via Luarocks-5.2 AND 5.1 will overwrite each other in /usr/local/bin.

This is, for now, unavoidable. If this is troublesome for you, you can build
rocks with the `--tree=` command to a special, non-conflicting location and
then add that to your `$PATH`.

If you have existing Rocks trees in $HOME, you will need to migrate them to the new
location manually. You will only have to do this once.

Latest OS X 10.4.4, clang:

clang --version
Apple LLVM version 6.1.0 (clang-602.0.53) (based on LLVM 3.6.0svn)
Target: x86_64-apple-darwin14.4.0
Thread model: posix

heka: master. Could build a few commits ago.