lua---mattorch
lua---mattorch copied to clipboard
OSx 10.7.5 install error
I tried installing mattorch with luarocks install mattorch After i exported the matlab path it gives the following build error:
Installing https://raw.githubusercontent.com/torch/rocks/master/mattorch-1.0-0.rockspec...
Using https://raw.githubusercontent.com/torch/rocks/master/mattorch-1.0-0.rockspec... switching to 'build' mode
Cloning into 'lua---mattorch'...
remote: Counting objects: 19, done.
remote: Compressing objects: 100% (16/16), done.
remote: Total 19 (delta 0), reused 8 (delta 0)
Receiving objects: 100% (19/19), 11.32 KiB, done.
Note: checking out 'c3640f86dc23c9cac836752576f6a3594d9fc4e3'.
You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by performing another checkout.
If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -b with the checkout command again. Example:
git checkout -b new_branch_name
cmake -E make_directory build;
cd build;
cmake .. -DCMAKE_BUILD_TYPE=Release -DCMAKE_PREFIX_PATH="/usr/local/bin/.." -DCMAKE_INSTALL_PREFIX="/usr/local/lib/luarocks/rocks/mattorch/1.0-0";
make
-- The C compiler identification is AppleClang 4.2.0.4250028
-- The CXX compiler identification is AppleClang 4.2.0.4250028
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Found Torch7 in /usr/local
-- Using Matlab in: /Applications/MATLAB_R2013b.app
-- Found Matlab: /Applications/MATLAB_R2013b.app/bin/maci64/libmex.dylib
-- Configuring done
CMake Warning (dev):
Policy CMP0042 is not set: MACOSX_RPATH is enabled by default. Run "cmake
--help-policy CMP0042" for policy details. Use the cmake_policy command to
set the policy and suppress this warning.
MACOSX_RPATH is not specified for the following targets:
mattorchlive
This warning is for project developers. Use -Wno-dev to suppress it.
-- Generating done
-- Build files have been written to: /tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/build
Scanning dependencies of target mattorch
[ 50%] Building C object CMakeFiles/mattorch.dir/mattorch.c.o
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorch.c:97:33: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
luaT_pushudata(L, tensor, luaT_checktypename2id(L, "torch.DoubleTensor"));
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorch.c:105:33: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
luaT_pushudata(L, tensor, luaT_checktypename2id(L, "torch.FloatTensor"));
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorch.c:113:33: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
luaT_pushudata(L, tensor, luaT_checktypename2id(L, "torch.IntTensor"));
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorch.c:121:33: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
luaT_pushudata(L, tensor, luaT_checktypename2id(L, "torch.IntTensor"));
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorch.c:129:33: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
luaT_pushudata(L, tensor, luaT_checktypename2id(L, "torch.ShortTensor"));
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorch.c:137:33: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
luaT_pushudata(L, tensor, luaT_checktypename2id(L, "torch.ShortTensor"));
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorch.c:145:33: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
luaT_pushudata(L, tensor, luaT_checktypename2id(L, "torch.CharTensor"));
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorch.c:153:33: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
luaT_pushudata(L, tensor, luaT_checktypename2id(L, "torch.ByteTensor"));
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorch.c:161:33: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
luaT_pushudata(L, tensor, luaT_checktypename2id(L, "torch.ByteTensor"));
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorch.c:198:68: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
THDoubleTensor *tensor = (THDoubleTensor *)luaT_checkudata(L, 2, luaT_checktypename2id(L, "torch.DoubleTensor"));
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorch.c:238:71: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
THDoubleTensor *tensor = (THDoubleTensor *)luaT_checkudata(L, -1, luaT_checktypename2id(L, "torch.DoubleTensor"));
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorch.c:276:40: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
THFile *file = luaT_checkudata(L, 1, luaT_checktypename2id(L, "torch.File"));
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorch.c:279:68: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
THDoubleTensor *tensor = (THDoubleTensor *)luaT_checkudata(L, 2, luaT_checktypename2id(L, "torch.DoubleTensor"));
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
13 warnings generated.
Linking C shared module libmattorch.so
[ 50%] Built target mattorch
Scanning dependencies of target mattorchlive
[100%] Building C object CMakeFiles/mattorchlive.dir/mattorchlive.c.o
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorchlive.c:74:3: warning: implicit declaration of function 'lua_executable_dir' is invalid in C99
[-Wimplicit-function-declaration]
lua_executable_dir("./lua");
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorchlive.c:158:33: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
luaT_pushudata(L, tensor, luaT_checktypename2id(L, "torch.DoubleTensor"));
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorchlive.c:164:33: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
luaT_pushudata(L, tensor, luaT_checktypename2id(L, "torch.FloatTensor"));
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorchlive.c:170:33: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
luaT_pushudata(L, tensor, luaT_checktypename2id(L, "torch.LongTensor"));
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorchlive.c:176:33: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
luaT_pushudata(L, tensor, luaT_checktypename2id(L, "torch.IntTensor"));
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorchlive.c:182:33: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
luaT_pushudata(L, tensor, luaT_checktypename2id(L, "torch.IntTensor"));
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorchlive.c:188:33: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
luaT_pushudata(L, tensor, luaT_checktypename2id(L, "torch.ShortTensor"));
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorchlive.c:194:33: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
luaT_pushudata(L, tensor, luaT_checktypename2id(L, "torch.ShortTensor"));
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorchlive.c:200:33: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
luaT_pushudata(L, tensor, luaT_checktypename2id(L, "torch.CharTensor"));
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorchlive.c:206:33: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
luaT_pushudata(L, tensor, luaT_checktypename2id(L, "torch.ByteTensor"));
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorchlive.c:212:33: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
luaT_pushudata(L, tensor, luaT_checktypename2id(L, "torch.ByteTensor"));
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorchlive.c:229:38: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
if (luaT_isudata(L, -noutputs+o, luaT_checktypename2id(L, "torch.DoubleTensor"))) {
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorchlive.c:231:51: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
void *tensor = luaT_toudata(L, -noutputs+o, luaT_checktypename2id(L, "torch.DoubleTensor"));
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorchlive.c:243:45: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
} else if (luaT_isudata(L, -noutputs+o, luaT_checktypename2id(L, "torch.FloatTensor"))) {
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorchlive.c:245:51: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
void *tensor = luaT_toudata(L, -noutputs+o, luaT_checktypename2id(L, "torch.FloatTensor"));
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorchlive.c:257:45: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
} else if (luaT_isudata(L, -noutputs+o, luaT_checktypename2id(L, "torch.IntTensor"))) {
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorchlive.c:259:51: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
void *tensor = luaT_toudata(L, -noutputs+o, luaT_checktypename2id(L, "torch.IntTensor"));
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorchlive.c:271:45: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
} else if (luaT_isudata(L, -noutputs+o, luaT_checktypename2id(L, "torch.LongTensor"))) {
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorchlive.c:273:51: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
void *tensor = luaT_toudata(L, -noutputs+o, luaT_checktypename2id(L, "torch.LongTensor"));
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorchlive.c:285:45: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
} else if (luaT_isudata(L, -noutputs+o, luaT_checktypename2id(L, "torch.ShortTensor"))) {
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorchlive.c:287:51: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
void *tensor = luaT_toudata(L, -noutputs+o, luaT_checktypename2id(L, "torch.ShortTensor"));
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorchlive.c:299:45: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
} else if (luaT_isudata(L, -noutputs+o, luaT_checktypename2id(L, "torch.CharTensor"))) {
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorchlive.c:301:51: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
void *tensor = luaT_toudata(L, -noutputs+o, luaT_checktypename2id(L, "torch.CharTensor"));
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorchlive.c:313:45: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
} else if (luaT_isudata(L, -noutputs+o, luaT_checktypename2id(L, "torch.ByteTensor"))) {
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
/tmp/luarocks_mattorch-1.0-0-4582/lua---mattorch/mattorchlive.c:315:51: warning: 'luaT_checktypename2id' is deprecated [-Wdeprecated-declarations]
void *tensor = luaT_toudata(L, -noutputs+o, luaT_checktypename2id(L, "torch.ByteTensor"));
^
/usr/local/include/luaT.h:106:38: note: 'luaT_checktypename2id' declared here
LUAT_API LUAT_DEPRECATED const char* luaT_checktypename2id(lua_State *L, const char *tname); /* same as luaT_typenameid */
^
25 warnings generated.
Linking C shared library libmattorchlive.dylib
Undefined symbols for architecture x86_64:
"_luaL_error", referenced from:
_lstop in mattorchlive.c.o
"_luaL_loadbuffer", referenced from:
_mattorch_dostring in mattorchlive.c.o
"_luaL_loadfile", referenced from:
_mattorch_dofile in mattorchlive.c.o
"_luaL_newstate", referenced from:
_mattorch_init in mattorchlive.c.o
"_luaL_openlibs", referenced from:
_mattorch_init in mattorchlive.c.o
"_lua_call", referenced from:
_mattorch_callfunc in mattorchlive.c.o
_traceback in mattorchlive.c.o
"_lua_close", referenced from:
_mattorch_close in mattorchlive.c.o
"_lua_executable_dir", referenced from:
_mattorch_init in mattorchlive.c.o
"_lua_gc", referenced from:
_mattorch_init in mattorchlive.c.o
_docall in mattorchlive.c.o
"_lua_getfield", referenced from:
_mattorch_dorequire in mattorchlive.c.o
_mattorch_callfunc in mattorchlive.c.o
_traceback in mattorchlive.c.o
"_lua_gettop", referenced from:
_docall in mattorchlive.c.o
"_lua_insert", referenced from:
_docall in mattorchlive.c.o
"_lua_isstring", referenced from:
_traceback in mattorchlive.c.o
"_lua_pcall", referenced from:
_docall in mattorchlive.c.o
"_lua_pushcclosure", referenced from:
_docall in mattorchlive.c.o
"_lua_pushinteger", referenced from:
_traceback in mattorchlive.c.o
"_lua_pushstring", referenced from:
_mattorch_dorequire in mattorchlive.c.o
"_lua_pushvalue", referenced from:
_traceback in mattorchlive.c.o
"_lua_remove", referenced from:
_docall in mattorchlive.c.o
"_lua_sethook", referenced from:
_laction in mattorchlive.c.o
_lstop in mattorchlive.c.o
"_lua_settop", referenced from:
_report in mattorchlive.c.o
_mattorch_callfunc in mattorchlive.c.o
_traceback in mattorchlive.c.o
"_lua_tolstring", referenced from:
_report in mattorchlive.c.o
"_lua_type", referenced from:
_report in mattorchlive.c.o
_traceback in mattorchlive.c.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[2]: *** [libmattorchlive.dylib] Error 1
make[1]: *** [CMakeFiles/mattorchlive.dir/all] Error 2
make: *** [all] Error 2
Error: Build error: Failed building.
Same thing here.
same issue, with exactly the same error message. I am using OS X 10.11.4. Does anyone have a solution? I need to use mattorch instead of matio because my .mat file is stored with 'v7.3' flag, and matio does not read such .mat files...
The issue is to inform the linker the right library to link with, you can change to this instead in the CMakeLists.txt:
TARGET_LINK_LIBRARIES(mattorchlive TH luaT luajit ${MATLAB_LIBRARIES})
I added the luajit into it because libluajit.dylib file contains those missing files, except one function lua_executable_dir which is required by void mattorch_init(void). I am not sure why this function is necessary, so I removed it in the source file (mattorchlive.c). If you now install the mattorch by cmake, it seems to work properly on Mac OS Sierra.