diff --git a/src/Makefile b/src/Makefile index b9fa5994a..57b89091d 100644 --- a/src/Makefile +++ b/src/Makefile @@ -1,5 +1,5 @@ CC=gcc -LIBS=-lGL -lcurl -lopenal -lpthread -lX11 -lm +LIBS=-lGL -lcurl -lopenal -lpthread -lX11 -lm -ldl CFLAGS=-g -w -no-pie -rdynamic SOURCES=$(wildcard *.c) OBJECTS=$(patsubst %.c, %.o, $(SOURCES)) diff --git a/src/Platform.c b/src/Platform.c index f8ee6f15b..a45fb6307 100644 --- a/src/Platform.c +++ b/src/Platform.c @@ -62,6 +62,7 @@ ReturnCode ReturnCode_SocketWouldBlock = WSAEWOULDBLOCK; #include #include #include +#include #include #include #include @@ -1902,7 +1903,7 @@ ReturnCode Platform_LoadLibrary(const String* path, void** lib) { } ReturnCode Platform_GetSymbol(void* lib, const char* name, void** symbol) { - *symbol = GetProcAddress(lib, symbol); + *symbol = GetProcAddress(lib, name); return Win_Return(*symbol); } #endif