Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add make command shell #130

Merged
merged 5 commits into from
Sep 15, 2015
Merged

add make command shell #130

merged 5 commits into from
Sep 15, 2015

Conversation

insionng
Copy link
Contributor

No description provided.

make command
make command
@ngaut
Copy link
Member

ngaut commented Sep 13, 2015

@qiuyesuifeng Please take a look.

@insionng Thank you, Could you sign the CLA. CI failed

@insionng
Copy link
Contributor Author

okay~

@shenli
Copy link
Member

shenli commented Sep 13, 2015

@c4pt0r
Please take a look.

@qiuyesuifeng
Copy link
Member

@insionng Thanks for your PR.

There are some additional things need to do:
1 For making tidb, u need do things as follows:
1.1 godep
godep is to get godep tool(https://github.com/tools/godep) which is used for easy building without getting dependency packages.

1.2 parser
parser is to get goyacc and golex package, generate parser/parser.go and parser/scanner.go which are needed by tidb building.
In your make.cmd, u have done this, but also need some work like in tidb/Makefile to generate parser/scanner.go
golex -o parser/scanner.go parser/scanner.l

1.3 build
Godep go build

1.4 test
Godep go test ./...

2 For making interpreter, u need do things as follows:
2.1 add ldflags go build option[nice to haves]
LDFLAGS += -X "github.com/pingcap/tidb/util/printer.TiDBBuildTS=$(shell date -u '+%Y-%m-%d %I:%M:%S')"
LDFLAGS += -X "github.com/pingcap/tidb/util/printer.TiDBGitHash=$(shell git rev-parse HEAD)"
The ldflags is very useful for us to check and fix bugs.
The correct interpreter output looks like as follows:

Welcome to the TiDB.
Version:
Git Commit Hash: bf97f61c450912a5c1f4cfba44bb11297fa7876f
UTC Build Time:  20150913214037

tidb>

2.2 build
Godep go build -ldflags "-X github.com/pingcap/tidb/util/printer.TiDBBuildTS=%TiDBBuildTS% -X github.com/pingcap/tidb/util/printer.TiDBGitHash=%TiDBGitHash%"
TiDBBuildTS and TiDBGitHash variables are set in above 2.1

So u can see above, maybe some more work need to do in make.cmd.
And also, for unix/mac users, i think it is better to install make tool.
Thanks again, looking forward to your update :)

@insionng
Copy link
Contributor Author

It has been updated.

@fuxiaohei fuxiaohei mentioned this pull request Sep 15, 2015
@ngaut
Copy link
Member

ngaut commented Sep 15, 2015

Well done. Looks like we don't need make.sh.
Just keep make.cmd is fine. We could still use make instead of make.sh.
Could you please remove make.sh. Then we will merge this PR.
Thanks. @insionng

@c4pt0r
Copy link
Member

c4pt0r commented Sep 15, 2015

LGTM

@ngaut
Copy link
Member

ngaut commented Sep 15, 2015

LGTM. Thank you @insionng

ngaut added a commit that referenced this pull request Sep 15, 2015
@ngaut ngaut merged commit 3bf5e14 into pingcap:master Sep 15, 2015
@rapoth rapoth mentioned this pull request Aug 23, 2017
@sre-bot sre-bot added the contribution This PR is from a community contributor. label Dec 18, 2019
YuJuncen pushed a commit to YuJuncen/tidb that referenced this pull request Apr 23, 2021
xhebox pushed a commit to xhebox/tidb that referenced this pull request Sep 28, 2021
xhebox pushed a commit to xhebox/tidb that referenced this pull request Oct 8, 2021
okJiang pushed a commit to okJiang/tidb that referenced this pull request Oct 19, 2021
* close connection after export
nolouch pushed a commit to tidblabs/tidb that referenced this pull request Jan 6, 2023
…ase 6.4` rate limit (pingcap#155)

* merge pr#130,pingcap#133 into 6.4

Signed-off-by: zeminzhou <[email protected]>

* fix start limit rate

Signed-off-by: zeminzhou <[email protected]>

* default config

Signed-off-by: zeminzhou <[email protected]>

* keyspace: use `user_storage_size` instead of `storage_size` for ratelimit (pingcap#145)

* use user_storage_size instead of storage_size for ratelimit

Signed-off-by: zeminzhou <[email protected]>

* update golang.org/x/text to 0.3.8

Signed-off-by: zeminzhou <[email protected]>

* Fix error handle when loadKeyspace failed at startup (pingcap#143)

Signed-off-by: yongman <[email protected]>

Signed-off-by: yongman <[email protected]>

* add keyspace-activate mode (pingcap#142)

* fix loadkeyspace nil (pingcap#144)

* fix loadkeyspace nil

Signed-off-by: ystaticy <[email protected]>

* retry load keyspace

Signed-off-by: David <[email protected]>

* address comments

Signed-off-by: David <[email protected]>

Signed-off-by: ystaticy <[email protected]>
Signed-off-by: David <[email protected]>
Co-authored-by: David <[email protected]>

* Compatible with old pd

Signed-off-by: zeminzhou <[email protected]>

Signed-off-by: zeminzhou <[email protected]>
Signed-off-by: yongman <[email protected]>
Signed-off-by: ystaticy <[email protected]>
Signed-off-by: David <[email protected]>
Co-authored-by: yongman <[email protected]>
Co-authored-by: better0332 <[email protected]>
Co-authored-by: ystaticy <[email protected]>
Co-authored-by: David <[email protected]>

* make check

Signed-off-by: zeminzhou <[email protected]>

* fix confict

Signed-off-by: zeminzhou <[email protected]>

* make check

Signed-off-by: zeminzhou <[email protected]>

Signed-off-by: zeminzhou <[email protected]>
Signed-off-by: yongman <[email protected]>
Signed-off-by: ystaticy <[email protected]>
Signed-off-by: David <[email protected]>
Co-authored-by: yongman <[email protected]>
Co-authored-by: better0332 <[email protected]>
Co-authored-by: ystaticy <[email protected]>
Co-authored-by: David <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
contribution This PR is from a community contributor.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants