mirror of
https://github.com/kiddin9/op-packages.git
synced 2026-07-27 18:41:15 +08:00
61 lines
1.6 KiB
Makefile
61 lines
1.6 KiB
Makefile
include $(TOPDIR)/rules.mk
|
|
|
|
PKG_NAME:=mihomo-alpha
|
|
PKG_VERSION:=2026.05.30
|
|
PKG_RELEASE:=10
|
|
|
|
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
|
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
|
|
PKG_SOURCE_PROTO:=git
|
|
PKG_SOURCE_URL:=https://github.com/MetaCubeX/mihomo.git
|
|
PKG_SOURCE_VERSION:=fc8c5a24b16991f98cd736950c17d1aa306a5041
|
|
PKG_MIRROR_HASH:=skip
|
|
|
|
PKG_LICENSE:=GPL3.0+
|
|
PKG_MAINTAINER:=Joseph Mory <morytyann@gmail.com>
|
|
|
|
PKG_BUILD_DEPENDS:=golang/host
|
|
PKG_BUILD_PARALLEL:=1
|
|
PKG_BUILD_FLAGS:=no-mips16
|
|
|
|
PKG_BUILD_VERSION:=alpha-fc8c5a24
|
|
PKG_BUILD_TIME:=$(shell date -u -Iseconds)
|
|
|
|
GO_PKG:=github.com/metacubex/mihomo
|
|
GO_PKG_BUILD_PKG:=github.com/metacubex/mihomo
|
|
GO_PKG_LDFLAGS_X:=$(GO_PKG)/constant.Version=$(PKG_BUILD_VERSION) $(GO_PKG)/constant.BuildTime=$(PKG_BUILD_TIME)
|
|
GO_PKG_TAGS:=with_gvisor
|
|
GO_PKG_INSTALL_BIN_PATH:=/usr/libexec
|
|
|
|
include $(INCLUDE_DIR)/package.mk
|
|
include $(TOPDIR)/feeds/packages/lang/golang/golang-package.mk
|
|
|
|
define Package/mihomo-alpha
|
|
SECTION:=net
|
|
CATEGORY:=Network
|
|
TITLE:=A rule based proxy in Go.
|
|
URL:=https://wiki.metacubex.one
|
|
DEPENDS:=$(GO_ARCH_DEPENDS) +ca-bundle +ip-full +kmod-inet-diag +kmod-tun
|
|
PROVIDES:=mihomo
|
|
CONFLICTS:=mihomo-meta
|
|
VARIANT:=alpha
|
|
ALTERNATIVES:=\
|
|
300:/usr/bin/mihomo:/usr/libexec/mihomo
|
|
endef
|
|
|
|
define Package/mihomo-alpha/description
|
|
A rule based proxy in Go.
|
|
endef
|
|
|
|
define Package/mihomo-alpha/install
|
|
$(call GoPackage/Package/Install/Bin,$(1))
|
|
endef
|
|
|
|
define Build/Prepare
|
|
$(Build/Prepare/Default)
|
|
$(RM) -r $(PKG_BUILD_DIR)/rules/logic_test
|
|
endef
|
|
|
|
$(eval $(call GoBinPackage,mihomo-alpha))
|
|
$(eval $(call BuildPackage,mihomo-alpha))
|