Skip to content

Commit cc2eab4

Browse files
authored
Merge pull request #5 from Beginner-Go/patch-1
go-aliyundrive-webdav: drop `UPX`
2 parents 303c76e + 51015d7 commit cc2eab4

File tree

1 file changed

+0
-27
lines changed

1 file changed

+0
-27
lines changed

Makefile

-27
Original file line numberDiff line numberDiff line change
@@ -16,16 +16,11 @@ PKG_LICENSE:=Apache-2.0
1616
PKG_LICENSE_FILE:=LICENSE
1717
PKG_MAINTAINER:=Tianling Shen <[email protected]>
1818

19-
PKG_CONFIG_DEPENDS:= \
20-
CONFIG_GO_ALIYUNDRIVE_WEBDAV_COMPRESS_GOPROXY \
21-
CONFIG_GO_ALIYUNDRIVE_WEBDAV_COMPRESS_UPX
22-
2319
PKG_BUILD_DEPENDS:=golang/host
2420
PKG_BUILD_PARALLEL:=1
2521
PKG_USE_MIPS16:=0
2622

2723
GO_PKG:=go-aliyun-webdav
28-
GO_PKG_LDFLAGS:=-s -w
2924
GO_PKG_LDFLAGS_X:=main.Version=v$(PKG_VERSION)
3025

3126
include $(INCLUDE_DIR)/package.mk
@@ -40,32 +35,10 @@ define Package/go-aliyundrive-webdav
4035
DEPENDS:=$(GO_ARCH_DEPENDS)
4136
endef
4237

43-
define Package/go-aliyundrive-webdav/config
44-
config GO_ALIYUNDRIVE_WEBDAV_COMPRESS_GOPROXY
45-
bool "Compiling with GOPROXY proxy"
46-
default n
47-
48-
config GO_ALIYUNDRIVE_WEBDAV_COMPRESS_UPX
49-
bool "Compress executable files with UPX"
50-
default y
51-
endef
52-
53-
ifeq ($(CONFIG_GO_ALIYUNDRIVE_WEBDAV_COMPRESS_GOPROXY),y)
54-
export GO111MODULE=on
55-
export GOPROXY=https://goproxy.baidu.com
56-
endif
57-
5838
define Package/go-aliyundrive-webdav/conffiles
5939
/etc/config/go-aliyundrive-webdav
6040
endef
6141

62-
define Build/Compile
63-
$(call GoPackage/Build/Compile)
64-
ifeq ($(CONFIG_GO_ALIYUNDRIVE_WEBDAV_COMPRESS_UPX),y)
65-
$(STAGING_DIR_HOST)/bin/upx --lzma --best $(GO_PKG_BUILD_BIN_DIR)/go-aliyun-webdav
66-
endif
67-
endef
68-
6942
define Package/go-aliyundrive-webdav/install
7043
$(call GoPackage/Package/Install/Bin,$(PKG_INSTALL_DIR))
7144
$(INSTALL_DIR) $(1)/usr/bin/

0 commit comments

Comments
 (0)