Add a few small consistency tweaks in hack

This commit is contained in:
Tianon Gravi 2013-10-17 23:36:28 -06:00 committed by Victor Vieux
parent dbe7d67c18
commit fb8d488896
4 changed files with 6 additions and 9 deletions

View File

@ -40,7 +40,6 @@ To build docker, you will need the following system dependencies
* A clean checkout of the source must be added to a valid Go [workspace](http://golang.org/doc/code.html#Workspaces) * A clean checkout of the source must be added to a valid Go [workspace](http://golang.org/doc/code.html#Workspaces)
under the path *src/github.com/dotcloud/docker*. See under the path *src/github.com/dotcloud/docker*. See
## Go dependencies ## Go dependencies
All Go dependencies are vendored under ./vendor. They are used by the official build, All Go dependencies are vendored under ./vendor. They are used by the official build,
@ -55,7 +54,6 @@ NOTE: if you''re not able to package the exact version (to the exact commit) of
please get in touch so we can remediate! Who knows what discrepancies can be caused by even the please get in touch so we can remediate! Who knows what discrepancies can be caused by even the
slightest deviation. We promise to do our best to make everybody happy. slightest deviation. We promise to do our best to make everybody happy.
## Disabling CGO ## Disabling CGO
Make sure to disable CGO on your system, and then recompile the standard library on the build Make sure to disable CGO on your system, and then recompile the standard library on the build
@ -71,7 +69,7 @@ cd /tmp && echo 'package main' > t.go && go test -a -i -v
To build the docker binary, run the following command with the source checkout as the To build the docker binary, run the following command with the source checkout as the
working directory: working directory:
``` ```bash
./hack/make.sh binary ./hack/make.sh binary
``` ```
@ -82,7 +80,7 @@ You are encouraged to use ./hack/make.sh without modification. If you must absol
your own script (are you really, really sure you need to? make.sh is really not that complicated), your own script (are you really, really sure you need to? make.sh is really not that complicated),
then please take care the respect the following: then please take care the respect the following:
* In *./hack/make.sh*: $LDFLAGS, $VERSION and $GITCOMMIT * In *./hack/make.sh*: $LDFLAGS, $BUILDFLAGS, $VERSION and $GITCOMMIT
* In *./hack/make/binary*: the exact build command to run * In *./hack/make/binary*: the exact build command to run
You may be tempted to tweak these settings. In particular, being a rigorous maintainer, you may want You may be tempted to tweak these settings. In particular, being a rigorous maintainer, you may want
@ -106,7 +104,6 @@ dependencies to be installed (see below).
The test suite will also download a small test container, so you will need internet connectivity. The test suite will also download a small test container, so you will need internet connectivity.
## Runtime dependencies ## Runtime dependencies
To run properly, docker needs the following software to be installed at runtime: To run properly, docker needs the following software to be installed at runtime:
@ -133,6 +130,6 @@ for your distro''s process supervisor of choice.
Docker should be run as root, with the following arguments: Docker should be run as root, with the following arguments:
``` ```bash
docker -d docker -d
``` ```

View File

@ -48,7 +48,6 @@ fi
LDFLAGS='-X main.GITCOMMIT "'$GITCOMMIT'" -X main.VERSION "'$VERSION'" -w -linkmode external -extldflags "-lpthread -static -Wl,--unresolved-symbols=ignore-in-object-files"' LDFLAGS='-X main.GITCOMMIT "'$GITCOMMIT'" -X main.VERSION "'$VERSION'" -w -linkmode external -extldflags "-lpthread -static -Wl,--unresolved-symbols=ignore-in-object-files"'
BUILDFLAGS='-tags netgo' BUILDFLAGS='-tags netgo'
bundle() { bundle() {
bundlescript=$1 bundlescript=$1
bundle=$(basename $bundlescript) bundle=$(basename $bundlescript)

View File

@ -1,3 +1,5 @@
#!/bin/sh
DEST=$1 DEST=$1
set -e set -e

View File

@ -3,8 +3,7 @@
DEST=$1 DEST=$1
PKGVERSION="$VERSION" PKGVERSION="$VERSION"
if test -n "$(git status --porcelain)" if [ -n "$(git status --porcelain)" ]; then
then
PKGVERSION="$PKGVERSION-$(date +%Y%m%d%H%M%S)-$GITCOMMIT" PKGVERSION="$PKGVERSION-$(date +%Y%m%d%H%M%S)-$GITCOMMIT"
fi fi