IT IS HERE! Get Smashing Node.JS on Amazon Kindle today!
Show Posts
← Back to homepage

Open up terminal. Copy the link of the latest Lua version and download it:

cd /tmp

Extract and compile:

tar -xzvf lua-5.1.4.tar.gz
cd lua-5.1.4
make macosx

Test and install (if test goes through)

make test
sudo make install

And you’re done!


Name said

shit ain’t workin’

NormB said

wget isn’t installed on leopard by default.

Found this little tidbit:

echo ‘alias wget=”curl -O”‘ >> ~/.bash_profile

Worked for me

Tofu said

Thank you worked perfectly! (I had wget already from darwinports)

luk said

Thank you very much! It worked great!

Natsuki said

Thanks very much .it works well ,
the problem is that textmate doesn’t hava a lua highlight support built-in ,
anyhow I’ll fix it

Walker said

Worked wonderfully. Thank you!

Julien said

Thanks for this! To the point. Works perfectly

Andru said

I’m new to Mac.I have installed this. But I dont know how to open it. Can you please help me

iksnae said

Thank you so much!

iksnae said

thank you!

Jeronimo said

I’ve found a lot of complicated ways to do install Lua on Mac and the simplest and most obvious worked at the first attempt. Good post !

LUA-kather said

 Worked perfectly! thanks a bunch…
For newbies:
– To download the Lua distribution without using wget, do this:
    1) click the link to the lua distribution in Safar; this will download the tarfile to your Downloads folder
    2) Open the Downloads folder in the Finder and look for the lua-5.1.4.tar file
    3) In your terminal window, type the following:
        cd /tmp
       Now press the Enter key.
   4) In your terminal window, do the following:
       type cp but do not press enter
      drag the lua-5.1.4.tar file from the Downloads folder to the Terminal window; this will automatically enter the full pathname to that file into your command line. Don’t press Enter yet.
     Type a space and then a period into the same command line.
     Your command should look like this:
    cp .
5) NOW press Enter. Terminal copies the Lua tarfile to your /tmp folder.

6) continue from the “Extract and compile” step above.



– if you get the message that make isnt found, install Xcode Mac OS developer tools from your OS X install disk

    LUA-kather said

    Couple more tips: this procedure works on Tiger too, but the Lua distribution gets downloaded to your desktop instead of to a /Downloads folder

    Make sure you get a .tar.gz file or you’ll have to change the tar options to unpack the file successfully

sammy said

Took a while but I eventually figured it out from this. Thanks!

Timber said

Worked very nice!!!

Sanjayb said

Awesome!  Thank you for making this available.

Sexman said

I can’t get it and it is stupid! someone help

OsNeCa said

you need to install the developer kit before install Lua, you can try installing xcode!!!!

OraNoh said

Worked fine – thanks´s

topnotch374 said

I’m clueless about this and need help installing lua to Mac OS Lion.


gaborzsazsak said

Please tell me where I can find the installed LUA, to set this path for IntelliJ. Cheers, Gabor

bobo said

Thanks!!! works perferctly!

singmelody said

Thanks .

Rob said

If you get errors at the “make” command, you need to install xcode. If you are using Lion or Mountain Lion, the new version of xcode does not automatically install the developer tools. To install, go into xcode –> Preferences –> Downloads and click Install next to the Command Line Tools. This installs “make” and allows you to use this command. Follow instructions as above to install Lua.

Sebastian said

heres a good way to get wget:

Your thoughts?

About Guillermo Rauch:

CTO and co-founder of LearnBoost / Cloudup (acquired by Automattic in 2013). Argentine living in SF.