luasocket: update version

I made the following modifications:

Makefile - Updated the upstream version. Set the LUAV environment
variable in the build variant. Set an include path in the lua build so
that that lua headers could be found.  Set source date version to
identify the source.

0001-Add-interface-support.patch - ported this patch which included
replacing one deprecated call for 5.3. Validated that the interface
functionality added by the patch is working and functional. The
following lua script line was functional: print(socket.iface.indextoname(2))

0301-Fix-mpc85xx-build.patch - Just fixed the offsets and fuzz in the
patch

040-remove-fpic-and-warnings.patch - ported this patch. I did make one
change. The patch name is called remove fpic and warnings, but the
patch was also removing optimization. I ported the removal of fpic and
warnings, however I left optimization in.

Built and tested on BCM5301X.

Signed-off-by: Colby Whitney <colby.whitney@luxul.com>
[ rmilecki: fix whitespaces in 040-remove-fpic-and-warnings.patch ]
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
This commit is contained in:
Colby Whitney
2019-07-25 09:25:43 -06:00
committed by Rafał Miłecki
parent e38f2d78ec
commit 5de3d6c220
4 changed files with 47 additions and 40 deletions
+15 -14
View File
@@ -8,15 +8,17 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=luasocket
PKG_SOURCE_VERSION:=6d5e40c324c84d9c1453ae88e0ad5bdd0a631448
PKG_VERSION:=3.0-rc1-20130909
PKG_RELEASE:=5
PKG_SOURCE_DATE:=2019-04-21
PKG_SOURCE_VERSION:=733af884f1aa18ff469bf3c4d18810e815853211
PKG_RELEASE:=1
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
PKG_MIRROR_HASH:=d2fa075d8bd026c41e0eb1a634ac2ad8115dee8abb070720e8e91fab51f86ee4
PKG_SOURCE_URL:=https://github.com/diegonehab/luasocket.git
PKG_SOURCE_PROTO:=git
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
PKG_SOURCE_URL:=https://github.com/diegonehab/luasocket
PKG_MIRROR_HASH:=60aef7544426cae3e6c7560a6e4ad556a04b879ca0ad0311645b2c513c872128
PKG_MAINTAINER:=W. Michael Petullo <mike@flyn.org>
PKG_LICENSE:=MIT
PKG_LICENSE_FILES:=LICENSE
include $(INCLUDE_DIR)/package.mk
@@ -24,9 +26,8 @@ define Package/luasocket
SUBMENU:=Lua
SECTION:=lang
CATEGORY:=Languages
URL:=http://w3.impa.br/~diego/software/luasocket
TITLE:=LuaSocket
URL:=http://luasocket.luaforge.net/
MAINTAINER:=W. Michael Petullo <mike@flyn.org>
DEPENDS:=+lua
endef
@@ -44,21 +45,21 @@ define Build/Compile
LIBDIR="$(TARGET_LDFLAGS)" \
CC="$(TARGET_CC) $(TARGET_CFLAGS) $(TARGET_CPPFLAGS) $(FPIC)" \
LD="$(TARGET_CROSS)ld -shared" \
LUAV=5.1 LUAINC_linux_base=$(STAGING_DIR)/usr/include \
all
endef
define Package/luasocket/install
$(INSTALL_DIR) $(1)/usr/lib/lua
$(INSTALL_DATA) $(PKG_BUILD_DIR)/src/{ltn12,mime,socket}.lua $(1)/usr/lib/lua
$(INSTALL_BIN) $(PKG_BUILD_DIR)/src/mime.so.1.0.3 $(1)/usr/lib/lua
$(INSTALL_BIN) $(PKG_BUILD_DIR)/src/socket.so.3.0-rc1 $(1)/usr/lib/lua
$(INSTALL_BIN) $(PKG_BUILD_DIR)/src/mime-1.0.3.so $(1)/usr/lib/lua
$(INSTALL_BIN) $(PKG_BUILD_DIR)/src/socket-3.0-rc1.so $(1)/usr/lib/lua
$(INSTALL_DIR) $(1)/usr/lib/lua/mime
ln -sf ../mime.so.1.0.3 $(1)/usr/lib/lua/mime/core.so
ln -sf ../mime-1.0.3.so $(1)/usr/lib/lua/mime/core.so
$(INSTALL_DIR) $(1)/usr/lib/lua/socket
$(INSTALL_DATA) $(PKG_BUILD_DIR)/src/{ftp,http,smtp,tp,url,headers}.lua $(1)/usr/lib/lua/socket
$(INSTALL_BIN) $(PKG_BUILD_DIR)/src/unix.so $(1)/usr/lib/lua/socket
ln -sf ../socket.so.3.0-rc1 $(1)/usr/lib/lua/socket/core.so
ln -sf ../socket-3.0-rc1.so $(1)/usr/lib/lua/socket/core.so
endef
$(eval $(call BuildPackage,luasocket))