Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Open sidebar
dms3
go-dms3
Commits
dbc1d3f2
Commit
dbc1d3f2
authored
8 years ago
by
Péter Szilágyi
Committed by
Dominic Della Valle
8 years ago
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Makefile, bin: Support multiple GOPATH components
License: MIT Signed-off-by:
Péter Szilágyi
<
peterke@gmail.com
>
parent
8fbbd7f7
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
11 additions
and
7 deletions
+11
-7
Makefile
Makefile
+1
-1
bin/check_go_path
bin/check_go_path
+10
-6
No files found.
Makefile
View file @
dbc1d3f2
...
...
@@ -41,7 +41,7 @@ bin/gx-go-v%:
gx_check
:
${gx_bin} ${gx-go_bin}
path_check
:
@
bin/check_go_path
$(
realpath
$(
shell
pwd
))
$(
realpath
$(
GOPATH)
/src/github.com/ipfs/go-ipfs
)
@
bin/check_go_path
$(
realpath
$(
shell
pwd
))
$(
realpath
$(
addsuffix
/src/github.com/ipfs/go-ipfs
,
$(
subst
:, ,
$(GOPATH)
))
)
deps
:
go_check gx_check path_check
${gx_bin}
--verbose
install
--global
...
...
This diff is collapsed.
Click to expand it.
bin/check_go_path
View file @
dbc1d3f2
#!/bin/sh
PWD
=
$1
EXPECTED
=
$2
if
[
-z
"
$PWD
"
]
;
then
echo
"must pass in your current working directory"
...
...
@@ -13,8 +12,13 @@ if [ -z "$GOPATH" ]; then
exit
1
fi
if
[
"
$PWD
"
!=
"
$EXPECTED
"
]
;
then
echo
"go-ipfs must be built from within your
\$
GOPATH directory."
echo
"expected '
$EXPECTED
' but got '
$PWD
'"
exit
1
fi
while
[
${#}
-gt
1
]
;
do
if
[
"
$PWD
"
=
"
$2
"
]
;
then
exit
0
fi
shift
done
echo
"go-ipfs must be built from within your
\$
GOPATH directory."
echo
"expected within '
$GOPATH
' but got '
$PWD
'"
exit
1
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment