代码拉取完成,页面将自动刷新
#
# Copyright (C) 2021 jjm2473 <jjm2473@gmail.com>
#
# This is free software, licensed under the Apache License, Version 2.0 .
#
META_NAME?=$(notdir ${CURDIR})
META_BASENAME?=$(patsubst app-meta-%,%,$(META_NAME))
META_ARCH?=all
META_FLAGS:=$(if $(realpath entry.sh), entrysh)
PKG_NAME?=$(META_NAME)
PKG_RELEASE?=1
PKG_MAINTAINER:=$(META_AUTHOR)
PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)
include $(INCLUDE_DIR)/package.mk
escape_json=$(strip $(subst ",\",$(subst \,\\\\,$(1))))
META_ESCAPED_TITLE:=$(call escape_json,$(META_TITLE))
META_ESCAPED_DESCRIPTION:=$(call escape_json,$(META_DESCRIPTION))
META_ESCAPED_TITLE.en:=$(call escape_json,$(META_TITLE.en))
META_ESCAPED_DESCRIPTION.en:=$(call escape_json,$(META_DESCRIPTION.en))
define Package/$(PKG_NAME)
SECTION:=meta
CATEGORY:=Metadata
TITLE:=$(META_TITLE)
DEPENDS:=$(META_DEPENDS)
PKGARCH:=all
endef
ifneq ($(META_DESCRIPTION),)
define Package/$(PKG_NAME)/description
$(strip $(META_DESCRIPTION))
endef
endif
define Build/Prepare
endef
define Build/Configure
endef
define Build/Compile
endef
define Package/$(PKG_NAME)/JsonInfo
{
"name": "$(META_BASENAME)",
"title": "$(META_ESCAPED_TITLE)",
$(if $(META_ESCAPED_TITLE.en), "title_en": "$(META_ESCAPED_TITLE.en)"$(comma))
"entry": "$(META_LUCI_ENTRY)",
"author": "$(META_AUTHOR)",
"website": "$(META_WEBSITE)",
$(if $(META_TUTORIAL), "tutorial": "$(META_TUTORIAL)"$(comma))
"version": "$(PKG_VERSION)",
"release": $(PKG_RELEASE),
"arch": [$(patsubst %$(comma),%,$(subst $(space),,$(foreach arch,$(META_ARCH),"$(arch)"$(comma))))],
"description": "$(META_ESCAPED_DESCRIPTION)",
$(if $(META_ESCAPED_DESCRIPTION.en), "description_en": "$(META_ESCAPED_DESCRIPTION.en)"$(comma))
$(if $(META_AUTOCONF), "autoconf": [$(patsubst %$(comma),%,$(subst $(space),,$(foreach conf,$(META_AUTOCONF),"$(conf)"$(comma))))]$(comma))
$(if $(META_UCI), "uci": "$(META_UCI)"$(comma))
$(if $(META_FLAGS), "flags": [$(patsubst %$(comma),%,$(subst $(space),,$(foreach flag,$(META_FLAGS),"$(flag)"$(comma))))]$(comma))
"tags": [$(patsubst %$(comma),%,$(subst $(space),,$(foreach tag,$(META_TAGS),"$(tag)"$(comma))))],
"depends": [$(patsubst %$(comma),%,$(subst $(space),,$(foreach dep,$(META_DEPENDS),"$(subst +,,$(dep))"$(comma))))]
}
endef
define Package/$(PKG_NAME)/install
$(INSTALL_DIR) $(1)/usr/lib/opkg/meta $(1)/usr/libexec/istorea $(1)/usr/libexec/istoree $(1)/www/luci-static/resources/app-icons
if [ -d ./root ]; then \
cp -pR ./root/* $(1)/; \
else true; fi
if [ -f ./logo.png ]; then \
$(INSTALL_DATA) ./logo.png $(1)/www/luci-static/resources/app-icons/$(META_BASENAME).png ; \
fi;
if [ -f ./config.sh ]; then \
$(INSTALL_BIN) ./config.sh $(1)/usr/libexec/istorea/$(META_BASENAME).sh ; \
fi;
if [ -f ./entry.sh ]; then \
$(INSTALL_BIN) ./entry.sh $(1)/usr/libexec/istoree/$(META_BASENAME).sh ; \
fi;
echo "$(call escape_json,$(call Package/$(PKG_NAME)/JsonInfo))" > $(1)/usr/lib/opkg/meta/$(META_BASENAME).json
endef
$(eval $(call BuildPackage,$(PKG_NAME)))
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。