Skip to content

Commit 81689a7

Browse files
KenoKristofferC
authored andcommitted
Small tweak to embedding.md (#34422)
Adds -rpath to the link line which was suggested in #28982 and removes the line about JULIA_BINDIR, which isn't necessary anymore, since we autodetect the directory. Also remove the reference to libstdc++. If you built julia yourself, it's definitely compatible with the system one. If not, we now build julia binary distributions with wide compatibility with different libstdc++ versions, so the system one should be fine.
1 parent 64e72f1 commit 81689a7

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

doc/src/manual/embedding.md

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -41,12 +41,9 @@ and link against `libjulia`. For instance, when Julia is installed to `$JULIA_DI
4141
the above test program `test.c` with `gcc` using:
4242
4343
```
44-
gcc -o test -fPIC -I$JULIA_DIR/include/julia -L$JULIA_DIR/lib test.c -ljulia $JULIA_DIR/lib/julia/libstdc++.so.6
44+
gcc -o test -fPIC -I$JULIA_DIR/include/julia -L$JULIA_DIR/lib -Wl,-rpath,$JULIA_DIR/lib test.c -ljulia
4545
```
4646
47-
Then if the environment variable `JULIA_BINDIR` is set to `$JULIA_DIR/bin`, the output `test` program
48-
can be executed.
49-
5047
Alternatively, look at the `embedding.c` program in the Julia source tree in the `test/embedding/` folder.
5148
The file `ui/repl.c` program is another simple example of how to set `jl_options` options while
5249
linking against `libjulia`.

0 commit comments

Comments
 (0)