Skip to content

Commit ee47ee4

Browse files
committed
CXX-2116 document rpath for non-standard install location
1 parent 91be57e commit ee47ee4

File tree

1 file changed

+10
-0
lines changed
  • docs/content/mongocxx-v3/installation

1 file changed

+10
-0
lines changed

Diff for: docs/content/mongocxx-v3/installation/linux.md

+10
Original file line numberDiff line numberDiff line change
@@ -100,6 +100,16 @@ cmake .. \
100100
-DCMAKE_INSTALL_PREFIX=/usr/local
101101
```
102102

103+
If installing to a non-standard directory (i.e., one which the dynamic loader does not search),
104+
consider specifying the `-DCMAKE_INSTALL_RPATH=` option:
105+
106+
```
107+
cmake .. \
108+
-DCMAKE_BUILD_TYPE=Release \
109+
-DCMAKE_INSTALL_PREFIX=/opt/mongo \
110+
-DCMAKE_INSTALL_RPATH=/opt/mongo
111+
```
112+
103113
In the Unix examples that follow, `mongocxx` is customized in these ways:
104114

105115
* `libmongoc` is found in `/opt/mongo-c-driver`.

0 commit comments

Comments
 (0)