Description: Fix FTBFS with ld --as-needed.
 Order of linker option matters. 
Author: Matthias Klose <doko@ubuntu.com>
Origin: ubuntu, http://launchpadlibrarian.net/79980054/hoichess_0.10.3-5_0.10.3-5ubuntu1.diff.gz
Bug-Debian: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=641727
Forwarded: no
Reviewed-By: Oliver Korff <ok@xynyx.de>
Last-Update: <2011-10-13>


--- a/src/Makefile
+++ b/src/Makefile
@@ -112,7 +112,7 @@
 # link object files
 $(BIN_CHESS) $(BIN_XIANGQI):
 	@mkdir -p $(dir $@)
-	$(CXX) $(CXXFLAGS) $(LDFLAGS) $(LIBPATH) $(LIBS) -o $@ $^
+	$(CXX) $(CXXFLAGS) $(LDFLAGS) $(LIBPATH) -o $@ $^ $(LIBS)
 
 # compile source files
 $(BUILDDIR_CHESS)/%.o $(BUILDDIR_XIANGQI)/%.o: %.cc Makefile Makefile.local
