Skip to content

Commit

Permalink
Makefile: call BuildPackage.
Browse files Browse the repository at this point in the history
Signed-off-by: kongfl888 K <[email protected]>
  • Loading branch information
kongfl888 committed Nov 19, 2022
1 parent f42026c commit 111f57a
Showing 1 changed file with 8 additions and 33 deletions.
41 changes: 8 additions & 33 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -8,45 +8,18 @@ include $(TOPDIR)/rules.mk
PKG_NAME:=luci-app-adguardhome
PKG_VERSION:=1.8
PKG_RELEASE:=20221023
PKG_MAINTAINER:=<https://github.com/rufengsuixing/luci-app-adguardhome>

PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)

include $(INCLUDE_DIR)/package.mk

define Package/luci-app-adguardhome
SECTION:=luci
CATEGORY:=LuCI
SUBMENU:=3. Applications
TITLE:=LuCI app for adguardhome
PKG_MAINTAINER:=<https://github.com/rufengsuixing/luci-app-adguardhome>
PKGARCH:=all
DEPENDS:=+!wget&&!curl&&!wget-ssl:curl
endef

define Package/luci-app-adguardhome/description
LuCI support for adguardhome
endef

define Build/Prepare
endef

define Build/Compile
endef
LUCI_TITLE:=LuCI app for adguardhome
LUCI_DEPENDS:=+!wget&&!curl&&!wget-ssl:curl
LUCI_PKGARCH:=all
LUCI_DESCRIPTION:=LuCI support for adguardhome

define Package/luci-app-adguardhome/conffiles
/usr/share/AdGuardHome/links.txt
/etc/config/AdGuardHome
endef

define Package/luci-app-adguardhome/install
$(INSTALL_DIR) $(1)/usr/lib/lua/luci
cp -pR ./luasrc/* $(1)/usr/lib/lua/luci
$(INSTALL_DIR) $(1)/
cp -pR ./root/* $(1)/
$(INSTALL_DIR) $(1)/usr/lib/lua/luci/i18n
po2lmo ./po/zh-cn/AdGuardHome.po $(1)/usr/lib/lua/luci/i18n/AdGuardHome.zh-cn.lmo
endef

define Package/luci-app-adguardhome/postinst
#!/bin/sh
/etc/init.d/AdGuardHome enable >/dev/null 2>&1
Expand Down Expand Up @@ -78,4 +51,6 @@ rm -rf /etc/AdGuardHome/
exit 0
endef

$(eval $(call BuildPackage,luci-app-adguardhome))
include $(TOPDIR)/feeds/luci/luci.mk

# call BuildPackage - OpenWrt buildroot signature

0 comments on commit 111f57a

Please sign in to comment.