Skip to content

Commit 2a60a18

Browse files
jfinzelgunnarmorling
authored andcommitted
Clarify build instructions
1 parent c5068d5 commit 2a60a18

File tree

1 file changed

+16
-6
lines changed

1 file changed

+16
-6
lines changed

README.md

Lines changed: 16 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,11 @@ This code depends on the following libraries and requires them for compilation:
2222

2323
## Building
2424

25-
To build you will need to install PostgreSQL (for pg_config), PostgreSQL server development packages, protobuf-c for the
26-
Protocol Buffer support and some PostGIS development packages
25+
`postgres-decoderbufs` has to be built from source after installing required dependencies. The required dependencies are first PostgreSQL
26+
(for pg_config), PostgreSQL server development packages, protobuf-c for the Protocol Buffer support and some PostGIS development packages.
2727

28-
### Debian
28+
### Installing Dependencies
29+
#### Debian
2930

3031
# Core build utilities
3132
apt-get update && apt-get install -f -y software-properties-common build-essential pkg-config git postgresql-server-dev-9.6
@@ -39,14 +40,23 @@ Protocol Buffer support and some PostGIS development packages
3940

4041
The above are taken from the Debezium [docker images](https://github.com/debezium/docker-images).
4142

42-
### Other Linux distributions
43+
#### Other Linux distributions
4344

4445
You just need to make sure the above software packages (_or some flavour thereof_) are installed for your distro.
4546
Note that the last step from the above sequence is only required for Debian to be able to install `libprotobuf-c-dev:1.2.1`
4647

47-
If you have all of the prerequisites installed you should be able to just:
48+
### Building and installing decoderbufs
4849

49-
make && make install
50+
If you have all of the above prerequisites installed, clone this git repo to build from source. If you have multiple
51+
postgres versions installed, you can select which version to install by altering your `$PATH` to point to the right version.
52+
Then `make` and `make install` for each version. Here is an example:
53+
54+
git clone https://github.com/debezium/postgres-decoderbufs.git
55+
cd postgres-decoderbufs
56+
# Install for Postgres 9.6 if I have multiple local versions
57+
export PATH=/usr/lib/postgresql/9.6/bin:$PATH
58+
make
59+
make install
5060

5161
Once the extension has been installed you just need to enable it and logical replication in postgresql.conf:
5262

0 commit comments

Comments
 (0)