--- Makefile.old	2012-04-26 21:40:25.277417417 +0200
+++ Makefile	2012-04-26 21:43:34.300835150 +0200
@@ -344,11 +344,11 @@
   endif
   
   ifeq ($(USE_CIN_THEORA),1)
-    CLIENT_LDFLAGS += -ltheora
+    CLIENT_LIBS += -ltheora
   endif
   
   ifeq ($(USE_CODEC_MP3),1)
-    CLIENT_LDFLAGS += -lmad
+    CLIENT_LIBS += -lmad
   endif
 
   ifeq ($(USE_CURL),1)
@@ -380,12 +380,12 @@
   
   ifeq ($(USE_CIN_THEORA),1)
     BASE_CFLAGS += -DUSE_CIN_THEORA
-    CLIENT_LDFLAGS += -ltheora
+    CLIENT_LIBS += -ltheora
   endif
   
   ifeq ($(USE_CODEC_MP3),1)
     BASE_CFLAGS += -DUSE_CODEC_MP3
-    CLIENT_LDFLAGS += -lmad
+    CLIENT_LIBS += -lmad
   endif
 else # ifeq Linux
 
@@ -435,12 +435,12 @@
   
    ifeq ($(USE_CIN_THEORA),1)
     BASE_CFLAGS += -DUSE_CIN_THEORA
-    CLIENT_LDFLAGS += -ltheora
+    CLIENT_LIBS += -ltheora
   endif
   
   ifeq ($(USE_CODEC_MP3),1)
     BASE_CFLAGS += -DUSE_CODEC_MP3
-    CLIENT_LDFLAGS += -lmad
+    CLIENT_LIBS += -lmad
   endif
 
   BASE_CFLAGS += -D_THREAD_SAFE=1
@@ -565,7 +565,7 @@
   endif
 
   ifeq ($(USE_CODEC_MP3),1)
-    CLIENT_LDFLAGS += -lmad
+    CLIENT_LIBS += -lmad
   endif
 
   ifeq ($(ARCH),x86)
@@ -662,11 +662,11 @@
   endif
   
   ifeq ($(USE_CIN_THEORA),1)
-    CLIENT_LDFLAGS += -ltheora
+    CLIENT_LIBS += -ltheora
   endif
   
   ifeq ($(USE_CODEC_MP3),1)
-    CLIENT_LDFLAGS += -lmad
+    CLIENT_LIBS += -lmad
   endif
 
   # cross-compiling tweaks
@@ -732,11 +732,11 @@
   endif
   
   ifeq ($(USE_CIN_THEORA),1)
-    CLIENT_LDFLAGS += -ltheora
+    CLIENT_LIBS += -ltheora
   endif
   
   ifeq ($(USE_CODEC_MP3),1)
-    CLIENT_LDFLAGS += -lmad
+    CLIENT_LIBS += -lmad
   endif
 
   ifeq ($(USE_CURL),1) 
@@ -1780,7 +1780,7 @@
 
 $(B)/wop-smp$(FULLBINEXT): $(Q3OBJ) $(Q3ROBJ) $(Q3POBJ_SMP) $(LIBSDLMAIN)
 	$(echo_cmd) "LD $@"
- 	$(Q)$(CC) $(CLIENT_CFLAGS) $(CFLAGS) $(CLIENT_LDFLAGS) $(LDFLAGS) $(THREAD_LDFLAGS) \
+	$(Q)$(CC) $(CLIENT_CFLAGS) $(CFLAGS) $(CLIENT_LDFLAGS) $(LDFLAGS) $(THREAD_LDFLAGS) \
 		-o $@ $(Q3OBJ) $(Q3ROBJ) $(Q3POBJ_SMP) \
  		$(THREAD_LIBS) $(LIBSDLMAIN) $(CLIENT_LIBS) $(RENDERER_LIBS) $(LIBS)
 endif