Murga-Projects Forums

Full Version: MacOS builds - Volunteer needed
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi,

The last time I had a MacOS binary was for version 0.1, it would be nice if someone could test the new build procedure on MacOS and provide me with a binary ...

Anyone up for the challenge ?

Cheers
JohnM
iGame3D reporting for duty, tell me what I need to do.

iGame3D Wrote:
iGame3D reporting for duty, tell me what I need to do.


The sequence goes something like this ...

Download the dependencies from here :

http://www.murga-projects.com/murgaLua/files/

And extract them to a working directory along with murgaLua.

First we build lua

Code:
cd lua-5.*/
make ansi
make install
cd ..


Followed by sqLite

Code:
cd sqlite-3.*/
./configure
make
make install
cd ..


The final dependency is Fltk

Code:
cd fltk-1.1*
# --enable-xft (For linux)
./configure --disable-gl --enable-localjpeg --enable-localzlib --enable-localpng
make
make install


But we also want a working copy of fluid for GUI generation

Quote:
cp fluid/fluid ../murgaLua/bin/MacOs-Intel
cd ..
cd murgaLua
strip bin/MacOs-Intel/fluid


If there is a MacOS upx equivalent it would be nice to do something like

upx --lzma bin/MacOs-Intel/fluid

But assuming there isn't we next build murgaLua

Quote:
make macos
cd bin
mv murgaLua MacOS


That should be about it ! :-)

I get to here and I think think something is wrong.
I should have a murguLua executable yes?
On Intel iMac I am only getting Fluid.

Code:
sh-2.05b# strip bin/MacOs-Intel/fluid
sh-2.05b# upx --lzma bin/MacOs-Intel/fluid
sh: upx: command not found
sh-2.05b# make macos
cd src && make macos
sh ../tools/embedLuaSocket.sh
sh ../tools/embedMurgaLuaLib.sh
make ../bin/murgaLua PLAT=macos
[compiling bind-fltk-ext.cxx]
g++ -fomit-frame-pointer -ffast-math -Os -fexpensive-optimizations -g `fltk-config --use-images --use-forms --cxxflags` -DLUA -Dmacos -c bind-fltk-ext.cxx -o bind-fltk-ext.o
In file included from bind-fltk-ext.cxx:24:
fltk.cxx:24:20: error: malloc.h: No such file or directory
bind-fltk.cxx: In function 'int lua_call1_fl_ask(lua_State*)':
bind-fltk.cxx:8940: warning: 'fl_ask' is deprecated (declared at /usr/local/include/FL/fl_ask.H:59)
bind-fltk.cxx:8940: warning: 'fl_ask' is deprecated (declared at /usr/local/include/FL/fl_ask.H:59)
make[2]: *** [bind-fltk-ext.o] Error 1
make[1]: *** [macos] Error 2
make: *** [macos] Error 2


What to do?

iGame3D Wrote:
I get to here and I think think something is wrong.
I should have a murguLua executable yes?
On Intel iMac I am only getting Fluid.

Code:
sh-2.05b# strip bin/MacOs-Intel/fluid
sh-2.05b# upx --lzma bin/MacOs-Intel/fluid
sh: upx: command not found
sh-2.05b# make macos
cd src && make macos
sh ../tools/embedLuaSocket.sh
sh ../tools/embedMurgaLuaLib.sh
make ../bin/murgaLua PLAT=macos
[compiling bind-fltk-ext.cxx]
g++ -fomit-frame-pointer -ffast-math -Os -fexpensive-optimizations -g `fltk-config --use-images --use-forms --cxxflags` -DLUA -Dmacos -c bind-fltk-ext.cxx -o bind-fltk-ext.o
In file included from bind-fltk-ext.cxx:24:
fltk.cxx:24:20: error: malloc.h: No such file or directory
bind-fltk.cxx: In function 'int lua_call1_fl_ask(lua_State*)':
bind-fltk.cxx:8940: warning: 'fl_ask' is deprecated (declared at /usr/local/include/FL/fl_ask.H:59)
bind-fltk.cxx:8940: warning: 'fl_ask' is deprecated (declared at /usr/local/include/FL/fl_ask.H:59)
make[2]: *** [bind-fltk-ext.o] Error 1
make[1]: *** [macos] Error 2
make: *** [macos] Error 2


What to do?


I am building murgaLua on a PPC iBook and get the exact same errors. I was looking to see if I missed something, but I have not found it yet. Fluid, SQLite, and Lua all seem to work. I did get an error while compiling FLUID. The "test" program errored out and quit while it was compiling.

OK ...

Sorry I have been away for a few days.

I think I had this one before ...

Try opening up "murgaLua/src/fltk.cxx" and replacing :

#include <malloc.h>

With :

#include <stdlib.h>

If that doesn't work then try replacing it with :

#include <sys/malloc.h>

Cheers
JohnM
Well I tried both of those and they both produce the same NEW error.

Code:
make macos
cd src && make macos
sh ../tools/embedLuaSocket.sh
sh ../tools/embedMurgaLuaLib.sh
make ../bin/murgaLua PLAT=macos
[compiling murgaLua.cxx]
g++ -fomit-frame-pointer -ffast-math -Os -fexpensive-optimizations -g `fltk-config --use-images --use-forms --cxxflags` -DLUA -Dmacos -c murgaLua.cxx -o murgaLua.o
In file included from murgaLua.cxx:23:
../3rd-party/lsqlite3-5/lsqlite3.c: In function `int dbvm_get_name(lua_State*)
   ':
../3rd-party/lsqlite3-5/lsqlite3.c:311: warning: initialization to `int' from `
   lua_Number'
../3rd-party/lsqlite3-5/lsqlite3.c:311: warning: argument to `int' from `
   lua_Number'
../3rd-party/lsqlite3-5/lsqlite3.c: In function `int dbvm_get_type(lua_State*)
   ':
../3rd-party/lsqlite3-5/lsqlite3.c:319: warning: initialization to `int' from `
   lua_Number'
../3rd-party/lsqlite3-5/lsqlite3.c:319: warning: argument to `int' from `
   lua_Number'
../3rd-party/lsqlite3-5/lsqlite3.c: In function `int
   dbvm_bind_parameter_name(lua_State*)':
../3rd-party/lsqlite3-5/lsqlite3.c:469: warning: initialization to `int' from `
   lua_Number'
../3rd-party/lsqlite3-5/lsqlite3.c:469: warning: argument to `int' from `
   lua_Number'
../3rd-party/lsqlite3-5/lsqlite3.c: In function `int db_exec_callback(void*,
   int, char**, char**)':
../3rd-party/lsqlite3-5/lsqlite3.c:1335: warning: assignment to `int' from `
   lua_Number'
../3rd-party/lsqlite3-5/lsqlite3.c:1335: warning: argument to `int' from `
   lua_Number'
murgaLua.cxx: At global scope:
murgaLua.cxx:33: error: parse error before numeric constant
make[2]: *** [murgaLua.o] Error 1
make[1]: *** [macos] Error 2
make: *** [macos] Error 2

using stdlib.h builds until ...

Code:
...
strip ../bin/murgaLua
../tools/upx --lzma ../bin/murgaLua
../tools/upx: ../tools/upx: cannot execute binary file
make[1]: *** [macos] Error 126
make: *** [macos] Error 2


using sys/malloc

Code:
make macos
cd src && make macos
sh ../tools/embedLuaSocket.sh
sh ../tools/embedMurgaLuaLib.sh
make ../bin/murgaLua PLAT=macos
make[2]: `../bin/murgaLua' is up to date.
strip ../bin/murgaLua
../tools/upx --lzma ../bin/murgaLua
../tools/upx: ../tools/upx: cannot execute binary file
make[1]: *** [macos] Error 126
make: *** [macos] Error 2


intelimac

Well what do you know, I got it to build
Why is the final build file called "MacOS" at the mv Murglua MacOS line?

iGame3D Wrote:
using stdlib.h builds until ...

Code:
...
strip ../bin/murgaLua
../tools/upx --lzma ../bin/murgaLua
../tools/upx: ../tools/upx: cannot execute binary file
make[1]: *** [macos] Error 126
make: *** [macos] Error 2


OK, that actually built ... It's just that the UPX line is being executed
by the build file (which it shouldn't).

But you'd have the murgaLua executable (uncompressed).

The second attempt (using sys/malloc), didn't actually create a new executable ... So did you try running the examples with this executable ?

iGame3D Wrote:
Well what do you know, I got it to build
Why is the final build file called "MacOS" at the mv Murglua MacOS line?


Err, I am not sure what you mean :-)

Cheers
JohnM

when I executed in terminal

Code:
mv murgaLua MacOS


the murgaLua application was renamed to "MacOS"

Code:
mv murgaLua MacOs-Intel

I believe corrects this problem?

Ok I am a noob.

I got this thing running. Examples work.

Going to run through the process again, see what I do wrong this time. ;-)

Pages: 1 2
Reference URL's