Closed lewislepton closed 9 years ago
That is where I would put it, yes.
this is what popped up
lepton:~ lepton$ /usr/bin/cc -Wall -Wextra -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk -bundle -Wl,-headerpad_max_install_names -undefined dynamic_lookup -o image.so CMakeFiles/image.dir/src/image.c.o -F/Library/Frameworks ../common/libcommon.a -framework SDL2 -framework SDL2_image -Wl,-rpath,/Library/Frameworks
clang: error: no such file or directory: 'CMakeFiles/image.dir/src/image.c.o'
clang: error: no such file or directory: '../common/libcommon.a'
Try cd-ing into sdl-image/ and rerun the same command.
oddly the same thing
lepton:~ lepton$ cd /Users/lepton/Downloads/luasdl2-master/sdl-image
lepton:sdl-image lepton$ /usr/bin/cc -Wall -Wextra -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk -bundle -Wl,-headerpad_max_install_names -undefined dynamic_lookup -o image.so CMakeFiles/image.dir/src/image.c.o -F/Library/Frameworks ../common/libcommon.a -framework SDL2 -framework SDL2_image -Wl,-rpath,/Library/Frameworks
clang: error: no such file or directory: 'CMakeFiles/image.dir/src/image.c.o'
clang: error: no such file or directory: '../common/libcommon.a'
Oh, sorry- try /Users/lepton/Downloads/luasdl2-master/_build_/sdl-image
it built the image.so. what next?
Wherever you put the SDL.so
file, create an SDL
folder, and put image.so
into there.
Similar steps should get mixer, net, and ttf working, but I'd suggest ensuring the examples that don't require them are working first.
should i put SDL.so in that folder, or have it stay where it is so its reading whatever is inside the folder?
SDL.so
stays as /usr/local/lib/lua/5.3/SDL.so
image.so
becomes /usr/local/lib/lua/5.3/SDL/image.so
one other question. i normally use sublime for all my lua based stuff. can i use that, and if so, how?
also just import with dofile into terminal to check. here is the output
> dofile("/Users/lepton/Downloads/luasdl2-master/examples/paths/paths.lua")
Base directory: /usr/local/bin/
Preference directory: /Users/lepton/Library/Application Support/Lua-SDL2/Testing/
but that image.so is in the right place now
also tried the threads one
> dofile("/Users/lepton/Downloads/luasdl2-master/examples/threads/channel.lua") Waiting...
Main...
Pushing...
Received: true
He received
>
I assume lua is installed at /usr/local/bin/
? It seems like the examples are running properly, yeah.
aye, it is installed in bin. here is some snapshots to show the current setup
So it sounds like you have a working setup now, just not one that builds conveniently.
aye, its getting there. slowly but surely ;) its just building the other things. we have the image.so, just the next ones now
just to say thanks as well. but hopefully once this is all done, then it can be weeded out for others ;) its worth it
I assume you can adapt the image.so instructions to the other three submodules on your own?.
aye, just sorting them now
here are them all. just double check before i start using them
/usr/bin/cc -Wall -Wextra -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk -bundle -Wl,-headerpad_max_install_names -undefined dynamic_lookup -o mixer.so CMakeFiles/mixer.dir/src/mixer.c.o -F/Library/Frameworks ../common/libcommon.a -framework SDL2 -framework SDL2_mixer -Wl,-rpath,/Library/Frameworks
/usr/bin/cc -Wall -Wextra -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk -bundle -Wl,-headerpad_max_install_names -undefined dynamic_lookup -o net.so CMakeFiles/net.dir/src/net.c.o -F/Library/Frameworks ../common/libcommon.a -framework SDL2 -framework SDL2_net -Wl,-rpath,/Library/Frameworks
/usr/bin/cc -Wall -Wextra -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk -bundle -Wl,-headerpad_max_install_names -undefined dynamic_lookup -o ttf.so CMakeFiles/ttf.dir/src/ttf.c.o -F/Library/Frameworks ../common/libcommon.a -framework SDL2 -framework SDL2_ttf -Wl,-rpath,/Library/Frameworks
As long as you run each from the right subfolder of _build_
, looks plausible.
just tried mixer
lepton:sdl-mixer lepton$ cd /Users/lepton/Downloads/luasdl2-master/_build_/sdl-mixer
lepton:sdl-mixer lepton$ /usr/bin/cc -Wall -Wextra -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk -bundle -Wl,-headerpad_max_install_names -undefined dynamic_lookup -o mixer.so CMakeFiles/mixer.dir/src/mixer.c.o -F/Library/Frameworks ../common/libcommon.a -framework SDL2 -framework SDL2_mixer -Wl,-rpath,/Library/Frameworks
clang: error: no such file or directory: 'CMakeFiles/mixer.dir/src/mixer.c.o'
same one with net
lepton:sdl-net lepton$ /usr/bin/cc -Wall -Wextra -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk -bundle -Wl,-headerpad_max_install_names -undefined dynamic_lookup -o net.so CMakeFiles/net.dir/src/net.c.o -F/Library/Frameworks ../common/libcommon.a -framework SDL2 -framework SDL2_net -Wl,-rpath,/Library/Frameworks
clang: error: no such file or directory: 'CMakeFiles/net.dir/src/net.c.o'
this is with in the build folder also, not outside it
same with ttf
lepton:sdl-ttf lepton$ /usr/bin/cc -Wall -Wextra -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk -bundle -Wl,-headerpad_max_install_names -undefined dynamic_lookup -o ttf.so CMakeFiles/ttf.dir/src/ttf.c.o -F/Library/Frameworks ../common/libcommon.a -framework SDL2 -framework SDL2_ttf -Wl,-rpath,/Library/Frameworks
clang: error: no such file or directory: 'CMakeFiles/ttf.dir/src/ttf.c.o'
obviously ive buggered up, but really just changed the image
text from before to mixer
ttf
net
checked what examples i could, and the ones which did not need the other add-ons [mixer/ttf/net], all work. rwops etc were fine, which is good.
also got it working in sublime text. so can build from that.
one thing i noticed with keyboard is that got stuck, didnt output anything, plus seemed to freeze lua. it didnt in a way since the 'x' to close it would come up if i hovered, but wouldnt shut down without force closing
its getting close though, but i cant figure out the mixer.co / ttf.co / net.co
build script. i thought i could just replace image
- but no dice
image.so works, which is cool
You have to be in _build_/sdl-net
,_build_/sdl-mixer
, _build_/sdl-ttf
, and so forth.
oh, thought i was. will try again. its late ;)
done it. but still problem. same actually from before. this is mixer
lepton:~ lepton$ cd /Users/lepton/Downloads/luasdl2-master/_build_/sdl-mixer
lepton:sdl-mixer lepton$ /usr/bin/cc -Wall -Wextra -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk -bundle -Wl,-headerpad_max_install_names -undefined dynamic_lookup -o mixer.so CMakeFiles/mixer.dir/src/mixer.c.o -F/Library/Frameworks ../common/libcommon.a -framework SDL2 -framework SDL2_mixer -Wl,-rpath,/Library/Frameworks
clang: error: no such file or directory: 'CMakeFiles/mixer.dir/src/mixer.c.o'
lepton:sdl-mixer lepton$
Oh, we never did the make-up-to-the-point-it-fails part, did we...
From build, run:
make mixer
make net
make ttf
They will all fail, but the manual linking should work after that.
HA, oh yeah. this post has been long ;) here is the output. they did spawn ;)
lepton:~ lepton$ cd /Users/lepton/Downloads/luasdl2-master/_build_/sdl-mixer
lepton:sdl-mixer lepton$ /usr/bin/cc -Wall -Wextra -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk -bundle -Wl,-headerpad_max_install_names -undefined dynamic_lookup -o mixer.so CMakeFiles/mixer.dir/src/mixer.c.o -F/Library/Frameworks ../common/libcommon.a -framework SDL2 -framework SDL2_mixer -Wl,-rpath,/Library/Frameworks
clang: error: no such file or directory: 'CMakeFiles/mixer.dir/src/mixer.c.o'
lepton:sdl-mixer lepton$ cd /Users/lepton/Downloads/luasdl2-master/_build_
lepton:_build_ lepton$ make mixer
[ 87%] Built target common
Scanning dependencies of target mixer
[100%] Building C object sdl-mixer/CMakeFiles/mixer.dir/src/mixer.c.o
Linking C shared module mixer.so
Undefined symbols for architecture x86_64:
"_luaL_checkinteger", referenced from:
_l_music_fadeIn in mixer.c.o
_l_music_volume in mixer.c.o
_l_music_fadeOut in mixer.c.o
_l_chunk_volume in mixer.c.o
_l_chunk_playChannel in mixer.c.o
_l_chunk_fadeInChannel in mixer.c.o
_l_mixer_openAudio in mixer.c.o
...
"_luaL_checklstring", referenced from:
_l_mixer_loadWAV in mixer.c.o
_l_mixer_loadMUS in mixer.c.o
_l_rw_fromFile in libcommon.a(rwops.c.o)
_l_rw_readByte in libcommon.a(rwops.c.o)
_l_rw_write in libcommon.a(rwops.c.o)
_l_rw_writeByte in libcommon.a(rwops.c.o)
"_luaL_checknumber", referenced from:
_l_music_fadeIn in mixer.c.o
_l_music_setPosition in mixer.c.o
"_luaL_checktype", referenced from:
_l_rw_create in libcommon.a(rwops.c.o)
"_luaL_checkudata", referenced from:
_commonGetUserdata in libcommon.a(common.c.o)
"_luaL_error", referenced from:
_l_mixer_fadingChannel in mixer.c.o
_rw_readparams in libcommon.a(rwops.c.o)
"_luaL_newmetatable", referenced from:
_commonBindObject in libcommon.a(common.c.o)
"_luaL_optinteger", referenced from:
_l_music_play in mixer.c.o
_l_chunk_playChannel in mixer.c.o
_l_chunk_fadeInChannel in mixer.c.o
_l_mixer_getChunkDecoder in mixer.c.o
_l_mixer_playing in mixer.c.o
_l_mixer_paused in mixer.c.o
_l_mixer_groupChannel in mixer.c.o
...
"_luaL_ref", referenced from:
_l_rw_create in libcommon.a(rwops.c.o)
"_luaL_setfuncs", referenced from:
_commonBindObject in libcommon.a(common.c.o)
_commonBindLibrary in libcommon.a(common.c.o)
_commonNewLibrary in libcommon.a(common.c.o)
"_luaL_setmetatable", referenced from:
_commonPushUserdata in libcommon.a(common.c.o)
"_luaL_unref", referenced from:
_l_rw_create in libcommon.a(rwops.c.o)
_l_rw_gc in libcommon.a(rwops.c.o)
"_lua_callk", referenced from:
_rw_size in libcommon.a(rwops.c.o)
_rw_seek in libcommon.a(rwops.c.o)
_rw_read in libcommon.a(rwops.c.o)
_rw_write in libcommon.a(rwops.c.o)
_rw_close in libcommon.a(rwops.c.o)
"_lua_createtable", referenced from:
_commonBindEnum in libcommon.a(common.c.o)
_commonPushEnum in libcommon.a(common.c.o)
_commonBindObject in libcommon.a(common.c.o)
_commonNewLibrary in libcommon.a(common.c.o)
"_lua_getfield", referenced from:
_l_rw_create in libcommon.a(rwops.c.o)
"_lua_gettop", referenced from:
_l_music_fadeIn in mixer.c.o
"_lua_newuserdata", referenced from:
_commonPushUserdata in libcommon.a(common.c.o)
"_lua_next", referenced from:
_commonGetEnum in libcommon.a(common.c.o)
"_lua_pushboolean", referenced from:
_commonPush in libcommon.a(common.c.o)
"_lua_pushfstring", referenced from:
_l_rw_tostring in libcommon.a(rwops.c.o)
"_lua_pushinteger", referenced from:
_l_rw_read in libcommon.a(rwops.c.o)
_rw_seek in libcommon.a(rwops.c.o)
_rw_read in libcommon.a(rwops.c.o)
_rw_write in libcommon.a(rwops.c.o)
_commonBindEnum in libcommon.a(common.c.o)
_commonPushEnum in libcommon.a(common.c.o)
_commonPush in libcommon.a(common.c.o)
...
"_lua_pushlstring", referenced from:
_l_rw_read in libcommon.a(rwops.c.o)
_rw_write in libcommon.a(rwops.c.o)
"_lua_pushnil", referenced from:
_commonGetEnum in libcommon.a(common.c.o)
_commonPushSDLError in libcommon.a(common.c.o)
_commonPushErrno in libcommon.a(common.c.o)
_commonPush in libcommon.a(common.c.o)
"_lua_pushnumber", referenced from:
_commonPush in libcommon.a(common.c.o)
"_lua_pushstring", referenced from:
_commonPushSDLError in libcommon.a(common.c.o)
_commonPushErrno in libcommon.a(common.c.o)
_commonPush in libcommon.a(common.c.o)
"_lua_pushvalue", referenced from:
_l_rw_create in libcommon.a(rwops.c.o)
"_lua_rawgeti", referenced from:
_rw_size in libcommon.a(rwops.c.o)
_rw_seek in libcommon.a(rwops.c.o)
_rw_read in libcommon.a(rwops.c.o)
_rw_write in libcommon.a(rwops.c.o)
_rw_close in libcommon.a(rwops.c.o)
"_lua_rawseti", referenced from:
_commonPushEnum in libcommon.a(common.c.o)
"_lua_setfield", referenced from:
_commonBindEnum in libcommon.a(common.c.o)
_commonBindObject in libcommon.a(common.c.o)
"_lua_settop", referenced from:
_l_rw_create in libcommon.a(rwops.c.o)
_commonGetEnum in libcommon.a(common.c.o)
_commonBindObject in libcommon.a(common.c.o)
"_lua_tointegerx", referenced from:
_rw_size in libcommon.a(rwops.c.o)
_rw_seek in libcommon.a(rwops.c.o)
_rw_read in libcommon.a(rwops.c.o)
_rw_write in libcommon.a(rwops.c.o)
_rw_close in libcommon.a(rwops.c.o)
_commonGetEnum in libcommon.a(common.c.o)
"_lua_tolstring", referenced from:
_rw_read in libcommon.a(rwops.c.o)
"_lua_tonumberx", referenced from:
_commonGetEnum in libcommon.a(common.c.o)
"_lua_type", referenced from:
_l_rw_create in libcommon.a(rwops.c.o)
_rw_read in libcommon.a(rwops.c.o)
_rw_close in libcommon.a(rwops.c.o)
_commonGetEnum in libcommon.a(common.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[3]: *** [sdl-mixer/mixer.so] Error 1
make[2]: *** [sdl-mixer/CMakeFiles/mixer.dir/all] Error 2
make[1]: *** [sdl-mixer/CMakeFiles/mixer.dir/rule] Error 2
make: *** [mixer] Error 2
lepton:_build_ lepton$ cd /Users/lepton/Downloads/luasdl2-master/_build_/sdl-mixer
lepton:sdl-mixer lepton$ /usr/bin/cc -Wall -Wextra -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk -bundle -Wl,-headerpad_max_install_names -undefined dynamic_lookup -o mixer.so CMakeFiles/mixer.dir/src/mixer.c.o -F/Library/Frameworks ../common/libcommon.a -framework SDL2 -framework SDL2_mixer -Wl,-rpath,/Library/Frameworks
lepton:sdl-mixer lepton$ cd /Users/lepton/Downloads/luasdl2-master/_build_
lepton:_build_ lepton$ make net
[ 87%] Built target common
Scanning dependencies of target net
[100%] Building C object sdl-net/CMakeFiles/net.dir/src/net.c.o
Linking C shared module net.so
Undefined symbols for architecture x86_64:
"_luaL_checkinteger", referenced from:
_l_set_checkSockets in net.c.o
_l_udp_bind in net.c.o
_l_udp_unbind in net.c.o
_l_udp_getPeerAddress in net.c.o
_l_udp_send in net.c.o
_l_udp_recv in net.c.o
_l_tcp_recv in net.c.o
...
"_luaL_checklstring", referenced from:
_l_udp_send in net.c.o
_l_tcp_send in net.c.o
_l_resolveHost in net.c.o
"_luaL_checktype", referenced from:
_checkAddress in net.c.o
"_luaL_checkudata", referenced from:
_commonGetUserdata in libcommon.a(common.c.o)
_tableGetUserdata in libcommon.a(table.c.o)
"_luaL_error", referenced from:
_l_set_add in net.c.o
_l_set_del in net.c.o
_l_udp_send in net.c.o
_assertNotClosed in net.c.o
_ready in net.c.o
"_luaL_newmetatable", referenced from:
_commonBindObject in libcommon.a(common.c.o)
"_luaL_setfuncs", referenced from:
_commonBindObject in libcommon.a(common.c.o)
_commonBindLibrary in libcommon.a(common.c.o)
_commonNewLibrary in libcommon.a(common.c.o)
"_luaL_setmetatable", referenced from:
_commonPushUserdata in libcommon.a(common.c.o)
"_luaL_testudata", referenced from:
_l_set_add in net.c.o
_l_set_del in net.c.o
"_lua_createtable", referenced from:
_luaopen_SDL_net in net.c.o
_l_set_gc in net.c.o
_pushAddress in net.c.o
_closeSocket in net.c.o
_commonBindEnum in libcommon.a(common.c.o)
_commonPushEnum in libcommon.a(common.c.o)
_commonBindObject in libcommon.a(common.c.o)
...
"_lua_getfield", referenced from:
_l_set_add in net.c.o
_l_set_del in net.c.o
_tableIsType in libcommon.a(table.c.o)
_tableGetUserdata in libcommon.a(table.c.o)
_tableGetInt in libcommon.a(table.c.o)
_tableGetDouble in libcommon.a(table.c.o)
_tableGetEnum in libcommon.a(table.c.o)
...
"_lua_getuservalue", referenced from:
_assertNotClosed in net.c.o
"_lua_newuserdata", referenced from:
_commonPushUserdata in libcommon.a(common.c.o)
"_lua_next", referenced from:
_commonGetEnum in libcommon.a(common.c.o)
"_lua_pushboolean", referenced from:
_commonPush in libcommon.a(common.c.o)
_tableSetBool in libcommon.a(table.c.o)
"_lua_pushinteger", referenced from:
_l_udp_recv in net.c.o
_l_tcp_send in net.c.o
_l_tcp_recv in net.c.o
_commonBindEnum in libcommon.a(common.c.o)
_commonPushEnum in libcommon.a(common.c.o)
_commonPush in libcommon.a(common.c.o)
_tableSetInt in libcommon.a(table.c.o)
...
"_lua_pushlstring", referenced from:
_l_udp_recv in net.c.o
_l_tcp_recv in net.c.o
_tableSetStringl in libcommon.a(table.c.o)
"_lua_pushnil", referenced from:
_l_set_del in net.c.o
_l_udp_recv in net.c.o
_l_tcp_recv in net.c.o
_commonGetEnum in libcommon.a(common.c.o)
_commonPushSDLError in libcommon.a(common.c.o)
_commonPushErrno in libcommon.a(common.c.o)
_commonPush in libcommon.a(common.c.o)
...
"_lua_pushnumber", referenced from:
_commonPush in libcommon.a(common.c.o)
_tableSetDouble in libcommon.a(table.c.o)
"_lua_pushstring", referenced from:
_l_tcp_send in net.c.o
_l_tcp_recv in net.c.o
_commonPushSDLError in libcommon.a(common.c.o)
_commonPushErrno in libcommon.a(common.c.o)
_commonPush in libcommon.a(common.c.o)
_tableSetString in libcommon.a(table.c.o)
"_lua_pushvalue", referenced from:
_l_set_add in net.c.o
"_lua_rawseti", referenced from:
_commonPushEnum in libcommon.a(common.c.o)
"_lua_rawsetp", referenced from:
_l_set_add in net.c.o
_l_set_del in net.c.o
"_lua_setfield", referenced from:
_luaopen_SDL_net in net.c.o
_l_set_gc in net.c.o
_commonBindEnum in libcommon.a(common.c.o)
_commonBindObject in libcommon.a(common.c.o)
_tableSetInt in libcommon.a(table.c.o)
_tableSetDouble in libcommon.a(table.c.o)
_tableSetString in libcommon.a(table.c.o)
...
"_lua_settop", referenced from:
_l_set_add in net.c.o
_l_set_del in net.c.o
_assertNotClosed in net.c.o
_commonGetEnum in libcommon.a(common.c.o)
_commonBindObject in libcommon.a(common.c.o)
_tableIsType in libcommon.a(table.c.o)
_tableGetUserdata in libcommon.a(table.c.o)
...
"_lua_setuservalue", referenced from:
_closeSocket in net.c.o
"_lua_toboolean", referenced from:
_tableGetBool in libcommon.a(table.c.o)
"_lua_tointegerx", referenced from:
_commonGetEnum in libcommon.a(common.c.o)
_tableGetInt in libcommon.a(table.c.o)
"_lua_tolstring", referenced from:
_tableGetString in libcommon.a(table.c.o)
_tableGetStringl in libcommon.a(table.c.o)
"_lua_tonumberx", referenced from:
_commonGetEnum in libcommon.a(common.c.o)
_tableGetDouble in libcommon.a(table.c.o)
"_lua_touserdata", referenced from:
_l_set_add in net.c.o
_l_set_del in net.c.o
"_lua_type", referenced from:
_l_udp_send in net.c.o
_assertNotClosed in net.c.o
_l_resolveHost in net.c.o
_commonGetEnum in libcommon.a(common.c.o)
_tableIsType in libcommon.a(table.c.o)
_tableGetInt in libcommon.a(table.c.o)
_tableGetDouble in libcommon.a(table.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[3]: *** [sdl-net/net.so] Error 1
make[2]: *** [sdl-net/CMakeFiles/net.dir/all] Error 2
make[1]: *** [sdl-net/CMakeFiles/net.dir/rule] Error 2
make: *** [net] Error 2
lepton:_build_ lepton$ cd /Users/lepton/Downloads/luasdl2-master/_build_/sdl-net
lepton:sdl-net lepton$ /usr/bin/cc -Wall -Wextra -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk -bundle -Wl,-headerpad_max_install_names -undefined dynamic_lookup -o net.so CMakeFiles/net.dir/src/net.c.o -F/Library/Frameworks ../common/libcommon.a -framework SDL2 -framework SDL2_net -Wl,-rpath,/Library/Frameworks
lepton:sdl-net lepton$ cd /Users/lepton/Downloads/luasdl2-master/_build_
lepton:_build_ lepton$ make ttf
[ 87%] Built target common
Scanning dependencies of target ttf
[100%] Building C object sdl-ttf/CMakeFiles/ttf.dir/src/ttf.c.o
Linking C shared module ttf.so
Undefined symbols for architecture x86_64:
"_luaL_checkinteger", referenced from:
_l_font_setOutline in ttf.c.o
_l_font_setHinting in ttf.c.o
_l_font_glyphIsProvided in ttf.c.o
_l_font_glyphMetrics in ttf.c.o
_l_open in ttf.c.o
_l_rw_read in libcommon.a(rwops.c.o)
_l_rw_readByte in libcommon.a(rwops.c.o)
...
"_luaL_checklstring", referenced from:
_fontRender in ttf.c.o
_fontSize in ttf.c.o
_l_rw_fromFile in libcommon.a(rwops.c.o)
_l_rw_readByte in libcommon.a(rwops.c.o)
_l_rw_write in libcommon.a(rwops.c.o)
_l_rw_writeByte in libcommon.a(rwops.c.o)
_l_surface_loadBMP in libcommon.a(surface.c.o)
...
"_luaL_checktype", referenced from:
_getUnicode in ttf.c.o
_l_rw_create in libcommon.a(rwops.c.o)
_l_surface_fillRects in libcommon.a(surface.c.o)
_videoGetRect in libcommon.a(video.c.o)
_readTable in libcommon.a(video.c.o)
_videoGetPoint in libcommon.a(video.c.o)
_videoGetLine in libcommon.a(video.c.o)
...
"_luaL_checkudata", referenced from:
_commonGetUserdata in libcommon.a(common.c.o)
_tableGetUserdata in libcommon.a(table.c.o)
"_luaL_error", referenced from:
_fontRender in ttf.c.o
_fontSize in ttf.c.o
_l_open in ttf.c.o
_rw_readparams in libcommon.a(rwops.c.o)
"_luaL_newmetatable", referenced from:
_commonBindObject in libcommon.a(common.c.o)
"_luaL_ref", referenced from:
_l_rw_create in libcommon.a(rwops.c.o)
"_luaL_setfuncs", referenced from:
_commonBindObject in libcommon.a(common.c.o)
_commonBindLibrary in libcommon.a(common.c.o)
_commonNewLibrary in libcommon.a(common.c.o)
"_luaL_setmetatable", referenced from:
_commonPushUserdata in libcommon.a(common.c.o)
"_luaL_unref", referenced from:
_l_rw_create in libcommon.a(rwops.c.o)
_l_rw_gc in libcommon.a(rwops.c.o)
"_lua_callk", referenced from:
_rw_size in libcommon.a(rwops.c.o)
_rw_seek in libcommon.a(rwops.c.o)
_rw_read in libcommon.a(rwops.c.o)
_rw_write in libcommon.a(rwops.c.o)
_rw_close in libcommon.a(rwops.c.o)
"_lua_createtable", referenced from:
_l_font_glyphMetrics in ttf.c.o
_commonBindEnum in libcommon.a(common.c.o)
_commonPushEnum in libcommon.a(common.c.o)
_commonBindObject in libcommon.a(common.c.o)
_commonNewLibrary in libcommon.a(common.c.o)
_videoPushColorRGB in libcommon.a(video.c.o)
_videoPushRect in libcommon.a(video.c.o)
...
"_lua_getfield", referenced from:
_l_rw_create in libcommon.a(rwops.c.o)
_tableIsType in libcommon.a(table.c.o)
_tableGetUserdata in libcommon.a(table.c.o)
_tableGetInt in libcommon.a(table.c.o)
_tableGetDouble in libcommon.a(table.c.o)
_tableGetEnum in libcommon.a(table.c.o)
_tableGetString in libcommon.a(table.c.o)
...
"_lua_gettop", referenced from:
_l_surface_createRGB in libcommon.a(surface.c.o)
_l_surface_fillRect in libcommon.a(surface.c.o)
"_lua_newuserdata", referenced from:
_commonPushUserdata in libcommon.a(common.c.o)
"_lua_next", referenced from:
_getUnicode in ttf.c.o
_commonGetEnum in libcommon.a(common.c.o)
_readTable in libcommon.a(video.c.o)
"_lua_pushboolean", referenced from:
_surfaceBlit in libcommon.a(surface.c.o)
_commonPush in libcommon.a(common.c.o)
_tableSetBool in libcommon.a(table.c.o)
"_lua_pushfstring", referenced from:
_l_rw_tostring in libcommon.a(rwops.c.o)
"_lua_pushinteger", referenced from:
_l_rw_read in libcommon.a(rwops.c.o)
_rw_seek in libcommon.a(rwops.c.o)
_rw_read in libcommon.a(rwops.c.o)
_rw_write in libcommon.a(rwops.c.o)
_commonBindEnum in libcommon.a(common.c.o)
_commonPushEnum in libcommon.a(common.c.o)
_commonPush in libcommon.a(common.c.o)
...
"_lua_pushlstring", referenced from:
_l_rw_read in libcommon.a(rwops.c.o)
_rw_write in libcommon.a(rwops.c.o)
_tableSetStringl in libcommon.a(table.c.o)
"_lua_pushnil", referenced from:
_getUnicode in ttf.c.o
_commonGetEnum in libcommon.a(common.c.o)
_commonPushSDLError in libcommon.a(common.c.o)
_commonPushErrno in libcommon.a(common.c.o)
_commonPush in libcommon.a(common.c.o)
_readTable in libcommon.a(video.c.o)
"_lua_pushnumber", referenced from:
_commonPush in libcommon.a(common.c.o)
_tableSetDouble in libcommon.a(table.c.o)
"_lua_pushstring", referenced from:
_commonPushSDLError in libcommon.a(common.c.o)
_commonPushErrno in libcommon.a(common.c.o)
_commonPush in libcommon.a(common.c.o)
_tableSetString in libcommon.a(table.c.o)
"_lua_pushvalue", referenced from:
_l_rw_create in libcommon.a(rwops.c.o)
"_lua_rawgeti", referenced from:
_rw_size in libcommon.a(rwops.c.o)
_rw_seek in libcommon.a(rwops.c.o)
_rw_read in libcommon.a(rwops.c.o)
_rw_write in libcommon.a(rwops.c.o)
_rw_close in libcommon.a(rwops.c.o)
"_lua_rawseti", referenced from:
_commonPushEnum in libcommon.a(common.c.o)
"_lua_setfield", referenced from:
_commonBindEnum in libcommon.a(common.c.o)
_commonBindObject in libcommon.a(common.c.o)
_tableSetInt in libcommon.a(table.c.o)
_tableSetDouble in libcommon.a(table.c.o)
_tableSetString in libcommon.a(table.c.o)
_tableSetStringl in libcommon.a(table.c.o)
_tableSetBool in libcommon.a(table.c.o)
...
"_lua_settop", referenced from:
_getUnicode in ttf.c.o
_l_rw_create in libcommon.a(rwops.c.o)
_commonGetEnum in libcommon.a(common.c.o)
_commonBindObject in libcommon.a(common.c.o)
_tableIsType in libcommon.a(table.c.o)
_tableGetUserdata in libcommon.a(table.c.o)
_tableGetInt in libcommon.a(table.c.o)
...
"_lua_toboolean", referenced from:
_l_font_setKerning in ttf.c.o
_l_surface_setColorKey in libcommon.a(surface.c.o)
_l_surface_setRLE in libcommon.a(surface.c.o)
_tableGetBool in libcommon.a(table.c.o)
"_lua_tointegerx", referenced from:
_getUnicode in ttf.c.o
_rw_size in libcommon.a(rwops.c.o)
_rw_seek in libcommon.a(rwops.c.o)
_rw_read in libcommon.a(rwops.c.o)
_rw_write in libcommon.a(rwops.c.o)
_rw_close in libcommon.a(rwops.c.o)
_commonGetEnum in libcommon.a(common.c.o)
...
"_lua_tolstring", referenced from:
_l_open in ttf.c.o
_rw_read in libcommon.a(rwops.c.o)
_tableGetString in libcommon.a(table.c.o)
_tableGetStringl in libcommon.a(table.c.o)
"_lua_tonumberx", referenced from:
_commonGetEnum in libcommon.a(common.c.o)
_tableGetDouble in libcommon.a(table.c.o)
"_lua_type", referenced from:
_l_open in ttf.c.o
_l_rw_create in libcommon.a(rwops.c.o)
_rw_read in libcommon.a(rwops.c.o)
_rw_close in libcommon.a(rwops.c.o)
_l_surface_fillRect in libcommon.a(surface.c.o)
_surfaceBlit in libcommon.a(surface.c.o)
_commonGetEnum in libcommon.a(common.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[3]: *** [sdl-ttf/ttf.so] Error 1
make[2]: *** [sdl-ttf/CMakeFiles/ttf.dir/all] Error 2
make[1]: *** [sdl-ttf/CMakeFiles/ttf.dir/rule] Error 2
make: *** [ttf] Error 2
lepton:_build_ lepton$ cd /Users/lepton/Downloads/luasdl2-master/_build_/sdl-ttf
lepton:sdl-ttf lepton$ /usr/bin/cc -Wall -Wextra -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk -bundle -Wl,-headerpad_max_install_names -undefined dynamic_lookup -o ttf.so CMakeFiles/ttf.dir/src/ttf.c.o -F/Library/Frameworks ../common/libcommon.a -framework SDL2 -framework SDL2_ttf -Wl,-rpath,/Library/Frameworks
lepton:sdl-ttf lepton$
photo proof now. ill just jam these in the usr/blah/blah
folder and test the examples
holy shit balls its all working. WOOOOOOOH, im knackered ;)
audio works
font works
joystick works
udp works though thats not sending anything, but it doesnt come up with errors
same with tcp. no photo, but also no errors
threads working. it was before, bt just to keep up with it all
thats it all working. now its just to get all of this post in a coherent way so others can now use it ;)
again, just to say thanks for this, really means an insane amount to me. been really wanting to use lua and SDL together for ages for making games, just never found anything recent enough. so this really makes my year ;)
You're welcome. Liking Lua+SDL was the reason I took up maintenance of this project.
Closing this issue, then, but #20 exists to track the Luarocks building status. Will also make a new issue for cmake.
After making the .so libs how do I start the program inside sublime?
I am not a sublime user; however, many programmer text editors let you set up commands to be run on the current file with key shortcuts. In this case, a command like lua %placeholder%
, or whatever syntax sublime uses.
I'm old-fashioned and just keep a termnal window open to the folder my current Lua scripts of interest are in.
@Tangent128 cool man. cheers
@Murii you need 2 things. a 'lua dev' package, which let you build and run from sublime. but if youre on mac, you need another which makes sure its going to your PATH. its called 'fix mac path', but thats for mac. a good search will come up with something if you are on something else and it doesnt work
placeholder being the path to lua ?
@Murii
so the 2 packages are lua dev
and fix mac path
those can be got from inside sublime using package control, as long as thats installed of course
@lewislepton I've just installed lua dev.Now?
i get right to the 'make' part [not even 'make install'] of the build, but it then doesnt make it. it says about something like 'SDL.so' at the end plus something else. dont know what it is. also did contact david regarding this but he doesnt know. he said it may be something to do with SDL2, maybe, but these are guesses really
– using yosemite/mac 10.10.3 – SDL2.0.3. built from source also tried the binary build from the site – have all the other SDL_image etc in my frameworks folder – also have cmake 2.8.12-2.
great if someone could help.
thanks