Skip to content

Commit 69906e4

Browse files
committed
Linux: also try opening libcurl.so.4;
1 parent 83057c9 commit 69906e4

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ Implementation
9090
`lovr-http` uses system-provided HTTP libraries:
9191

9292
- Windows uses wininet.
93-
- Linux uses curl (must be installed, but most systems have it).
93+
- Linux uses curl (must install e.g. `libcurl4` package, but most systems have it).
9494
- Android uses Java's HttpURLConnection via JNI.
9595
- macOS uses NSURLSession.
9696

http.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -500,7 +500,8 @@ static struct {
500500
static void* library;
501501

502502
static void http_init(void) {
503-
library = dlopen("libcurl.so", RTLD_LAZY);
503+
library = dlopen("libcurl.so.4", RTLD_LAZY);
504+
if (!library) library = dlopen("libcurl.so", RTLD_LAZY);
504505

505506
if (library) {
506507
FN_FOREACH(FN_LOAD)

0 commit comments

Comments
 (0)