Sophie

Sophie

distrib > Fedora > 15 > i386 > by-pkgid > 2dc62da59542d11fbfc6032d739f6dbb > files > 1

linuxdcpp-1.0.3-5.fc15.src.rpm

diff -ur linuxdcpp-1.0.2-orig/client/SConstruct linuxdcpp-1.0.2/client/SConstruct
--- linuxdcpp-1.0.2-orig/client/SConstruct	2008-05-04 20:55:24.000000000 +0200
+++ linuxdcpp-1.0.2/client/SConstruct	2008-09-21 22:37:32.000000000 +0200
@@ -45,7 +45,10 @@
 
 Import('env')
 
+env_client = env.Clone()
+env_client.ParseConfig('pkg-config --cflags glib-2.0')
+
 # Build the client_files
-clientObjs = env.Object(client_files)
+clientObjs = env_client.Object(client_files)
 
 Return('clientObjs')
diff -ur linuxdcpp-1.0.2-orig/client/SettingsManager.cpp linuxdcpp-1.0.2/client/SettingsManager.cpp
--- linuxdcpp-1.0.2-orig/client/SettingsManager.cpp	2008-05-04 20:55:25.000000000 +0200
+++ linuxdcpp-1.0.2/client/SettingsManager.cpp	2008-09-21 22:38:17.000000000 +0200
@@ -16,6 +16,8 @@
  * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
  */
 
+#include <glib.h>
+
 #include "stdinc.h"
 #include "DCPlusPlus.h"
 
@@ -112,7 +114,10 @@
 		int64Settings[k] = 0;
 	}
 
-	setDefault(DOWNLOAD_DIRECTORY, Util::getConfigPath() + "Downloads" PATH_SEPARATOR_STR);
+	const char* xdgDir = g_get_user_special_dir(G_USER_DIRECTORY_DOWNLOAD);
+	const string downloadDir = xdgDir ? string(xdgDir) + PATH_SEPARATOR_STR : Util::getConfigPath() + "Downloads" PATH_SEPARATOR_STR;
+
+	setDefault(DOWNLOAD_DIRECTORY, downloadDir);
 	setDefault(TEMP_DOWNLOAD_DIRECTORY, Util::getConfigPath() + "Incomplete" PATH_SEPARATOR_STR);
 	setDefault(SLOTS, 1);
 	setDefault(TCP_PORT, 0);
diff -ur linuxdcpp-1.0.2-orig/SConstruct linuxdcpp-1.0.2/SConstruct
--- linuxdcpp-1.0.2-orig/SConstruct	2008-07-03 05:54:11.000000000 +0200
+++ linuxdcpp-1.0.2/SConstruct	2008-09-21 22:37:32.000000000 +0200
@@ -126,6 +126,11 @@
 		print '\tNote: You might have the lib but not the headers'
 		Exit(1)
 
+	if not conf.CheckPKG('glib-2.0 >= 2.14'):
+		print '\tglib >= 2.14 not found.'
+		print '\tNote: You might have the lib but not the headers'
+		Exit(1)
+
 	if not conf.CheckHeader('time.h'):
 		Exit(1)