Lua is an embeddable scripting language. If you are trying to embed it in PHP follow this instructions that may help you:

$ sudo apt-get install phpize liblua5.1-0-dev 
$ git clone git://repo.or.cz/phplua.git src
$ cd src/
$ phpize
$ ./configure

At this point you are almost done, BUT please edit the file Makefile and change the line:

LUA_SHARED_LIBADD = -llua

by:

LUA_SHARED_LIBADD = -llua5.1

Then is time to finish cooking:

$ make
$ sudo make install

Almost done, do a test:

$ make tests #all will fail, that is fine by now
$ php tests/001.php #this one works, read the source to confirm ;)

Blessings