
in in lua-5.1/Makefile and lua-5.1/src/Makefile add macosx_ub to PLATS:
PLATS= aix ansi bsd generic linux macosx macosx_ub mingw posix solaris
in lua-5.1/src/Makefile add macosx_ub build optionmacosx_ub:
$(MAKE) all MYCFLAGS=”-DLUA_USE_MACOSX -isysroot /Developer/SDKs/MacOSX10.5.sdk -mmacosx-version-min=10.5 -arch ppc -arch i386” “MYLDFLAGS=-Wl,-syslibroot,/Developer/SDKs/MacOSX10.5.sdk -arch ppc -arch i386 -mmacosx-version-min=10.5”
in lua-5.1
make macosx_ub
I had some troubles linking my projects to lua saying: file is not of required architecture.
Solution via, thanks, http://soledadpenades.com/2008/05/19/lua-universal-binary/