forked from liuran001/openwrt-packages
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
48 lines (38 loc) · 1.32 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
# SPDX-License-Identifier: GPL-3.0-only
#
# Copyright (C) 2014-2018 Jian Chang <[email protected]>
# Copyright (C) 2021 ImmortalWrt.org
include $(TOPDIR)/rules.mk
PKG_NAME:=chinadns
PKG_VERSION:=1.3.3
PKG_RELEASE:=$(AUTORELEASE)
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=https://codeload.github.com/aa65535/ChinaDNS/tar.gz/v$(PKG_VERSION)?
PKG_HASH:=74e53af32f8aa2ca7e63697385f12d89a06c486641556cfd8bc3f085d87e55ad
PKG_BUILD_DIR:=$(BUILD_DIR)/ChinaDNS-$(PKG_VERSION)
PKG_LICENSE:=GPL-3.0-only
PKG_LICENSE_FILES:=LICENSE
PKG_MAINTAINER:=Jian Chang <[email protected]>
PKG_FIXUP:=autoreconf
PKG_BUILD_PARALLEL:=1
PKG_INSTALL:=1
include $(INCLUDE_DIR)/package.mk
define Package/chinadns
SECTION:=net
CATEGORY:=Network
SUBMENU:=IP Addresses and Names
TITLE:=Protect yourself against DNS poisoning in China.
URL:=https://github.com/shadowsocks/ChinaDNS
endef
define Package/chinadns/conffiles
/usr/share/chinadns/chnroute.txt
/usr/share/chinadns/iplist.txt
endef
define Package/chinadns/install
$(INSTALL_DIR) $(1)/usr/bin
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/chinadns $(1)/usr/bin/
$(INSTALL_DIR) $(1)/usr/share/chinadns
$(CP) $(PKG_INSTALL_DIR)/usr/share/chnroute.txt $(1)/usr/share/chinadns/
$(CP) $(PKG_INSTALL_DIR)/usr/share/iplist.txt $(1)/usr/share/chinadns/
endef
$(eval $(call BuildPackage,chinadns))