Skip to content

Commit 3a8d0d9

Browse files
committed
Update Linux build instructions in Packages/README.md.
1 parent 24dc1bf commit 3a8d0d9

File tree

1 file changed

+36
-32
lines changed

1 file changed

+36
-32
lines changed

Packages/README.md

Lines changed: 36 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -8,62 +8,67 @@ Follow these steps to build and run them on Linux.
88
## Prerequisites
99

1010
These instructions are for running in the Docker container manager,
11-
but can be directly used on any Ubuntu 14.04 image.
11+
but can be directly used on any Ubuntu 16.04 image.
1212

1313
## Start Docker
1414

1515
Start a docker instance with the following command:
1616

17-
`docker run -i -t --privileged=true ubuntu:14.04 /bin/bash`
17+
`docker run -i -t --privileged=true ubuntu:16.04 /bin/bash`
1818

1919
## Install Dependencies
2020

2121
# update package list
2222
apt-get update
2323
# install download tools
24-
apt-get install git wget -y
24+
apt-get install -y git wget
25+
# install a few useful utilities
26+
apt-get install -y vim sudo
2527
# install grpc build dependencies
26-
apt-get install build-essential autoconf libtool -y
28+
apt-get install -y build-essential autoconf libtool
2729
# install swift dependencies
28-
apt-get install clang libicu-dev libedit-dev python-dev libxml2-dev -y
30+
apt-get install -y clang libicu-dev libedit-dev python-dev libxml2-dev
31+
# install networking dependencies
32+
apt-get install -y libcurl4-openssl-dev
2933

3034
## Install Swift
3135

3236
# go to /root
33-
cd
37+
cd
3438
# download and unpack swift
35-
wget https://swift.org/builds/swift-3.0-preview-3/ubuntu1404/swift-3.0-PREVIEW-3/swift-3.0-PREVIEW-3-ubuntu14.04.tar.gz
36-
tar xzf swift-3.0-PREVIEW-3-ubuntu14.04.tar.gz
39+
wget https://swift.org/builds/swift-3.0.1-release/ubuntu1604/swift-3.0.1-RELEASE/swift-3.0.1-RELEASE-ubuntu16.04.tar.gz
40+
tar xzf swift-3.0.1-RELEASE-ubuntu16.04.tar.gz
41+
ln -s swift-3.0.1-RELEASE-ubuntu16.04 swift
3742

3843
## Add Swift to your path
44+
# add swift to your path by adding this to your .bashrc
45+
export PATH=/root/swift/usr/bin:$PATH
3946

40-
# add swift to your path by adding this to your .bashrc
41-
export SWIFT=swift-3.0-PREVIEW-3-ubuntu14.04
42-
export PATH=/root/$SWIFT/usr/bin:$PATH
43-
44-
# Then run this to update your path
45-
source ~/.bashrc
47+
# Then run this to update your path
48+
source ~/.bashrc
4649

4750
## Configure git
4851

49-
git config --global user.email <your email address>
50-
git config --global user.name "<your name>"
52+
git config --global user.email <your email address>
53+
git config --global user.name "<your name>"
5154

5255
## Fetch and build grpc
53-
git clone https://github.com/timburks/grpc
54-
cd grpc
55-
git submodule update --init
56-
git checkout swift
57-
make
58-
make install
56+
git clone https://github.com/grpc/grpc-swift
57+
cd grpc-swift
58+
git submodule update --init
59+
cd third_party/grpc
60+
git submodule update --init
61+
make
62+
make install
5963

6064
## Build the gRPC packages
61-
cd src/swift/Packages/
62-
cd CgRPC; make; cd ..
63-
cd gRPC; make; cd ..
64-
cd Server; make; make install; cd ..
65-
cd Client; make; make install; cd ..
66-
65+
cd
66+
cd grpc-swift/Packages
67+
cd CgRPC; make; cd ..
68+
cd gRPC; make; cd ..
69+
cd Server; make; make install; cd ..
70+
cd Client; make; make install; cd ..
71+
6772
It may be necessary to run `make` multiple times in the Server and Client directories.
6873
If you see an error like the following, please retry running `make`.
6974

@@ -77,8 +82,7 @@ If you see an error like the following, please retry running `make`.
7782
No submodule mapping found in .gitmodules for path 'Packages/CgRPC-1.0.0'
7883
error: Git 2.0 or higher is required. Please update git and retry.
7984
make: *** [all] Error 1
80-
85+
8186
## Run the test client and server from the grpc/src/swift/Packages directory:
82-
Server/Server &
83-
Client/Client
84-
87+
Server/Server &
88+
Client/Client

0 commit comments

Comments
 (0)