From 87f016f27c27b0cb1b01a4373f2c1e14a2c31ce5 Mon Sep 17 00:00:00 2001 From: Vadim Vetrov Date: Mon, 5 Aug 2024 16:21:20 +0300 Subject: [PATCH] Add download from github --- youtubeUnblock/Makefile | 44 ++++++++++++++++++++++------------------- 1 file changed, 24 insertions(+), 20 deletions(-) diff --git a/youtubeUnblock/Makefile b/youtubeUnblock/Makefile index 5ff1d1b..80712bb 100644 --- a/youtubeUnblock/Makefile +++ b/youtubeUnblock/Makefile @@ -4,44 +4,48 @@ include $(TOPDIR)/rules.mk PKG_NAME:=youtubeUnblock PKG_VERSION:=0.1 +PKG_REV:=82d65b8f9696ba9be7cdf807e0524a2f93b2bc7a PKG_RELEASE:=1 -SOURCE_DIR:=/home/me/youtubeUnblock +PKG_SOURCE_URL:=https://github.com/Waujito/youtubeUnblock.git +PKG_SOURCE_PROTO:=git +PKG_SOURCE_VERSION:=$(PKG_REV) include $(INCLUDE_DIR)/package.mk define Package/youtubeUnblock - SECTION:=net - CATEGORY:=Networking - TITLE:=youtubeUnblock + SECTION:=net + CATEGORY:=Networking + TITLE:=youtubeUnblock + URL:=https://github.com/Waujito/youtubeUnblock + MAINTAINER:=Vadim Vetrov endef define Package/youtubeUnblock/description - Bypasses Googlevideo detection systems that relies on SNI + Bypasses Googlevideo detection systems that relies on SNI endef define Build/Prepare - mkdir -p $(PKG_BUILD_DIR) - cp -r $(SOURCE_DIR)/* $(PKG_BUILD_DIR) - $(Build/Patch) + $(Build/Prepare/Default) + $(Build/Patch) endef define Build/Compile - $(MAKE) -C $(PKG_BUILD_DIR) \ - PATH="$(TARGET_PATH)" \ - CC="$(TARGET_CC)" \ - CFLAGS="$(TARGET_CFLAGS)" \ - LDFLAGS="$(TARGET_LDFLAGS)" \ - CROSS_COMPILE_PLATFORM="$(TARGET_CROSS:-=)" + $(MAKE) -C $(PKG_BUILD_DIR) \ + PATH="$(TARGET_PATH)" \ + CC="$(TARGET_CC)" \ + CFLAGS="$(TARGET_CFLAGS)" \ + LDFLAGS="$(TARGET_LDFLAGS)" \ + CROSS_COMPILE_PLATFORM="$(TARGET_CROSS:-=)" endef define Package/youtubeUnblock/install - $(INSTALL_DIR) $(1)/usr/bin - $(INSTALL_BIN) $(PKG_BUILD_DIR)/build/youtubeUnblock $(1)/usr/bin - $(INSTALL_DIR) $(1)/etc/init.d - $(INSTALL_BIN) ./files/youtubeUnblock.owrt $(1)/etc/init.d/youtubeUnblock - $(INSTALL_DIR) $(1)/usr/share/nftables.d/ruleset-post/ - $(CP) ./files/537-youtubeUnblock.nft $(1)/usr/share/nftables.d/ruleset-post/537-youtubeUnblock.nft + $(INSTALL_DIR) $(1)/usr/bin + $(INSTALL_BIN) $(PKG_BUILD_DIR)/build/youtubeUnblock $(1)/usr/bin + $(INSTALL_DIR) $(1)/etc/init.d + $(INSTALL_BIN) ./files/youtubeUnblock.owrt $(1)/etc/init.d/youtubeUnblock + $(INSTALL_DIR) $(1)/usr/share/nftables.d/ruleset-post/ + $(CP) ./files/537-youtubeUnblock.nft $(1)/usr/share/nftables.d/ruleset-post/537-youtubeUnblock.nft endef $(eval $(call BuildPackage,youtubeUnblock))