Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
P
plugin
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
link33
plugin
Commits
b9fc209f
Commit
b9fc209f
authored
Dec 27, 2019
by
jiangpeng
Committed by
vipwzw
Dec 30, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
makefile:remove global go list command
parent
e97eda52
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
11 deletions
+9
-11
Makefile
Makefile
+7
-11
docker-compose.sh
build/docker-compose.sh
+2
-0
No files found.
Makefile
View file @
b9fc209f
...
...
@@ -8,12 +8,8 @@ export GO111MODULE=on
CLI
:=
build/chain33-cli
SRC_CLI
:=
github.com/33cn/plugin/cli
APP
:=
build/chain33
export
CHAIN33_PATH
=
$(
shell
go list
-f
{{
.Dir
}}
github.com/33cn/chain33
)
BUILD_FLAGS
=
-ldflags
"-X github.com/33cn/chain33/common/version.GitCommit=
`
git rev-parse
--short
=
8 HEAD
`
"
LDFLAGS
:=
-ldflags
"-w -s"
PKG_LIST_VET
:=
`
go list ./... |
grep
-v
"vendor"
|
grep
-v
plugin/dapp/evm/executor/vm/common/crypto/bn256
`
PKG_LIST
:=
`
go list ./... |
grep
-v
"vendor"
|
grep
-v
"chain33/test"
|
grep
-v
"mocks"
|
grep
-v
"pbft"
`
PKG_LIST_INEFFASSIGN
=
`
go list
-f
{{
.Dir
}}
./... |
grep
-v
"vendor"
`
MKPATH
=
$
(
abspath
$
(
lastword
$(MAKEFILE_LIST)
))
MKDIR
=
$
(
dir
$(MKPATH)
)
proj
:=
"build"
...
...
@@ -25,14 +21,14 @@ build: depends
go build
$(BUILD_FLAGS)
-v
-i
-o
$(APP)
go build
$(BUILD_FLAGS)
-v
-i
-o
$(CLI)
$(SRC_CLI)
go build
$(BUILD_FLAGS)
-v
-i
-o
build/fork-config github.com/33cn/plugin/cli/fork_config/
@
cp
chain33.toml
$(CHAIN33_PATH)
/build/system-test-rpc.sh
build/
@
cp
chain33.toml build/
@
cp
chain33.para.toml build/ci/paracross/
build_ci
:
depends
##
Build the binary file for CI
@
go build
-v
-i
-o
$(CLI)
$(SRC_CLI)
@
go build
$(BUILD_FLAGS)
-v
-o
$(APP)
@
cp
chain33.toml
$(CHAIN33_PATH)
/build/system-test-rpc.sh
build/
@
cp
chain33.toml build/
@
cp
chain33.para.toml build/ci/paracross/
...
...
@@ -40,7 +36,7 @@ para:
@
go build
-v
-o
build/
$(NAME)
-ldflags
"-X
$(SRC_CLI)
/buildflags.ParaName=user.p.
$(NAME)
. -X
$(SRC_CLI)
/buildflags.RPCAddr=http://localhost:8901"
$(SRC_CLI)
vet
:
@
go vet
${
PKG_LIST_VET
}
@
go vet
./...
autotest
:
##
build autotest binary
@
cd
build/autotest
&&
bash ./run.sh build
&&
cd
../../
...
...
@@ -77,16 +73,16 @@ linter_test: ## Use gometalinter check code, for local test
@
find
.
-name
'*.sh'
-not
-path
"./vendor/*"
| xargs shellcheck
ineffassign
:
@
golangci-lint run
--no-config
--issues-exit-code
=
1
--deadline
=
2m
--disable-all
--enable
=
ineffassign
-n
${
PKG_LIST_INEFFASSIGN
}
@
golangci-lint run
--no-config
--issues-exit-code
=
1
--deadline
=
2m
--disable-all
--enable
=
ineffassign
-n
./...
race
:
##
Run data race detector
@
go
test
-parallel
=
8
-race
-short
$(PKG_LIST)
@
go
test
-parallel
=
8
-race
-short
`
go list ./... |
grep
-v
"pbft"
`
test
:
##
Run unittests
@
go
test
-parallel
=
8
-race
$(PKG_LIST)
@
go
test
-parallel
=
8
-race
`
go list ./...|
grep
-v
"pbft"
`
testq
:
##
Run unittests
@
go
test
-parallel
=
8
$(PKG_LIST)
@
go
test
-parallel
=
8
`
go list ./... |
grep
-v
"pbft"
`
fmt
:
fmt_proto fmt_shell
##
go fmt
@
go
fmt
./...
...
...
build/docker-compose.sh
View file @
b9fc209f
...
...
@@ -12,6 +12,8 @@ set -o pipefail
# sudo apt-get install parallel
# ./docker-compose.sh build
CHAIN33_PATH
=
$(
go list
-f
{{
.Dir
}}
github.com/33cn/chain33
)
cp
"
$CHAIN33_PATH
"
/build/system-test-rpc.sh ./
PWD
=
$(
cd
"
$(
dirname
"
$0
"
)
"
&&
pwd
)
export
PATH
=
"
$PWD
:
$PATH
"
...
...
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