package/pkg-golang: drop the fixed <pkg>_BINDIR variable
authorThomas Petazzoni <thomas.petazzoni@bootlin.com>
Sun, 1 Apr 2018 11:51:36 +0000 (13:51 +0200)
committerPeter Korsgaard <peter@korsgaard.com>
Sun, 1 Apr 2018 14:39:28 +0000 (16:39 +0200)
Now that <pkg>_BINDIR is always "bin", having it as a package variable
doesn't make much sense, so get rid of this variable completely, and
use "bin".

Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Reviewed-by: "Yann E. MORIN" <yann.morin.1998@free.fr>
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
package/docker-proxy/docker-proxy.mk
package/flannel/flannel.mk
package/pkg-golang.mk

index a90271fc353b38c71a01ca5587e6bc6d04dc668f..dfa9d4347d25db750e7660f11ffb53cd0108de65 100644 (file)
@@ -17,7 +17,7 @@ DOCKER_PROXY_WORKSPACE = gopath
 DOCKER_PROXY_BUILD_TARGETS = cmd/proxy
 
 define DOCKER_PROXY_INSTALL_TARGET_CMDS
-       $(INSTALL) -D -m 0755 $(@D)/$(DOCKER_PROXY_BINDIR)/proxy $(TARGET_DIR)/usr/bin/docker-proxy
+       $(INSTALL) -D -m 0755 $(@D)/bin/proxy $(TARGET_DIR)/usr/bin/docker-proxy
 endef
 
 $(eval $(golang-package))
index 07d5d0dfd6937beeffa4a7b2b47f59d60b5f61be..d00d2df92c6582bdc9824455404d4356d3a6fe4b 100644 (file)
@@ -15,7 +15,7 @@ FLANNEL_LDFLAGS = -X github.com/coreos/flannel/version.Version=$(FLANNEL_VERSION
 
 # Install flannel to its well known location.
 define FLANNEL_INSTALL_TARGET_CMDS
-       $(INSTALL) -D -m 0755 $(@D)/$(FLANNEL_BINDIR)/flannel $(TARGET_DIR)/opt/bin/flanneld
+       $(INSTALL) -D -m 0755 $(@D)/bin/flannel $(TARGET_DIR)/opt/bin/flanneld
        $(INSTALL) -D -m 0755 $(@D)/dist/mk-docker-opts.sh $(TARGET_DIR)/opt/bin/mk-docker-opts.sh
 endef
 
index 342d17fbd97ccb9115c228b9bc10630508cfcd14..f23bda390d4768816911c91e4a1eb78586224042 100644 (file)
@@ -70,7 +70,6 @@ ifeq ($$($(2)_BUILD_TARGETS),.)
 $(2)_BIN_NAME ?= $(1)
 endif
 
-$(2)_BINDIR = bin
 $(2)_INSTALL_BINS ?= $(1)
 
 # Source files in Go should be extracted in a precise folder in the hierarchy
@@ -103,7 +102,7 @@ define $(2)_BUILD_CMDS
                        GOPATH="$$(@D)/$$($(2)_WORKSPACE)" \
                        $$($(2)_GO_ENV) \
                        $$(GO_BIN) build -v $$($(2)_BUILD_OPTS) \
-                       -o $$(@D)/$$($(2)_BINDIR)/$$(or $$($(2)_BIN_NAME),$$(notdir $$(d))) \
+                       -o $$(@D)/bin/$$(or $$($(2)_BIN_NAME),$$(notdir $$(d))) \
                        ./$$(d)
        )
 endef
@@ -114,7 +113,7 @@ endif
 ifndef $(2)_INSTALL_TARGET_CMDS
 define $(2)_INSTALL_TARGET_CMDS
        $$(foreach d,$$($(2)_INSTALL_BINS),\
-               $(INSTALL) -D -m 0755 $$(@D)/$$($(2)_BINDIR)/$$(d) $(TARGET_DIR)/usr/bin/$$(d)
+               $(INSTALL) -D -m 0755 $$(@D)/bin/$$(d) $(TARGET_DIR)/usr/bin/$$(d)
        )
 endef
 endif