Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
K
kubo_final
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Anastasiia Chirikova
kubo_final
Commits
de4e34d2
Commit
de4e34d2
authored
9 years ago
by
Thomas Gardner
Browse files
Options
Downloads
Patches
Plain Diff
Makefile: add PHONY targets and a help message
License: MIT Signed-off-by:
Thomas Gardner
<
tmg@fastmail.com
>
parent
081c6d92
Branches
Branches containing commit
No related tags found
1 merge request
!1
New
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
Makefile
+57
-8
57 additions, 8 deletions
Makefile
with
57 additions
and
8 deletions
Makefile
+
57
−
8
View file @
de4e34d2
ifeq
($(TEST_NO_FUSE),1)
go_test
=
go
test
-tags
nofuse
go_test
=
go
test
-tags
nofuse
else
go_test
=
go
test
go_test
=
go
test
endif
commit
=
`
git rev-parse
--short
HEAD
`
ldflags
=
"-X "
github.com/ipfs/go-ipfs/repo/config
".CurrentCommit=
$(
commit
)
"
COMMIT
:=
$(
shell git rev-parse
--short
HEAD
)
ldflags
=
"-X "
github.com/ipfs/go-ipfs/repo/config
".CurrentCommit=
$(
COMMIT
)
"
MAKEFLAGS
+=
--no-print-directory
all
:
# no-op. try:
# make install
# make test
all
:
help
godep
:
go get github.com/tools/godep
...
...
@@ -31,6 +29,14 @@ build:
nofuse
:
cd
cmd/ipfs
&&
go
install
-tags
nofuse
-ldflags
=
$(
ldflags
)
clean
:
cd
cmd/ipfs
&&
go clean
-ldflags
=
$(
ldflags
)
uninstall
:
cd
cmd/ipfs
&&
go clean
-i
-ldflags
=
$(
ldflags
)
PHONY
+=
all
help
godep
install
build nofuse clean uninstall
##############################################################
# tests targets
...
...
@@ -76,3 +82,46 @@ test_all_commits_travis:
windows_build_check
:
GOOS
=
windows
GOARCH
=
amd64 go build
-o
.test.ipfs.exe ./cmd/ipfs
rm
.test.ipfs.exe
PHONY
+=
test
test_short test_expensive
##############################################################
# A semi-helpful help message
help
:
@
echo
'DEPENDENCY TARGETS:'
@
echo
''
@
echo
' vendor - Create a Godep workspace of 3rd party dependencies'
@
echo
''
@
echo
'BUILD TARGETS:'
@
echo
''
@
echo
' all - print this help message'
@
echo
' build - Build binary at ./cmd/ipfs/ipfs'
@
echo
' nofuse - Build binary with no fuse support'
@
echo
' install - Build binary and install into $$GOPATH/bin'
# @echo ' dist_install - TODO: c.f. ./cmd/ipfs/dist/README.md'
@echo
''
@echo 'CLEANING TARGETS
:
'
@
echo
''
@
echo
' clean - Remove binary from build directory'
@
echo
' uninstall - Remove binary from $$GOPATH/bin'
@
echo
''
@
echo
'TESTING TARGETS:'
@
echo
''
@
echo
' test - Run expensive tests and Window$$ check'
@
echo
' test_short - Run short tests and sharness tests'
@
echo
' test_expensive - Run a few extras'
@
echo
' test_3node'
@
echo
' test_go_short'
@
echo
' test_go_expensive'
@
echo
' test_go_race'
@
echo
' test_sharness_short'
@
echo
' test_sharness_expensive'
@
echo
' test_all_commits'
@
echo
" test_all_commits_travis - DON'T USE: takes way too long"
@
echo
' windows_build_check'
@
echo
''
PHONY
+=
help
.PHONY
:
$(PHONY)
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment