From 2be57e13869ecfe248fb87abad762eaa24a10a47 Mon Sep 17 00:00:00 2001 From: Lawrence Chan Date: Wed, 17 Jul 2019 18:18:26 -0500 Subject: Make GOPATH-related symlinking more precise This change tweaks the symlink commands that are invoked when libpod is not on GOPATH. This has the following effects: - If the working directory is not "libpod", it will still create the symlink at the correct github.com/containers/libpod path. - If the github.com/varlink directory/symlink already exists, it will still create the symlink at the intended path. Signed-off-by: Lawrence Chan --- Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 3c7f9d74b..e155d31d4 100644 --- a/Makefile +++ b/Makefile @@ -127,8 +127,8 @@ help: .gopathok: ifeq ("$(wildcard $(GOPKGDIR))","") mkdir -p "$(GOPKGBASEDIR)" - ln -sf "$(CURDIR)" "$(GOPKGBASEDIR)" - ln -sf "$(CURDIR)/vendor/github.com/varlink" "$(FIRST_GOPATH)/src/github.com/varlink" + ln -sfnT "$(CURDIR)" "$(GOPKGDIR)" + ln -sfnT "$(CURDIR)/vendor/github.com/varlink" "$(FIRST_GOPATH)/src/github.com/varlink" endif touch $@ -- cgit v1.2.3-54-g00ecf