Lua -- MacOS上安装lua
2016-03-09 13:13
561 查看
1.在Mac OS的终端上查询本机是否已经安装了lua或者安装成功了lua
没有安装:
安装成功:
我安装的是5.3.2的版本的。
2.如果没有安装的话去官网下载一个最新的tar.gz格式的代码吧
http://www.lua.org/download.html
3.我的tar.gz文件在download目录下:
在终端输入:tar xzvf lua-5.3.2.tar 解压
进入lua-5.3.2,可以看到如下文件
然后安装lua,在终端中输入命令
执行第一步查看,恭喜你已经安装成了。
没有安装:
happyelements@happyelementsdeMac-mini ~$ lua -bash: lua: command not found
安装成功:
happyelements@happyelementsdeMac-mini /$ lua Lua 5.3.2 Copyright (C) 1994-2015 Lua.org, PUC-Rio >
我安装的是5.3.2的版本的。
2.如果没有安装的话去官网下载一个最新的tar.gz格式的代码吧
http://www.lua.org/download.html
3.我的tar.gz文件在download目录下:
在终端输入:tar xzvf lua-5.3.2.tar 解压
happyelements@happyelementsdeMac-mini ~$ cd /Users/happyelements/Downloads happyelements@happyelementsdeMac-mini Downloads$ tar xzvf lua-5.3.2.tar x lua-5.3.2/ x lua-5.3.2/src/ x lua-5.3.2/src/liolib.c x lua-5.3.2/src/lctype.h x lua-5.3.2/src/ltm.h x lua-5.3.2/src/ldump.c x lua-5.3.2/src/lobject.h x lua-5.3.2/src/lopcodes.h x lua-5.3.2/src/luac.c x lua-5.3.2/src/lbitlib.c x lua-5.3.2/src/llimits.h x lua-5.3.2/src/luaconf.h x lua-5.3.2/src/lgc.h x lua-5.3.2/src/lauxlib.c x lua-5.3.2/src/lstate.h x lua-5.3.2/src/llex.c x lua-5.3.2/src/ldblib.c x lua-5.3.2/src/lcode.h x lua-5.3.2/src/lstate.c x lua-5.3.2/src/lua.c x lua-5.3.2/src/lzio.c x lua-5.3.2/src/lcode.c x lua-5.3.2/src/llex.h x lua-5.3.2/src/lparser.c x lua-5.3.2/src/linit.c x lua-5.3.2/src/ldebug.h x lua-5.3.2/src/lcorolib.c x lua-5.3.2/src/lbaselib.c x lua-5.3.2/src/ldebug.c x lua-5.3.2/src/lutf8lib.c x lua-5.3.2/src/lapi.c x lua-5.3.2/src/lua.h x lua-5.3.2/src/lauxlib.h x lua-5.3.2/src/lobject.c x lua-5.3.2/src/lstrlib.c x lua-5.3.2/src/ltm.c x lua-5.3.2/src/ltablib.c x lua-5.3.2/src/lualib.h x lua-5.3.2/src/lfunc.h x lua-5.3.2/src/ldo.c x lua-5.3.2/src/lfunc.c x lua-5.3.2/src/lctype.c x lua-5.3.2/src/lvm.c x lua-5.3.2/src/loadlib.c x lua-5.3.2/src/ltable.h x lua-5.3.2/src/lstring.h x lua-5.3.2/src/ltable.c x lua-5.3.2/src/lua.hpp x lua-5.3.2/src/lopcodes.c x lua-5.3.2/src/lapi.h x lua-5.3.2/src/lparser.h x lua-5.3.2/src/Makefile x lua-5.3.2/src/lundump.c x lua-5.3.2/src/lmem.h x lua-5.3.2/src/lundump.h x lua-5.3.2/src/lprefix.h x lua-5.3.2/src/lstring.c x lua-5.3.2/src/lmathlib.c x lua-5.3.2/src/lvm.h x lua-5.3.2/src/lgc.c x lua-5.3.2/src/ldo.h x lua-5.3.2/src/lzio.h x lua-5.3.2/src/loslib.c x lua-5.3.2/src/lmem.c x lua-5.3.2/README x lua-5.3.2/doc/ x lua-5.3.2/doc/luac.1 x lua-5.3.2/doc/osi-certified-72x60.png x lua-5.3.2/doc/manual.css x lua-5.3.2/doc/readme.html x lua-5.3.2/doc/logo.gif x lua-5.3.2/doc/index.css x lua-5.3.2/doc/contents.html x lua-5.3.2/doc/manual.html x lua-5.3.2/doc/lua.1 x lua-5.3.2/doc/lua.css x lua-5.3.2/Makefile
进入lua-5.3.2,可以看到如下文件
happyelements@happyelementsdeMac-mini Downloads$ cd lua-5.3.2 happyelements@happyelementsdeMac-mini lua-5.3.2$ ls Makefile README doc src
然后安装lua,在终端中输入命令
make macosx sudo make install
执行第一步查看,恭喜你已经安装成了。
相关文章推荐
- Lua快速入门总结
- Self Summary: Lua Language(two useful links) and the difference between : and .
- Self Summary: Lua Language(two useful links) and the difference between : and .
- Self Summary: Lua Language(two useful links) and the difference between : and .
- Self Summary: Lua Language(two useful links) and the difference between : and .
- Self Summary: Lua Language(two useful links) and the difference between : and .
- Self Summary: Lua Language(two useful links) and the difference between : and .
- 用python把AuroraGT的结果导成lua
- 集训队专题(8)1008 The Evaluation of Determinant
- Lua 服务器Socket通信实例(转)
- Lua 服务器与客户端实例(转)
- 基于lua的网页脚本开发语言cgilua(转)
- c++使用Lua
- Lua的time相关函数
- lua 写逻辑打印log时,打印到一半后停止不再打印,程序停止
- Lua中 assert、pcall 的错误处理
- lua 中的assert 与loadstring 问题
- 我为什么要再给lua写一个json模块
- java: org.luaj.vm2.LuaError:XXX module not found lua脚本初始化出错(转)
- lua-TestMore(转)