Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- diff --git a/package/utils/lua/Makefile b/package/utils/lua/Makefile
- index cf2d887..51860b7 100644
- --- a/package/utils/lua/Makefile
- +++ b/package/utils/lua/Makefile
- @@ -22,24 +22,28 @@ PKG_BUILD_PARALLEL:=1
- PKG_LICENSE:=MIT
- PKG_LICENSE_FILES:=COPYRIGHT
- +PKG_CONFIG_DEPENDS:=\
- + CONFIG_LUA_IS_JIT \
- + CONFIG_LUA_IS_PUC
- +
- HOST_PATCH_DIR := ./patches-host
- include $(INCLUDE_DIR)/package.mk
- include $(INCLUDE_DIR)/host-build.mk
- +define Package/lua/config
- + source "$(SOURCE)/Config.in"
- +endef
- +
- define Package/lua/Default
- SUBMENU:=Lua
- SECTION:=lang
- CATEGORY:=Languages
- - TITLE:=Lua programming language
- - URL:=http://www.lua.org/
- - MAINTAINER:=Jo-Philipp Wich <[email protected]>
- + TITLE:=Lua [virtual]
- endef
- define Package/lua/Default/description
- - Lua is a powerful light-weight programming language designed for extending
- - applications. Lua is also frequently used as a general-purpose, stand-alone
- - language. Lua is free software.
- + Virtual Lua package
- endef
- define Package/liblua
- @@ -48,43 +52,92 @@ $(call Package/lua/Default)
- SECTION:=libs
- CATEGORY:=Libraries
- TITLE+= (libraries)
- + DEPENDS:=+LUA_IS_PUC:libluapuc +LUA_IS_JIT:libluajit
- endef
- define Package/liblua/description
- $(call Package/lua/Default/description)
- - This package contains the Lua shared libraries, needed by other programs.
- endef
- define Package/lua
- $(call Package/lua/Default)
- - DEPENDS:=+liblua
- + DEPENDS:=+liblua +LUA_IS_PUC:luapuc +LUA_IS_JIT:luajit
- TITLE+= (interpreter)
- endef
- define Package/lua/description
- $(call Package/lua/Default/description)
- - This package contains the Lua language interpreter.
- endef
- define Package/luac
- $(call Package/lua/Default)
- - DEPENDS:=+liblua
- + DEPENDS:=+liblua +LUA_IS_PUC:luapucc +LUA_IS_JIT:luajitc
- TITLE+= (compiler)
- endef
- define Package/luac/description
- $(call Package/lua/Default/description)
- +endef
- +
- +define Package/luapuc/Default
- + SUBMENU:=Lua
- + SECTION:=lang
- + CATEGORY:=Languages
- + TITLE:=Lua programming language
- + URL:=http://www.lua.org/
- + MAINTAINER:=Jo-Philipp Wich <[email protected]>
- +endef
- +
- +define Package/luapuc/Default/description
- + Lua is a powerful light-weight programming language designed for extending
- + applications. Lua is also frequently used as a general-purpose, stand-alone
- + language. Lua is free software.
- +endef
- +
- +define Package/libluapuc
- +$(call Package/luapuc/Default)
- + SUBMENU:=
- + SECTION:=libs
- + CATEGORY:=Libraries
- + TITLE+= (libraries)
- + DEPENDS:=@LUA_IS_PUC
- +endef
- +
- +define Package/libluapuc/description
- +$(call Package/luapuc/Default/description)
- + This package contains the Lua shared libraries, needed by other programs.
- +endef
- +
- +define Package/luapuc
- +$(call Package/luapuc/Default)
- + DEPENDS:=+libluapuc
- + TITLE+= (interpreter)
- +endef
- +
- +define Package/luapuc/description
- +$(call Package/luapuc/Default/description)
- + This package contains the Lua language interpreter.
- +endef
- +
- +define Package/luapucc
- +$(call Package/luapuc/Default)
- + DEPENDS:=+libluapuc
- + TITLE+= (compiler)
- +endef
- +
- +define Package/luapucc/description
- +$(call Package/luapuc/Default/description)
- This package contains the Lua language compiler.
- endef
- define Package/lua-examples
- -$(call Package/lua/Default)
- - DEPENDS:=lua
- +$(call Package/luapuc/Default)
- + DEPENDS:=luapuc
- TITLE+= (examples)
- endef
- define Package/lua-examples/description
- -$(call Package/lua/Default/description)
- +$(call Package/luapuc/Default/description)
- This package contains Lua language examples.
- endef
- @@ -148,17 +201,17 @@ define Build/InstallDev
- $(CP) $(PKG_BUILD_DIR)/etc/lua.pc $(1)/usr/lib/pkgconfig/
- endef
- -define Package/liblua/install
- +define Package/libluapuc/install
- $(INSTALL_DIR) $(1)/usr/lib
- $(CP) $(PKG_INSTALL_DIR)/usr/lib/liblua.so.* $(1)/usr/lib/
- endef
- -define Package/lua/install
- +define Package/luapuc/install
- $(INSTALL_DIR) $(1)/usr/bin
- $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/lua $(1)/usr/bin/
- endef
- -define Package/luac/install
- +define Package/luapucc/install
- $(INSTALL_DIR) $(1)/usr/bin
- $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/luac $(1)/usr/bin/
- endef
- @@ -172,6 +225,11 @@ endef
- $(eval $(call BuildPackage,liblua))
- $(eval $(call BuildPackage,lua))
- $(eval $(call BuildPackage,luac))
- -$(eval $(call BuildPackage,lua-examples))
- -$(eval $(call HostBuild))
- +$(eval $(call BuildPackage,libluapuc))
- +$(eval $(call BuildPackage,luapuc))
- +$(eval $(call BuildPackage,luapucc))
- +$(eval $(call BuildPackage,lua-examples))
- +ifneq ($(CONFIG_PACKAGE_luapuc),)
- +# $(eval $(call HostBuild))
- +endif
- --- /dev/null 2016-07-20 13:17:04.379838998 +0300
- +++ b/package/utils/lua/Config.in 2016-08-04 01:37:21.928454855 +0300
- @@ -0,0 +1,21 @@
- +# lua interpreter choice
- +
- +menu "Interpreter"
- + depends on PACKAGE_lua
- +
- +choice
- + prompt "Type"
- + default LUA_IS_PUC
- +
- +config LUA_IS_PUC
- + bool "PUC"
- + select PACKAGE_libluapuc
- +
- +config LUA_IS_JIT
- + bool "JIT"
- + select PACKAGE_libluajit
- + depends on @arm||@mips
- +
- +endchoice
- +
- +endmenu
Advertisement
Add Comment
Please, Sign In to add comment