Re: [asterisk-users] Installing LUA
On Wednesday 17 June 2009 16:54:53 John A. Sullivan III wrote: On Wed, 2009-06-17 at 15:43 -0500, Tilghman Lesher wrote: On Wednesday 17 June 2009 14:55:55 John A. Sullivan III wrote: On Wed, 2009-06-17 at 14:18 -0500, Tilghman Lesher wrote: On Wednesday 17 June 2009 11:56:28 John A. Sullivan III wrote: On Wed, 2009-06-17 at 12:44 -0400, Sean Bright wrote: Watkins, Bradley wrote: One more bit of magic necessary here, as pbx/pbx_lua.c has includes for: #include lua5.1/lua.h #include lua5.1/lauxlib.h #include lua5.1/lualib.h On Redhat-based systems, it needs to be: #include lua.h #include lauxlib.h #include lualib.h Gah. OK. So the patch I supplied will find LUA at configure time but not compile time. This needs some more thought. Oops! Confirmed. menuselect found it but make failed. I'll make the edits by hand and let you know how I fared - John Try this patch: http://asterisk.drunkcoder.com/patches/20090617__luafix.diff.txt Alas, the patch fails completely. The configure revision numbers look very different. I am using the 1.6.1.1 tarball. I copied the patch into the source directory (asterisk-1.6.1.1) and ran patch -p0 20090617__luafix.diff.txt. It was a long list of failed hunks. What next? Thanks - John The patch is actually derived from the current 1.6.1 SVN source, so any changes made since 1.6.1.1 was branched are the difference. Updated patch: http://asterisk.drunkcoder.com/patches/20090617__luafix__1.6.1.1.diff.txt The patch applied cleanly but Asterisk segfaulted on startup. I did not see anything particularly suspicious in the console output - mostly warnings and errors about realtime database connectivity that we have not yet setup other than this message: [Jun 17 17:47:24] WARNING[30682]: loader.c:375 load_dynamic_module: Error loading module 'app_directory.so': /usr/lib64/libc-client.so.1: undefined symbol: mm_dlog As much as I'd like, I don't think I have the code knowledge and I don't have the time on this project to step through it with a debugger. What next? Thanks - John The error above has zilch to do with pbx_lua, but rather with the compilation of app_directory against IMAP and the probable inability of your linker to find the correct IMAP libraries. You can prove this by adding 'noload = app_directory.so' to your modules.conf and restarting Asterisk. -- Tilghman ___ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Installing LUA
On Thu, 2009-06-18 at 14:20 -0500, Tilghman Lesher wrote: On Wednesday 17 June 2009 16:54:53 John A. Sullivan III wrote: On Wed, 2009-06-17 at 15:43 -0500, Tilghman Lesher wrote: On Wednesday 17 June 2009 14:55:55 John A. Sullivan III wrote: On Wed, 2009-06-17 at 14:18 -0500, Tilghman Lesher wrote: On Wednesday 17 June 2009 11:56:28 John A. Sullivan III wrote: On Wed, 2009-06-17 at 12:44 -0400, Sean Bright wrote: Watkins, Bradley wrote: One more bit of magic necessary here, as pbx/pbx_lua.c has includes for: #include lua5.1/lua.h #include lua5.1/lauxlib.h #include lua5.1/lualib.h On Redhat-based systems, it needs to be: #include lua.h #include lauxlib.h #include lualib.h Gah. OK. So the patch I supplied will find LUA at configure time but not compile time. This needs some more thought. Oops! Confirmed. menuselect found it but make failed. I'll make the edits by hand and let you know how I fared - John Try this patch: http://asterisk.drunkcoder.com/patches/20090617__luafix.diff.txt Alas, the patch fails completely. The configure revision numbers look very different. I am using the 1.6.1.1 tarball. I copied the patch into the source directory (asterisk-1.6.1.1) and ran patch -p0 20090617__luafix.diff.txt. It was a long list of failed hunks. What next? Thanks - John The patch is actually derived from the current 1.6.1 SVN source, so any changes made since 1.6.1.1 was branched are the difference. Updated patch: http://asterisk.drunkcoder.com/patches/20090617__luafix__1.6.1.1.diff.txt The patch applied cleanly but Asterisk segfaulted on startup. I did not see anything particularly suspicious in the console output - mostly warnings and errors about realtime database connectivity that we have not yet setup other than this message: [Jun 17 17:47:24] WARNING[30682]: loader.c:375 load_dynamic_module: Error loading module 'app_directory.so': /usr/lib64/libc-client.so.1: undefined symbol: mm_dlog As much as I'd like, I don't think I have the code knowledge and I don't have the time on this project to step through it with a debugger. What next? Thanks - John The error above has zilch to do with pbx_lua, but rather with the compilation of app_directory against IMAP and the probable inability of your linker to find the correct IMAP libraries. You can prove this by adding 'noload = app_directory.so' to your modules.conf and restarting Asterisk. Yes, I didn't suspect it was related but tossed it in just in case. Nonetheless, it is clear (at least to me) that lua is causing the segfault. When I remove it, the segfault goes away. When I add it, the segfault returns. Thanks - John -- John A. Sullivan III Open Source Development Corporation +1 207-985-7880 jsulli...@opensourcedevel.com http://www.spiritualoutreach.com Making Christianity intelligible to secular society ___ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Installing LUA
Hello, all. The little bit of reading I've done on lua makes me eager to give it a try. However, when I try to install it (Asterisk 1.6.1.1 on CentOS 5.3), it is not available in menuselect. I have installed lua and lua-devel. I've seen very little about it in my Internet searches. What else must I do so that it installs? Thanks - John What do you see in the config.log in the asterisk source directory with respect to lua (say, the output of 'grep -i lua config.log)? - Brad ___ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Installing LUA
On Wed, 2009-06-17 at 07:49 -0400, Watkins, Bradley wrote: Hello, all. The little bit of reading I've done on lua makes me eager to give it a try. However, when I try to install it (Asterisk 1.6.1.1 on CentOS 5.3), it is not available in menuselect. I have installed lua and lua-devel. I've seen very little about it in my Internet searches. What else must I do so that it installs? Thanks - John What do you see in the config.log in the asterisk source directory with respect to lua (say, the output of 'grep -i lua config.log)? - Brad snip Thanks. I see: [compu...@pbx01 asterisk-1.6.1.0]$ grep -i lua config.log configure:42697: checking for luaL_newstate in -llua5.1 configure:42732: gcc -o conftest -g -O2 conftest.c -llua5.15 /usr/bin/ld: cannot find -llua5.1 | char luaL_newstate (); | return luaL_newstate (); ac_cv_lib_lua5_1_luaL_newstate=no LUA_DIR='' LUA_INCLUDE='' LUA_LIB='' PBX_LUA='0' When I check the installed version I see: [compu...@pbx01 asterisk-1.6.1.0]$ rpm -q lua lua-5.0.2-1.el5.rf I assume this is telling me CentOS installed 5.0.2 and Asterisk is looking for 5.1 - John -- John A. Sullivan III Open Source Development Corporation +1 207-985-7880 jsulli...@opensourcedevel.com http://www.spiritualoutreach.com Making Christianity intelligible to secular society ___ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Installing LUA
On Wednesday 17 June 2009 08:38:19 John A. Sullivan III wrote: On Wed, 2009-06-17 at 07:49 -0400, Watkins, Bradley wrote: Hello, all. The little bit of reading I've done on lua makes me eager to give it a try. However, when I try to install it (Asterisk 1.6.1.1 on CentOS 5.3), it is not available in menuselect. I have installed lua and lua-devel. I've seen very little about it in my Internet searches. What else must I do so that it installs? Thanks - John What do you see in the config.log in the asterisk source directory with respect to lua (say, the output of 'grep -i lua config.log)? - Brad snip Thanks. I see: [compu...@pbx01 asterisk-1.6.1.0]$ grep -i lua config.log configure:42697: checking for luaL_newstate in -llua5.1 configure:42732: gcc -o conftest -g -O2 conftest.c -llua5.15 /usr/bin/ld: cannot find -llua5.1 | char luaL_newstate (); | return luaL_newstate (); ac_cv_lib_lua5_1_luaL_newstate=no LUA_DIR='' LUA_INCLUDE='' LUA_LIB='' PBX_LUA='0' When I check the installed version I see: [compu...@pbx01 asterisk-1.6.1.0]$ rpm -q lua lua-5.0.2-1.el5.rf I assume this is telling me CentOS installed 5.0.2 and Asterisk is looking for 5.1 - John That is correct. The code for Lua uses certain features in the 5.1 version that aren't present in previous versions. -- Tilghman ___ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Installing LUA
On Wed, 2009-06-17 at 09:01 -0500, Tilghman Lesher wrote: On Wednesday 17 June 2009 08:38:19 John A. Sullivan III wrote: On Wed, 2009-06-17 at 07:49 -0400, Watkins, Bradley wrote: Hello, all. The little bit of reading I've done on lua makes me eager to give it a try. However, when I try to install it (Asterisk 1.6.1.1 on CentOS 5.3), it is not available in menuselect. I have installed lua and lua-devel. I've seen very little about it in my Internet searches. What else must I do so that it installs? Thanks - John What do you see in the config.log in the asterisk source directory with respect to lua (say, the output of 'grep -i lua config.log)? - Brad snip Thanks. I see: [compu...@pbx01 asterisk-1.6.1.0]$ grep -i lua config.log configure:42697: checking for luaL_newstate in -llua5.1 configure:42732: gcc -o conftest -g -O2 conftest.c -llua5.15 /usr/bin/ld: cannot find -llua5.1 | char luaL_newstate (); | return luaL_newstate (); ac_cv_lib_lua5_1_luaL_newstate=no LUA_DIR='' LUA_INCLUDE='' LUA_LIB='' PBX_LUA='0' When I check the installed version I see: [compu...@pbx01 asterisk-1.6.1.0]$ rpm -q lua lua-5.0.2-1.el5.rf I assume this is telling me CentOS installed 5.0.2 and Asterisk is looking for 5.1 - John That is correct. The code for Lua uses certain features in the 5.1 version that aren't present in previous versions. Hmm . . . to my great surprise, it is still not working: [compu...@pbx01 asterisk-1.6.1.1]$ grep -i lua config.log configure:42697: checking for luaL_newstate in -llua5.1 configure:42732: gcc -o conftest -g -O2 conftest.c -llua5.15 /usr/bin/ld: cannot find -llua5.1 | char luaL_newstate (); | return luaL_newstate (); ac_cv_lib_lua5_1_luaL_newstate=no LUA_DIR='' LUA_INCLUDE='' LUA_LIB='' PBX_LUA='0' Versions seem correct: lua-devel-5.1.2-1.el5.kb lua-5.1.2-1.el5.kb The files exist: [r...@pbx01 Asterisk]# locate lua /download/lua-5.1.2-1.el5.kb.x86_64.rpm /download/lua-devel-5.1.2-1.el5.kb.x86_64.rpm /etc/asterisk/extensions.lua /etc/joe/syntax/lua.jsf /home/compuser/Asterisk/asterisk-1.6.1.0/configs/extensions.lua.sample /home/compuser/Asterisk/asterisk-1.6.1.0/pbx/.pbx_lua.makeopts /home/compuser/Asterisk/asterisk-1.6.1.0/pbx/.pbx_lua.moduleinfo /home/compuser/Asterisk/asterisk-1.6.1.0/pbx/pbx_lua.c /home/compuser/Asterisk/asterisk-1.6.1.1/configs/extensions.lua.sample /home/compuser/Asterisk/asterisk-1.6.1.1/pbx/.pbx_lua.makeopts /home/compuser/Asterisk/asterisk-1.6.1.1/pbx/.pbx_lua.moduleinfo /home/compuser/Asterisk/asterisk-1.6.1.1/pbx/pbx_lua.c /sbin/mpath_prio_alua /sbin/mpath_prio_alua.static /usr/bin/lua /usr/bin/luac /usr/include/lua.h /usr/include/lua.hpp /usr/include/luaconf.h /usr/include/lualib.h /usr/lib64/liblua-5.1.so /usr/lib64/liblua.so /usr/lib64/pkgconfig/lua.pc /usr/share/doc/lua-5.1.2 /usr/share/doc/lua-5.1.2/COPYRIGHT /usr/share/doc/lua-5.1.2/HISTORY /usr/share/doc/lua-5.1.2/README /usr/share/doc/lua-5.1.2/amazon.gif /usr/share/doc/lua-5.1.2/contents.html /usr/share/doc/lua-5.1.2/cover.png /usr/share/doc/lua-5.1.2/logo.gif /usr/share/doc/lua-5.1.2/lua.css /usr/share/doc/lua-5.1.2/lua.html /usr/share/doc/lua-5.1.2/luac.html /usr/share/doc/lua-5.1.2/manual.css /usr/share/doc/lua-5.1.2/manual.html /usr/share/doc/lua-5.1.2/readme.html /usr/share/doc/postgresql-8.1.11/html/regress-evaluation.html /usr/share/doc/rpm-4.4.2.3/COPYRIGHT-lua /usr/share/locale/lua /usr/share/locale/lua/LC_MESSAGES /usr/share/man/man1/lua.1.gz /usr/share/man/man1/luac.1.gz /usr/share/man/man8/mpath_prio_alua.8.gz /usr/share/vim/vim70/ftplugin/lua.vim /usr/share/vim/vim70/indent/lua.vim /usr/share/vim/vim70/syntax/lua.vim If I run ./configure --with-lua=/usr/lib64, it fails: checking for mandatory modules: LUA... fail configure: *** configure: *** The LUA installation appears to be missing or broken. configure: *** Either correct the installation, or run configure configure: *** including --without-lua. Any idea what I am doing wrong? Thanks - John -- John A. Sullivan III Open Source Development Corporation +1 207-985-7880 jsulli...@opensourcedevel.com http://www.spiritualoutreach.com Making Christianity intelligible to secular society ___ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Installing LUA
In the makeopts file change LUA_INCLUDE= To LUA_INCLUDE=-I/usr/include And do make again. This should fix it. -Original Message- From: asterisk-users-boun...@lists.digium.com [mailto:asterisk-users-boun...@lists.digium.com] On Behalf Of John A. Sullivan III Sent: Wednesday, June 17, 2009 9:43 AM To: Asterisk Users Mailing List - Non-Commercial Discussion Subject: Re: [asterisk-users] Installing LUA On Wed, 2009-06-17 at 09:01 -0500, Tilghman Lesher wrote: On Wednesday 17 June 2009 08:38:19 John A. Sullivan III wrote: On Wed, 2009-06-17 at 07:49 -0400, Watkins, Bradley wrote: Hello, all. The little bit of reading I've done on lua makes me eager to give it a try. However, when I try to install it (Asterisk 1.6.1.1 on CentOS 5.3), it is not available in menuselect. I have installed lua and lua-devel. I've seen very little about it in my Internet searches. What else must I do so that it installs? Thanks - John What do you see in the config.log in the asterisk source directory with respect to lua (say, the output of 'grep -i lua config.log)? - Brad snip Thanks. I see: [compu...@pbx01 asterisk-1.6.1.0]$ grep -i lua config.log configure:42697: checking for luaL_newstate in -llua5.1 configure:42732: gcc -o conftest -g -O2 conftest.c -llua5.15 /usr/bin/ld: cannot find -llua5.1 | char luaL_newstate (); | return luaL_newstate (); ac_cv_lib_lua5_1_luaL_newstate=no LUA_DIR='' LUA_INCLUDE='' LUA_LIB='' PBX_LUA='0' When I check the installed version I see: [compu...@pbx01 asterisk-1.6.1.0]$ rpm -q lua lua-5.0.2-1.el5.rf I assume this is telling me CentOS installed 5.0.2 and Asterisk is looking for 5.1 - John That is correct. The code for Lua uses certain features in the 5.1 version that aren't present in previous versions. Hmm . . . to my great surprise, it is still not working: [compu...@pbx01 asterisk-1.6.1.1]$ grep -i lua config.log configure:42697: checking for luaL_newstate in -llua5.1 configure:42732: gcc -o conftest -g -O2 conftest.c -llua5.15 /usr/bin/ld: cannot find -llua5.1 | char luaL_newstate (); | return luaL_newstate (); ac_cv_lib_lua5_1_luaL_newstate=no LUA_DIR='' LUA_INCLUDE='' LUA_LIB='' PBX_LUA='0' Versions seem correct: lua-devel-5.1.2-1.el5.kb lua-5.1.2-1.el5.kb The files exist: [r...@pbx01 Asterisk]# locate lua /download/lua-5.1.2-1.el5.kb.x86_64.rpm /download/lua-devel-5.1.2-1.el5.kb.x86_64.rpm /etc/asterisk/extensions.lua /etc/joe/syntax/lua.jsf /home/compuser/Asterisk/asterisk-1.6.1.0/configs/extensions.lua.sample /home/compuser/Asterisk/asterisk-1.6.1.0/pbx/.pbx_lua.makeopts /home/compuser/Asterisk/asterisk-1.6.1.0/pbx/.pbx_lua.moduleinfo /home/compuser/Asterisk/asterisk-1.6.1.0/pbx/pbx_lua.c /home/compuser/Asterisk/asterisk-1.6.1.1/configs/extensions.lua.sample /home/compuser/Asterisk/asterisk-1.6.1.1/pbx/.pbx_lua.makeopts /home/compuser/Asterisk/asterisk-1.6.1.1/pbx/.pbx_lua.moduleinfo /home/compuser/Asterisk/asterisk-1.6.1.1/pbx/pbx_lua.c /sbin/mpath_prio_alua /sbin/mpath_prio_alua.static /usr/bin/lua /usr/bin/luac /usr/include/lua.h /usr/include/lua.hpp /usr/include/luaconf.h /usr/include/lualib.h /usr/lib64/liblua-5.1.so /usr/lib64/liblua.so /usr/lib64/pkgconfig/lua.pc /usr/share/doc/lua-5.1.2 /usr/share/doc/lua-5.1.2/COPYRIGHT /usr/share/doc/lua-5.1.2/HISTORY /usr/share/doc/lua-5.1.2/README /usr/share/doc/lua-5.1.2/amazon.gif /usr/share/doc/lua-5.1.2/contents.html /usr/share/doc/lua-5.1.2/cover.png /usr/share/doc/lua-5.1.2/logo.gif /usr/share/doc/lua-5.1.2/lua.css /usr/share/doc/lua-5.1.2/lua.html /usr/share/doc/lua-5.1.2/luac.html /usr/share/doc/lua-5.1.2/manual.css /usr/share/doc/lua-5.1.2/manual.html /usr/share/doc/lua-5.1.2/readme.html /usr/share/doc/postgresql-8.1.11/html/regress-evaluation.html /usr/share/doc/rpm-4.4.2.3/COPYRIGHT-lua /usr/share/locale/lua /usr/share/locale/lua/LC_MESSAGES /usr/share/man/man1/lua.1.gz /usr/share/man/man1/luac.1.gz /usr/share/man/man8/mpath_prio_alua.8.gz /usr/share/vim/vim70/ftplugin/lua.vim /usr/share/vim/vim70/indent/lua.vim /usr/share/vim/vim70/syntax/lua.vim If I run ./configure --with-lua=/usr/lib64, it fails: checking for mandatory modules: LUA... fail configure: *** configure: *** The LUA installation appears to be missing or broken. configure: *** Either correct the installation, or run configure configure: *** including --without-lua. Any idea what I am doing wrong? Thanks - John -- John A. Sullivan III Open Source Development Corporation +1 207-985-7880 jsulli...@opensourcedevel.com http://www.spiritualoutreach.com Making Christianity intelligible to secular society ___ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users ___ -- Bandwidth and Colocation Provided by http
Re: [asterisk-users] Installing LUA
On Wed, 2009-06-17 at 09:57 -0500, Danny Nicholas wrote: In the makeopts file change LUA_INCLUDE= To LUA_INCLUDE=-I/usr/include And do make again. This should fix it. snip Argh! alas it did not fix it: LUA_INCLUDE=-I/usr/include configure:42697: checking for luaL_newstate in -llua5.1 configure:42732: gcc -o conftest -g -O2 conftest.c -llua5.15 /usr/bin/ld: cannot find -llua5.1 | char luaL_newstate (); | return luaL_newstate (); ac_cv_lib_lua5_1_luaL_newstate=no LUA_DIR='' LUA_INCLUDE='' LUA_LIB='' PBX_LUA='0' Oops! I think I misunderstand you. Are you saying I will still not see it as an available option in make menuselect but it will compile in because I've manually edited the makeopts file? Thanks - John -- John A. Sullivan III Open Source Development Corporation +1 207-985-7880 jsulli...@opensourcedevel.com http://www.spiritualoutreach.com Making Christianity intelligible to secular society ___ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Installing LUA
John A. Sullivan III wrote: Argh! alas it did not fix it: Looks like a problem with how the various distros are packaging and installing it. I've created a patch to configure that should find it on your system, give it a whirl: $ cd path/to/asterisk-src/ $ wget -O - http://pastebin.ca/raw/1463560; | patch -p0 $ ./configure $ make menuselect Let me know if that works for you. -- Sean Bright sean.bri...@gmail.com ___ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Installing LUA
On Wed, 2009-06-17 at 11:42 -0400, Sean Bright wrote: John A. Sullivan III wrote: Argh! alas it did not fix it: Looks like a problem with how the various distros are packaging and installing it. I've created a patch to configure that should find it on your system, give it a whirl: $ cd path/to/asterisk-src/ $ wget -O - http://pastebin.ca/raw/1463560; | patch -p0 $ ./configure $ make menuselect Let me know if that works for you. Wow! Definitely a non-trivial patch. Alas, it does not work but the errors are different: [compu...@pbx01 asterisk-1.6.1.1]$ grep -i lua config.log configure:42697: checking for luaL_newstate in -llua5.1 configure:42732: gcc -o conftest -g -O2 conftest.c -llua5.15 /usr/bin/ld: cannot find -llua5.1 | char luaL_newstate (); | return luaL_newstate (); configure:42960: checking for luaL_newstate in -llua-5.1 configure:42995: gcc -o conftest -g -O2 conftest.c -llua-5.15 /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblua-5.1.so: undefined reference to `sqrt' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblua-5.1.so: undefined reference to `floor' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblua-5.1.so: undefined reference to `ceil' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblua-5.1.so: undefined reference to `cosh' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblua-5.1.so: undefined reference to `tan' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblua-5.1.so: undefined reference to `tanh' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblua-5.1.so: undefined reference to `asin' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblua-5.1.so: undefined reference to `log' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblua-5.1.so: undefined reference to `atan' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblua-5.1.so: undefined reference to `sinh' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblua-5.1.so: undefined reference to `fmod' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblua-5.1.so: undefined reference to `acos' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblua-5.1.so: undefined reference to `exp' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblua-5.1.so: undefined reference to `sin' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblua-5.1.so: undefined reference to `pow' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblua-5.1.so: undefined reference to `atan2' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblua-5.1.so: undefined reference to `cos' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblua-5.1.so: undefined reference to `log10' | char luaL_newstate (); | return luaL_newstate (); ac_cv_lib_lua5_1_luaL_newstate=no ac_cv_lib_lua_5_1_luaL_newstate=no LUA_DIR='' LUA_INCLUDE='' LUA_LIB='' PBX_LUA='0' I'm guessing there are differences in the API between what CentOS has installed (well actually the testing RPM I found to upgrade to 5.1 from 5.0) and what * expects. Given that, I would imagine it is not safe to manually edit makeopts. Thoughts? Comments? Insults? Thanks - John -- John A. Sullivan III Open Source Development Corporation +1 207-985-7880 jsulli...@opensourcedevel.com http://www.spiritualoutreach.com Making Christianity intelligible to secular society ___ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Installing LUA
Wow! Definitely a non-trivial patch. Alas, it does not work but the errors are different: [compu...@pbx01 asterisk-1.6.1.1]$ grep -i lua config.log configure:42697: checking for luaL_newstate in -llua5.1 configure:42732: gcc -o conftest -g -O2 conftest.c -llua5.15 /usr/bin/ld: cannot find -llua5.1 | char luaL_newstate (); | return luaL_newstate (); configure:42960: checking for luaL_newstate in -llua-5.1 configure:42995: gcc -o conftest -g -O2 conftest.c -llua-5.15 /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblu a-5.1.so: undefined reference to `sqrt' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblu a-5.1.so: undefined reference to `floor' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblu a-5.1.so: undefined reference to `ceil' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblu a-5.1.so: undefined reference to `cosh' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblu a-5.1.so: undefined reference to `tan' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblu a-5.1.so: undefined reference to `tanh' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblu a-5.1.so: undefined reference to `asin' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblu a-5.1.so: undefined reference to `log' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblu a-5.1.so: undefined reference to `atan' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblu a-5.1.so: undefined reference to `sinh' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblu a-5.1.so: undefined reference to `fmod' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblu a-5.1.so: undefined reference to `acos' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblu a-5.1.so: undefined reference to `exp' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblu a-5.1.so: undefined reference to `sin' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblu a-5.1.so: undefined reference to `pow' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblu a-5.1.so: undefined reference to `atan2' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblu a-5.1.so: undefined reference to `cos' /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../lib64/liblu a-5.1.so: undefined reference to `log10' | char luaL_newstate (); | return luaL_newstate (); ac_cv_lib_lua5_1_luaL_newstate=no ac_cv_lib_lua_5_1_luaL_newstate=no LUA_DIR='' LUA_INCLUDE='' LUA_LIB='' PBX_LUA='0' I'm guessing there are differences in the API between what CentOS has installed (well actually the testing RPM I found to upgrade to 5.1 from 5.0) and what * expects. Given that, I would imagine it is not safe to manually edit makeopts. Thoughts? Comments? Insults? Thanks - John -- My guess is that when running the compile test ( This line: 'configure:42995: gcc -o conftest -g -O2 conftest.c -llua-5.15' ) it is necessary to add '-lm' in order to link in the standard math library. - Brad ___ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Installing LUA
My guess is that when running the compile test ( This line: 'configure:42995: gcc -o conftest -g -O2 conftest.c -llua-5.15' ) it is necessary to add '-lm' in order to link in the standard math library. - Brad One more bit of magic necessary here, as pbx/pbx_lua.c has includes for: #include lua5.1/lua.h #include lua5.1/lauxlib.h #include lua5.1/lualib.h On Redhat-based systems, it needs to be: #include lua.h #include lauxlib.h #include lualib.h ___ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Installing LUA
John A. Sullivan III wrote: Wow! Definitely a non-trivial patch. Alas, it does not work but the errors are different: I've updated the patch to take into account your feedback as well as Bradley's. You'll need to revert the previous patch (this will probably involve unrolling a fresh 1.6.1.1 tarball (or if you have pulled from SVN just do an 'svn revert configur*')). $ cd path/to/asterisk/src $ wget -O - http://pastebin.ca/raw/1463619; | patch -p0 $ ./configure $ make menuselect Let me know. -- Sean Bright sean.bri...@gmail.com ___ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Installing LUA
Watkins, Bradley wrote: One more bit of magic necessary here, as pbx/pbx_lua.c has includes for: #include lua5.1/lua.h #include lua5.1/lauxlib.h #include lua5.1/lualib.h On Redhat-based systems, it needs to be: #include lua.h #include lauxlib.h #include lualib.h Gah. OK. So the patch I supplied will find LUA at configure time but not compile time. This needs some more thought. -- Sean Bright sean.bri...@gmail.com ___ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Installing LUA
On Wed, 2009-06-17 at 12:37 -0400, Sean Bright wrote: John A. Sullivan III wrote: Wow! Definitely a non-trivial patch. Alas, it does not work but the errors are different: I've updated the patch to take into account your feedback as well as Bradley's. You'll need to revert the previous patch (this will probably involve unrolling a fresh 1.6.1.1 tarball (or if you have pulled from SVN just do an 'svn revert configur*')). $ cd path/to/asterisk/src $ wget -O - http://pastebin.ca/raw/1463619; | patch -p0 $ ./configure $ make menuselect Let me know. That did the trick! Now I need to figure out how to get speex working. That will be the next email to keep the threads separate. Thanks, all. The beauty of open source is revealed again! - John -- John A. Sullivan III Open Source Development Corporation +1 207-985-7880 jsulli...@opensourcedevel.com http://www.spiritualoutreach.com Making Christianity intelligible to secular society ___ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Installing LUA
On Wed, 2009-06-17 at 12:44 -0400, Sean Bright wrote: Watkins, Bradley wrote: One more bit of magic necessary here, as pbx/pbx_lua.c has includes for: #include lua5.1/lua.h #include lua5.1/lauxlib.h #include lua5.1/lualib.h On Redhat-based systems, it needs to be: #include lua.h #include lauxlib.h #include lualib.h Gah. OK. So the patch I supplied will find LUA at configure time but not compile time. This needs some more thought. Oops! Confirmed. menuselect found it but make failed. I'll make the edits by hand and let you know how I fared - John -- John A. Sullivan III Open Source Development Corporation +1 207-985-7880 jsulli...@opensourcedevel.com http://www.spiritualoutreach.com Making Christianity intelligible to secular society ___ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Installing LUA
On Wed, 2009-06-17 at 12:56 -0400, John A. Sullivan III wrote: On Wed, 2009-06-17 at 12:44 -0400, Sean Bright wrote: Watkins, Bradley wrote: One more bit of magic necessary here, as pbx/pbx_lua.c has includes for: #include lua5.1/lua.h #include lua5.1/lauxlib.h #include lua5.1/lualib.h On Redhat-based systems, it needs to be: #include lua.h #include lauxlib.h #include lualib.h Gah. OK. So the patch I supplied will find LUA at configure time but not compile time. This needs some more thought. Oops! Confirmed. menuselect found it but make failed. I'll make the edits by hand and let you know how I fared - John That worked. The system is still in enough of a test phase that I can destroy it again and rebuild it if you'd like to send me a new version of the patch. Thanks - John -- John A. Sullivan III Open Source Development Corporation +1 207-985-7880 jsulli...@opensourcedevel.com http://www.spiritualoutreach.com Making Christianity intelligible to secular society ___ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Installing LUA
On Wed, 2009-06-17 at 13:05 -0400, John A. Sullivan III wrote: On Wed, 2009-06-17 at 12:56 -0400, John A. Sullivan III wrote: On Wed, 2009-06-17 at 12:44 -0400, Sean Bright wrote: Watkins, Bradley wrote: One more bit of magic necessary here, as pbx/pbx_lua.c has includes for: #include lua5.1/lua.h #include lua5.1/lauxlib.h #include lua5.1/lualib.h On Redhat-based systems, it needs to be: #include lua.h #include lauxlib.h #include lualib.h Gah. OK. So the patch I supplied will find LUA at configure time but not compile time. This needs some more thought. Oops! Confirmed. menuselect found it but make failed. I'll make the edits by hand and let you know how I fared - John That worked. The system is still in enough of a test phase that I can destroy it again and rebuild it if you'd like to send me a new version of the patch. Thanks - John ARGH Not so good. Asterisk now segfaults on start up :((( - John -- John A. Sullivan III Open Source Development Corporation +1 207-985-7880 jsulli...@opensourcedevel.com http://www.spiritualoutreach.com Making Christianity intelligible to secular society ___ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Installing LUA
That worked. The system is still in enough of a test phase that I can destroy it again and rebuild it if you'd like to send me a new version of the patch. Thanks - John ARGH Not so good. Asterisk now segfaults on start up :((( - John Now that is a behavior I'm not seeing, although to be fair I'm using Fedora 9 to compile/test and not CentOS. - Brad ___ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Installing LUA
On Wednesday 17 June 2009 11:56:28 John A. Sullivan III wrote: On Wed, 2009-06-17 at 12:44 -0400, Sean Bright wrote: Watkins, Bradley wrote: One more bit of magic necessary here, as pbx/pbx_lua.c has includes for: #include lua5.1/lua.h #include lua5.1/lauxlib.h #include lua5.1/lualib.h On Redhat-based systems, it needs to be: #include lua.h #include lauxlib.h #include lualib.h Gah. OK. So the patch I supplied will find LUA at configure time but not compile time. This needs some more thought. Oops! Confirmed. menuselect found it but make failed. I'll make the edits by hand and let you know how I fared - John Try this patch: http://asterisk.drunkcoder.com/patches/20090617__luafix.diff.txt -- Tilghman ___ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Installing LUA
On Wed, 2009-06-17 at 14:18 -0500, Tilghman Lesher wrote: On Wednesday 17 June 2009 11:56:28 John A. Sullivan III wrote: On Wed, 2009-06-17 at 12:44 -0400, Sean Bright wrote: Watkins, Bradley wrote: One more bit of magic necessary here, as pbx/pbx_lua.c has includes for: #include lua5.1/lua.h #include lua5.1/lauxlib.h #include lua5.1/lualib.h On Redhat-based systems, it needs to be: #include lua.h #include lauxlib.h #include lualib.h Gah. OK. So the patch I supplied will find LUA at configure time but not compile time. This needs some more thought. Oops! Confirmed. menuselect found it but make failed. I'll make the edits by hand and let you know how I fared - John Try this patch: http://asterisk.drunkcoder.com/patches/20090617__luafix.diff.txt Alas, the patch fails completely. The configure revision numbers look very different. I am using the 1.6.1.1 tarball. I copied the patch into the source directory (asterisk-1.6.1.1) and ran patch -p0 20090617__luafix.diff.txt. It was a long list of failed hunks. What next? Thanks - John -- John A. Sullivan III Open Source Development Corporation +1 207-985-7880 jsulli...@opensourcedevel.com http://www.spiritualoutreach.com Making Christianity intelligible to secular society ___ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Installing LUA
On Wednesday 17 June 2009 14:55:55 John A. Sullivan III wrote: On Wed, 2009-06-17 at 14:18 -0500, Tilghman Lesher wrote: On Wednesday 17 June 2009 11:56:28 John A. Sullivan III wrote: On Wed, 2009-06-17 at 12:44 -0400, Sean Bright wrote: Watkins, Bradley wrote: One more bit of magic necessary here, as pbx/pbx_lua.c has includes for: #include lua5.1/lua.h #include lua5.1/lauxlib.h #include lua5.1/lualib.h On Redhat-based systems, it needs to be: #include lua.h #include lauxlib.h #include lualib.h Gah. OK. So the patch I supplied will find LUA at configure time but not compile time. This needs some more thought. Oops! Confirmed. menuselect found it but make failed. I'll make the edits by hand and let you know how I fared - John Try this patch: http://asterisk.drunkcoder.com/patches/20090617__luafix.diff.txt Alas, the patch fails completely. The configure revision numbers look very different. I am using the 1.6.1.1 tarball. I copied the patch into the source directory (asterisk-1.6.1.1) and ran patch -p0 20090617__luafix.diff.txt. It was a long list of failed hunks. What next? Thanks - John The patch is actually derived from the current 1.6.1 SVN source, so any changes made since 1.6.1.1 was branched are the difference. Updated patch: http://asterisk.drunkcoder.com/patches/20090617__luafix__1.6.1.1.diff.txt -- Tilghman ___ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users
Re: [asterisk-users] Installing LUA
On Wed, 2009-06-17 at 15:43 -0500, Tilghman Lesher wrote: On Wednesday 17 June 2009 14:55:55 John A. Sullivan III wrote: On Wed, 2009-06-17 at 14:18 -0500, Tilghman Lesher wrote: On Wednesday 17 June 2009 11:56:28 John A. Sullivan III wrote: On Wed, 2009-06-17 at 12:44 -0400, Sean Bright wrote: Watkins, Bradley wrote: One more bit of magic necessary here, as pbx/pbx_lua.c has includes for: #include lua5.1/lua.h #include lua5.1/lauxlib.h #include lua5.1/lualib.h On Redhat-based systems, it needs to be: #include lua.h #include lauxlib.h #include lualib.h Gah. OK. So the patch I supplied will find LUA at configure time but not compile time. This needs some more thought. Oops! Confirmed. menuselect found it but make failed. I'll make the edits by hand and let you know how I fared - John Try this patch: http://asterisk.drunkcoder.com/patches/20090617__luafix.diff.txt Alas, the patch fails completely. The configure revision numbers look very different. I am using the 1.6.1.1 tarball. I copied the patch into the source directory (asterisk-1.6.1.1) and ran patch -p0 20090617__luafix.diff.txt. It was a long list of failed hunks. What next? Thanks - John The patch is actually derived from the current 1.6.1 SVN source, so any changes made since 1.6.1.1 was branched are the difference. Updated patch: http://asterisk.drunkcoder.com/patches/20090617__luafix__1.6.1.1.diff.txt The patch applied cleanly but Asterisk segfaulted on startup. I did not see anything particularly suspicious in the console output - mostly warnings and errors about realtime database connectivity that we have not yet setup other than this message: [Jun 17 17:47:24] WARNING[30682]: loader.c:375 load_dynamic_module: Error loading module 'app_directory.so': /usr/lib64/libc-client.so.1: undefined symbol: mm_dlog As much as I'd like, I don't think I have the code knowledge and I don't have the time on this project to step through it with a debugger. What next? Thanks - John -- John A. Sullivan III Open Source Development Corporation +1 207-985-7880 jsulli...@opensourcedevel.com http://www.spiritualoutreach.com Making Christianity intelligible to secular society ___ -- Bandwidth and Colocation Provided by http://www.api-digital.com -- asterisk-users mailing list To UNSUBSCRIBE or update options visit: http://lists.digium.com/mailman/listinfo/asterisk-users