I tried installing with HHVM MacPort on Mac OSX with the method on https://github.com/facebook/hhvm/wiki/Building-and-installing-HHVM-on-OSX-10.10 (method: Macports: install by Hand).
sudo port -v install autoconf automake binutils bison boost clang-3.6 cmake elftoolchain gawk google-glog jemalloc libelf libjpeg-turbo libmcrypt libmemcached libpng md5sha1sum ocaml oniguruma5 readline tbb
gives the following result :
---> Computing dependencies for autoconf.
---> Cleaning autoconf
---> Removing work directory for autoconf
---> Cleaning automake
---> Removing work directory for automake
---> Computing dependencies for binutils.
---> Cleaning binutils
---> Removing work directory for binutils
---> Computing dependencies for bison.
---> Cleaning bison
---> Removing work directory for bison
---> Computing dependencies for boost.
---> Cleaning boost
---> Removing work directory for boost
---> Computing dependencies for clang-3.6.
---> Cleaning clang-3.6
---> Removing work directory for clang-3.6
---> Computing dependencies for cmake.
---> Cleaning cmake
---> Removing work directory for cmake
---> Computing dependencies for elftoolchain.
---> Cleaning elftoolchain
---> Removing work directory for elftoolchain
---> Computing dependencies for gawk.
---> Cleaning gawk
---> Removing work directory for gawk
---> Computing dependencies for google-glog.
---> Cleaning google-glog
---> Removing work directory for google-glog
---> Activating jemalloc @3.6.0_1
x ./
x ./+COMMENT
x ./+CONTENTS
x ./+DESC
x ./+PORTFILE
x ./+STATE
x ./opt/
x ./opt/local/
x ./opt/local/bin/
x ./opt/local/include/
x ./opt/local/lib/
x ./opt/local/share/
x ./opt/local/share/doc/
x ./opt/local/share/man/
x ./opt/local/share/man/man3/
x ./opt/local/share/man/man3/jemalloc.3.gz
x ./opt/local/share/doc/jemalloc/
x ./opt/local/share/doc/jemalloc/jemalloc.html
x ./opt/local/lib/libjemalloc.1.dylib
x ./opt/local/lib/libjemalloc.a
x ./opt/local/lib/libjemalloc.dylib
x ./opt/local/lib/libjemalloc_pic.a
x ./opt/local/include/jemalloc/
x ./opt/local/include/jemalloc/jemalloc.h
x ./opt/local/bin/jemalloc-prof
x ./opt/local/bin/jemalloc.sh
Error: org.macports.activate for port jemalloc returned: Image error: /opt/local/bin/jemalloc.sh already exists and does not belong to a registered port. Unable to activate port jemalloc. Use 'port -f activate jemalloc' to force the activation.
Please see the log file for port jemalloc for details:
/opt/local/var/macports/logs/_opt_local_var_macports_sources_rsync.macports.org_release_tarballs_ports_devel_jemalloc/jemalloc/main.log
To report a bug, follow the instructions in the guide:
http://guide.macports.org/#project.tickets
Error: Processing of port jemalloc failed
jemalloc :
sudo port -f activate jemalloc ---> The following versions of jemalloc are currently installed: ---> jemalloc @3.6.0_0 ---> jemalloc @3.6.0_1 Error: port activate failed: Registry error: Please specify the full version as recorded in the port registry.
activate jemloalloc
sudo port -f activate [email protected]_1 ---> Activating jemalloc @3.6.0_1 Warning: File /opt/local/bin/jemalloc.sh already exists. Moving to: /opt/local/bin/jemalloc.sh.mp_1444506130. Warning: File /opt/local/include/jemalloc/jemalloc.h already exists. Moving to: /opt/local/include/jemalloc/jemalloc.h.mp_1444506130. Warning: File /opt/local/lib/libjemalloc.1.dylib already exists. Moving to: /opt/local/lib/libjemalloc.1.dylib.mp_1444506130. Warning: File /opt/local/lib/libjemalloc.a already exists. Moving to: /opt/local/lib/libjemalloc.a.mp_1444506130. Warning: File /opt/local/lib/libjemalloc.dylib already exists. Moving to: /opt/local/lib/libjemalloc.dylib.mp_1444506130. Warning: File /opt/local/lib/libjemalloc_pic.a already exists. Moving to: /opt/local/lib/libjemalloc_pic.a.mp_1444506130. Warning: File /opt/local/share/doc/jemalloc/jemalloc.html already exists. Moving to: /opt/local/share/doc/jemalloc/jemalloc.html.mp_1444506130. Warning: File /opt/local/share/man/man3/jemalloc.3.gz already exists. Moving to: /opt/local/share/man/man3/jemalloc.3.gz.mp_1444506130. ---> Cleaning jemalloc
And after, I run this command :
git clone https://github.com/facebook/hhvm.git
cd hhvm
git submodule update --init --recursive
It's ok.
After
cmake
:cmake \ -DCMAKE_C_COMPILER=clang-mp-3.6 -DCMAKE_CXX_COMPILER=clang++-mp-3.6 -DCMAKE_ASM_COMPILER=clang-mp-3.6 \ -DCMAKE_C_FLAGS="-isystem/opt/local/include" -DCMAKE_CXX_FLAGS="-isystem/opt/local/include" \ -DENABLE_MCROUTER=0 -DENABLE_EXTENSION_MCROUTER=Off -DENABLE_EXTENSION_IMAGICK=Off \ -DMYSQL_UNIX_SOCK_ADDR=/dev/null \ -DLIBDWARF_LIBRARIES="/opt/local/lib/elftoolchain/libdwarf.3.dylib" \ -DLIBDWARF_INCLUDE_DIRS="/opt/local/include/elftoolchain/"
result :
-- The ASM compiler identification is unknown
-- Found assembler: /opt/local/bin/clang-mp-3.6
-- Warning: Did not find file Compiler/-ASM
-- Build type not specified: cmake build type Release.
-- Boost version: 1.59.0
-- Found the following Boost libraries:
-- system
-- program_options
-- filesystem
-- context
-- Could NOT find LIBINOTIFY (missing: LIBINOTIFY_LIBRARY LIBINOTIFY_INCLUDE_DIR)
-- System PCRE does not have JIT enabled - will use hhvm-third-party/pcre
-- Found libevent: /opt/local/lib/libevent.dylib
-- Found libsqlite3: /opt/local/lib/libsqlite3.dylib
-- Could NOT find DOUBLE_CONVERSION (missing: DOUBLE_CONVERSION_LIBRARY DOUBLE_CONVERSION_INCLUDE_DIR)
-- Using third-party bundled double-conversion
-- Found LZ4: /usr/local/lib/liblz4.dylib
-- Could NOT find FastLZ (missing: FASTLZ_LIBRARY FASTLZ_INCLUDE_DIR)
-- Using third-party bundled fastlz
-- Found libzip: /opt/local/lib/libzip.dylib 0.11.1
-- Found ICU header files in /opt/local/include
-- Found ICU libraries: /opt/local/lib/libicuuc.dylib
-- Found jemalloc: /opt/local/lib/libjemalloc.dylib
-- Found Intel TBB
-- Looking for dwarf_producer_init
-- Looking for dwarf_producer_init - found
-- Performing Test DW_CONST
-- Performing Test DW_CONST - Success
-- Looking for dwarf_producer_init_c
-- Looking for dwarf_producer_init_c - not found
-- libdwarf uses const char* type
-- libdwarf does not have dwarf_producer_init_c, using dwarf_producer_init
Generating Release build
-- Did not find system RE2
-- Building RE2 from third-party
-- Boost version: 1.59.0
-- Found the following Boost libraries:
-- system
-- program_options
-- filesystem
-- regex
-- context
-- Boost version: 1.59.0
-- Found the following Boost libraries:
-- system
-- thread
-- Boost version: 1.59.0
-- Found the following Boost libraries:
-- thread
-- system
CMake Warning (dev) at CMake/HPHPFunctions.cmake:21 (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 variables like "lib" will no longer be dereferenced 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):
third-party/thrift/CMakeLists.txt:5 (auto_sources)
This warning is for project developers. Use -Wno-dev to suppress it.
-- Boost version: 1.59.0
-- Found the following Boost libraries:
-- thread
-- system
-- Found libevent: /opt/local/lib/libevent.dylib
-- Found libevent 2.0.9+
-- Found Readline: /opt/local/include
CMake Warning (dev) at third-party/pcre/CMakeLists.txt:770 (GET_TARGET_PROPERTY):
Policy CMP0026 is not set: Disallow use of the LOCATION target property.
Run "cmake --help-policy CMP0026" for policy details. Use the cmake_policy
command to set the policy and suppress this warning.
The LOCATION property should not be read from target "pcregrep". Use the
target name directly with add_custom_command, or use the generator
expression $<TARGET_FILE>, as appropriate.
This warning is for project developers. Use -Wno-dev to suppress it.
CMake Warning (dev) at third-party/pcre/CMakeLists.txt:773 (GET_TARGET_PROPERTY):
Policy CMP0026 is not set: Disallow use of the LOCATION target property.
Run "cmake --help-policy CMP0026" for policy details. Use the cmake_policy
command to set the policy and suppress this warning.
The LOCATION property should not be read from target "pcretest". Use the
target name directly with add_custom_command, or use the generator
expression $<TARGET_FILE>, as appropriate.
This warning is for project developers. Use -Wno-dev to suppress it.
--
--
-- PCRE configuration summary:
--
-- C compiler ...................... : /opt/local/bin/clang-mp-3.6
-- C++ compiler .................... : /opt/local/bin/clang++-mp-3.6
-- C compiler flags ................ : -isystem/opt/local/include -msse4.2 -w -O3 -DNDEBUG
-- C++ compiler flags .............. : -isystem/opt/local/include -Wall -std=gnu++11 -stdlib=libc++ -fno-omit-frame-pointer -Woverloaded-virtual -Wno-deprecated -Wno-strict-aliasing -Wno-write-strings -Wno-invalid-offsetof -fno-operator-names -Wno-error=array-bounds -Wno-error=switch -Werror=format-security -Wno-unused-result -Wno-sign-compare -Wno-attributes -Wno-maybe-uninitialized -Wno-mismatched-tags -Wno-unknown-warning-option -Wno-return-type-c-linkage -Qunused-arguments -msse4.2 -O3 -DNDEBUG
--
-- Build 8 bit PCRE library ........ : ON
-- Build 16 bit PCRE library ....... : OFF
-- Build 32 bit PCRE library ....... : OFF
-- Build C++ library ............... : ON
-- Enable JIT compiling support .... : ON
-- Enable UTF support .............. : ON
-- Unicode properties .............. : ON
-- Newline char/sequence ........... : LF
-- \R matches only ANYCRLF ......... : OFF
-- EBCDIC coding ................... : OFF
-- EBCDIC coding with NL=0x25 ...... : OFF
-- Rebuild char tables ............. : OFF
-- No stack recursion .............. : OFF
-- POSIX mem threshold ............. : 10
-- Internal link size .............. : 2
-- Parentheses nest limit .......... : 250
-- Match limit ..................... : 10000000
-- Match limit recursion ........... : MATCH_LIMIT
-- Build shared libs ............... : OFF
-- Build static libs ............... : ON
-- Build pcregrep .................. : ON
-- Enable JIT in pcregrep .......... : ON
-- Buffer size for pcregrep ........ : 20480
-- Build tests (implies pcretest .. : ON
-- and pcregrep)
-- Link pcregrep with libz ......... : ON
-- Link pcregrep with libbz2 ....... : ON
-- Link pcretest with libeditline .. : OFF
-- Link pcretest with libreadline .. : ON
-- Support Valgrind .................: OFF
-- Support coverage .................:
--
-- Build type not specified: cmake build type Release.
-- Boost version: 1.59.0
-- Found the following Boost libraries:
-- system
-- program_options
-- filesystem
-- context
-- Could NOT find LIBINOTIFY (missing: LIBINOTIFY_LIBRARY LIBINOTIFY_INCLUDE_DIR)
-- System PCRE does not have JIT enabled - will use hhvm-third-party/pcre
-- Found libevent: /opt/local/lib/libevent.dylib
-- Found libsqlite3: /opt/local/lib/libsqlite3.dylib
-- Could NOT find DOUBLE_CONVERSION (missing: DOUBLE_CONVERSION_LIBRARY DOUBLE_CONVERSION_INCLUDE_DIR)
-- Using third-party bundled double-conversion
-- Found LZ4: /usr/local/lib/liblz4.dylib
-- Could NOT find FastLZ (missing: FASTLZ_LIBRARY FASTLZ_INCLUDE_DIR)
-- Using third-party bundled fastlz
-- Found libzip: /opt/local/lib/libzip.dylib 0.11.1
-- Found ICU header files in /opt/local/include
-- Found ICU libraries: /opt/local/lib/libicuuc.dylib
-- Found jemalloc: /opt/local/lib/libjemalloc.dylib
-- Found Intel TBB
-- Looking for dwarf_producer_init
-- Looking for dwarf_producer_init - found
-- Performing Test DW_CONST
-- Performing Test DW_CONST - Success
-- Looking for dwarf_producer_init_c
-- Looking for dwarf_producer_init_c - not found
-- libdwarf uses const char* type
-- libdwarf does not have dwarf_producer_init_c, using dwarf_producer_init
Generating Release build
-- Warning: Did not find file Compiler/-ASM
-- Found ocamlc: /opt/local/bin/ocamlc
-- Found ocamlc.opt: /opt/local/bin/ocamlc.opt
-- Using built-in JSON parser
-- Building the apache extension.
-- Building the apc extension.
-- Building the array extension.
-- Building the asio extension.
-- Building the Async MySQL extension.
-- Building the bcmath extension.
-- Building the bz2 extension.
-- Building the closure extension.
-- Building the collections extension.
-- Building the ctype extension.
-- Building the curl extension.
-- Building the datetime extension.
-- Building the debugger extension.
-- Building the DOMDocument extension.
-- Building the enum extension.
-- Found ICU header files in /opt/local/include
-- Found ICU libraries: /opt/local/lib/libicuuc.dylib
-- Building the fb extension.
-- Found ICU header files in /opt/local/include
-- Found ICU libraries: /opt/local/lib/libicuuc.dylib
-- Building the fileinfo extension.
-- Building the filter extension.
-- Found GNU FriBidi: /opt/local/lib/libfribidi.dylib
-- Building the fribidi extension.
-- Found GNU FriBidi: /opt/local/lib/libfribidi.dylib
-- Building the gd extension.
-- Building the generator extension.
-- Building the gmp extension.
-- Building the hash extension.
-- Building the hh extension.
-- Building the hh_client extension.
-- Building the Hot Profiler extension.
-- Building the iconv extension.
-- Found ICU header files in /opt/local/include
-- Found ICU libraries: /opt/local/lib/libicuuc.dylib
-- Building the icu extension.
-- Found ICU header files in /opt/local/include
-- Found ICU libraries: /opt/local/lib/libicuuc.dylib
Not building the imagick extension.
-- Building the imap extension.
-- Building the intervaltimer extension.
-- Building the ipc extension.
-- Building the json extension.
-- Building the ldap extension.
-- Building the libxml extension.
-- Building the mail extension.
-- Building the mailparse extension.
-- Building the mbstring extension.
Not building the mcrouter extension.
-- Found mcrypt: /opt/local/lib/libmcrypt.dylib
-- Building the mcrypt extension.
-- Found mcrypt: /opt/local/lib/libmcrypt.dylib
-- Building the memcache extension.
-- Building the memcached extension.
-- Building the MySQL extension.
-- Building the MySQLi extension.
-- Building the objprof extension.
-- Building the odbc extension.
-- Building the openssl extension.
-- Building the pcre extension.
-- Building the pdo extension.
-- Building the pdo_mysql extension.
-- Building the pdo_sqlite extension.
-- Building the phar extension.
-- Building the posix extension.
-- Building the process extension.
-- Building the readline extension.
-- Building the reflection extension.
-- Building the server extension.
-- Building the session extension.
-- Building the simplexml extension.
-- Building the soap extension.
-- Building the sockets extension.
-- Building the spl extension.
-- Building the sqlite3 extension.
-- Building the std extension.
-- Building the stream extension.
-- Building the string extension.
-- Building the thread extension.
-- Building the thrift extension.
-- Building the url extension.
-- Building the wddx extension.
-- Building the xdebug extension.
-- Building the xenon extension.
-- Building the xhprof extension.
-- Building the xml extension.
-- Building the xmlreader extension.
-- Building the xmlwriter extension.
-- Building the xsl extension.
-- Building the zip extension.
-- Building the zlib extension.
CMake Warning (dev) at CMake/HPHPFunctions.cmake:177 (get_target_property):
Policy CMP0026 is not set: Disallow use of the LOCATION target property.
Run "cmake --help-policy CMP0026" for policy details. Use the cmake_policy
command to set the policy and suppress this warning.
The LOCATION property should not be read from target "hhvm". Use the
target name directly with add_custom_command, or use the generator
expression $<TARGET_FILE>, as appropriate.
Call Stack (most recent call first):
hphp/hhvm/CMakeLists.txt:62 (HHVM_INSTALL)
This warning is for project developers. Use -Wno-dev to suppress it.
-- Configuring done
-- Generating done
-- Build files have been written to: /opt/local/apache2/htdocs/hhvm/hhvm
run
hhvm
, result :dyld: Library not loaded: /opt/local/lib/libicudata.53.dylib Referenced from: /opt/local/bin/hhvm Reason: image not found Trace/BPT trap: 5
libicudata.53.dylib the library is indeed not present /opt/local/lib/
.
I do not know how to fix this.
hhvm
was built against an older version of the International Components for Unicode (ICU). Your cmake output suggests that the correct copy of the ICU libraries was picked up though. Since your steps do not show build output: Did you actually build hhvm? Are you sure the hhvm binary you're running is the one you built locally? – neverpanic$PATH
, and consequently binaries from the working directory are not picked up when you run them by name -- only running them using a path (e.g.,./hhvm
) will use them from the current working directory. To check whichhhvm
is executed, usetype hhvm
orwhich hhvm
(your output suggests it might be/opt/local/bin/hhvm
). Also provide the output ofotool -L $(which hhvm)
. – neverpanic