mirror of
https://github.com/minio/minio.git
synced 2024-12-24 06:05:55 -05:00
Add git and mercurial as dependencies
This commit is contained in:
parent
69ae3b3310
commit
c3fca84f25
@ -1,6 +1,16 @@
|
||||
### Build Dependencies
|
||||
This installation document assumes Ubuntu 12.04 or later on x86-64.
|
||||
|
||||
##### Install Git and GCC
|
||||
```sh
|
||||
$ sudo apt-get install git build-essential
|
||||
```
|
||||
|
||||
##### Install Mercurial
|
||||
```sh
|
||||
$ sudo apt-get install mercurial
|
||||
```
|
||||
|
||||
##### Install YASM
|
||||
```sh
|
||||
$ sudo apt-get install yasm
|
||||
|
5
Makefile
5
Makefile
@ -3,7 +3,10 @@ MAKE_OPTIONS := -s
|
||||
|
||||
all: getdeps cover install
|
||||
|
||||
getdeps:
|
||||
checkdeps:
|
||||
@./checkdeps.sh
|
||||
|
||||
getdeps: checkdeps
|
||||
@go get github.com/tools/godep && echo "Installing godep"
|
||||
@go get code.google.com/p/go.tools/cmd/cover && echo "Installing cover"
|
||||
|
||||
|
36
checkdeps.sh
Executable file
36
checkdeps.sh
Executable file
@ -0,0 +1,36 @@
|
||||
#!/bin/sh
|
||||
|
||||
echo -n "Checking dependencies for Minio.. "
|
||||
|
||||
## Check all dependencies are present
|
||||
MISSING=""
|
||||
|
||||
env git --version > /dev/null 2>&1
|
||||
if [ $? -ne 0 ]; then
|
||||
MISSING="${MISSING} git"
|
||||
fi
|
||||
|
||||
env hg --version > /dev/null 2>&1
|
||||
if [ $? -ne 0 ]; then
|
||||
MISSING="${MISSING} mercurial"
|
||||
fi
|
||||
|
||||
env gcc --version > /dev/null 2>&1
|
||||
if [ $? -ne 0 ]; then
|
||||
MISSING="${MISSING} build-essential"
|
||||
fi
|
||||
|
||||
## If dependencies are missing, warn the user and abort
|
||||
if [ "x${MISSING}" != "x" ]; then
|
||||
echo "ERROR"
|
||||
echo
|
||||
echo "The following build tools are missing:"
|
||||
echo
|
||||
echo "** ${MISSING} **"
|
||||
echo
|
||||
echo "Please install them "
|
||||
echo "$ sudo apt-get install ${MISSING}"
|
||||
echo
|
||||
exit 1
|
||||
fi
|
||||
echo "SUCCESS"
|
Loading…
Reference in New Issue
Block a user