rpms/d4x/F-7 d4x-2.5.7.1-desktop.patch, NONE, 1.1 d4x-2.5.7.1-man.patch, NONE, 1.1 d4x-2.5.7.1-speed.patch, NONE, 1.1 d4x-2.5.7.1.makebuild.patch, NONE, 1.1 d4x.spec, 1.15, 1.16

Matthias Saou (thias) fedora-extras-commits at redhat.com
Sun Feb 3 18:26:38 UTC 2008


Author: thias

Update of /cvs/extras/rpms/d4x/F-7
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv14428/F-7

Modified Files:
	d4x.spec 
Added Files:
	d4x-2.5.7.1-desktop.patch d4x-2.5.7.1-man.patch 
	d4x-2.5.7.1-speed.patch d4x-2.5.7.1.makebuild.patch 
Log Message:
Include patch to fix slow download speed (#302121).


d4x-2.5.7.1-desktop.patch:

--- NEW FILE d4x-2.5.7.1-desktop.patch ---
diff -Naupr d4x-2.5.7.1.orig/share/nt.desktop d4x-2.5.7.1/share/nt.desktop
--- d4x-2.5.7.1.orig/share/nt.desktop	2005-08-31 15:32:13.000000000 +0200
+++ d4x-2.5.7.1/share/nt.desktop	2007-06-20 11:50:09.000000000 +0200
@@ -1,19 +1,19 @@
 [Desktop Entry]
 Name=Downloader for X
 Name[cs]=Downloader pro X
-Name[fr]=Downloader for X
+Name[fr]=Downloader pour X
 Name[es]=Downloader para X
 Name[de]=Downloader für X
 Name[pl]=Downloader dla X
 Name[ru]=Качалка для Иксов
-Comment=downloading program
+Comment=Downloading Program
 Comment[cs]=Program pro stahování souborů
 Comment[fr]=Programme de téléchargement de fichiers
-Comment[es]=Una herramienta para descagar ficheros
+Comment[es]=Herramienta de descaga de ficheros
 Comment[de]=Programm zum Downloaden von Dateien
 Comment[pl]=Program do pobierania plików z Internetu.
 Comment[ru]=программа для скачивания файлов
-Icon=nt.png
+Icon=d4x
 Exec=d4x
 TryExec=d4x
 Terminal=false

d4x-2.5.7.1-man.patch:

--- NEW FILE d4x-2.5.7.1-man.patch ---
diff -Naupr d4x-2.5.7.1.orig/DOC/nt.1 d4x-2.5.7.1/DOC/nt.1
--- d4x-2.5.7.1.orig/DOC/nt.1	2004-07-01 17:42:44.000000000 +0200
+++ d4x-2.5.7.1/DOC/nt.1	2007-06-20 11:45:02.000000000 +0200
@@ -1,13 +1,13 @@
 .TH NT 1 "March 7th, 2001"
 .SH NAME
-nt - A download manager for X
+d4x - A download manager for X
 .SH SYNOPSYS
-\fBnt\fP [OPTIONS] ... [URL]
+\fBd4x\fP [OPTIONS] ... [URL]
 .SH DESCRIPTION
-\fBnt\fP (also known as Downloader for X) is a Linux GUI program for
+\fBd4x\fP (also known as Downloader for X) is a Linux GUI program for
 downloading files from the Internet.  It supports FTP and HTTP (not completly
 yet but the current implementation is quite enough for downloading).  The
-program will resume interupted downloads if the server supports it too.  nt
+program will resume interupted downloads if the server supports it too. d4x 
 is like kget for Linux and ReGet or GetRight
 for Microsoft Windows (tm).
 .SH OPTIONS
@@ -15,7 +15,7 @@ Options are distinguished from URLs in t
 One may specify any number of options and URLs.
 
 Many of the options can be used to control a pre-existing
-instance of \fBnt\fP.  When \fBnt\fP finds an instance of itself already
+instance of \fBd4x\fP.  When \fBd4x\fP finds an instance of itself already
 running, it will forward the command to the already running instance for
 execution.  If there no pre-existing instance is found, then it will perform
 the requested operations itself.
@@ -23,12 +23,12 @@ the requested operations itself.
 The command line will be parsed from left to right.  This means that the
 requested operations will be performed in that order.
 .TP
-\fBnt\fP accepts the following options:
+\fBd4x\fP accepts the following options:
 .TP
 \fBURL\fP
 Add the indicated file to the download queue.  A dialog box will appear in
 which you can indicate where the file should be saved and set other options.
-If \fBnt\fP is already running, then the new instance will simply ask the
+If \fBd4x\fP is already running, then the new instance will simply ask the
 existing instance to add the file and then it will exit. If existing instance
 already have this \fBURL\fP in queue in inactive state than it will be
 moved to *wait* state.
@@ -65,7 +65,7 @@ Disable speed limit.
 .TP
 \fB-d, --directory PATH\fP
 Set directory for saving downloaded files.  This applies only to files
-added to an pre-existing instance by running the \fBnt\fP command with URLs
+added to an pre-existing instance by running the \fBd4x\fP command with URLs
 on the command line.
 .TP
 \fB-c, --delete-completed\fP
@@ -77,7 +77,7 @@ Rerun all failed downloads.
 \fB-w, --without-face\fP
 Start Downloader without X interface.  (It will display the log on stdout but
 there will be no user interface of any kind.  The only way to control it is by
-running \fBnt\fP with appropriate options.)
+running \fBd4x\fP with appropriate options.)
 .TP
 \fB-m, --max-running integer\fP
 Set the maximum total number of active downloads for current queue.

d4x-2.5.7.1-speed.patch:

--- NEW FILE d4x-2.5.7.1-speed.patch ---
--- d4x-2.5.7.1.orig/main/signal.cc
+++ d4x-2.5.7.1/main/signal.cc
@@ -89,7 +89,7 @@
 
 
 void my_pthreads_mutex_init(pthread_mutex_t *lock){
-#if defined(__linux__)
+#if defined(__linux__) || defined(__GLIBC__)
 /* manual page for mutexes said that mutexes in linux is fast by
    default...
  */
--- d4x-2.5.7.1.orig/main/socket.cc
+++ d4x-2.5.7.1/main/socket.cc
@@ -165,10 +165,10 @@
 		return(SOCKET_CANT_ALLOCATE);
 	int a=1;
 	setsockopt(fd,SOL_SOCKET,SO_KEEPALIVE,(char *)&a,sizeof(a));
-	setsockopt(fd,SOL_SOCKET,SO_KEEPALIVE,(char *)&a,sizeof(a));
+	//setsockopt(fd,SOL_SOCKET,SO_KEEPALIVE,(char *)&a,sizeof(a));
 	
 	size_t sl=2000; //set receive buffer to default+30% MTU size
-	setsockopt(fd,SOL_SOCKET,SO_RCVBUF,(char *)&sl,sizeof(sl));
+	//setsockopt(fd,SOL_SOCKET,SO_RCVBUF,(char *)&sl,sizeof(sl));
 
 	if (!connect_impl())
 		return(SOCKET_CANT_CONNECT);

d4x-2.5.7.1.makebuild.patch:

--- NEW FILE d4x-2.5.7.1.makebuild.patch ---
diff -Naupr d4x-2.5.7.1.orig/configure d4x-2.5.7.1/configure
--- d4x-2.5.7.1.orig/configure	2006-04-12 18:48:29.000000000 +0200
+++ d4x-2.5.7.1/configure	2008-02-03 19:06:53.000000000 +0100
@@ -18398,11 +18398,6 @@ _ACEOF
 
 
 cat >>confdefs.h <<\_ACEOF
-#define GTK_DISABLE_DEPRECATED
-_ACEOF
-
-
-cat >>confdefs.h <<\_ACEOF
 #define _FILE_OFFSET_BITS 64
 _ACEOF
 
diff -Naupr d4x-2.5.7.1.orig/configure.ac d4x-2.5.7.1/configure.ac
--- d4x-2.5.7.1.orig/configure.ac	2005-11-05 00:35:38.000000000 +0100
+++ d4x-2.5.7.1/configure.ac	2008-02-03 19:06:44.000000000 +0100
@@ -298,7 +298,6 @@ AC_DEFINE_UNQUOTED(D4X_SHARE_PATH,
 
 # Other needed defines
 AC_DEFINE(_REENTRANT, , [Enable reenrant code of glibc])
-AC_DEFINE(GTK_DISABLE_DEPRECATED, , [Enable warnings about deprecated functions usage])
 AC_DEFINE(_FILE_OFFSET_BITS, 64, [To support files over 2GB])
 
 # Prepare all requiered flags
diff -Naupr d4x-2.5.7.1.orig/main/face/list.cc d4x-2.5.7.1/main/face/list.cc
--- d4x-2.5.7.1.orig/main/face/list.cc	2006-03-20 01:29:41.000000000 +0100
+++ d4x-2.5.7.1/main/face/list.cc	2008-02-03 19:06:44.000000000 +0100
@@ -8,8 +8,6 @@
  *	but WITHOUT ANY WARRANTY; without even the implied warranty of
  *	MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  */
-#define GTK_DISABLE_DEPRECATED
-
 #include <stdio.h>
 #include <gtk/gtk.h>
 #include <gdk/gdkkeysyms.h>


Index: d4x.spec
===================================================================
RCS file: /cvs/extras/rpms/d4x/F-7/d4x.spec,v
retrieving revision 1.15
retrieving revision 1.16
diff -u -r1.15 -r1.16
--- d4x.spec	23 Nov 2006 13:36:16 -0000	1.15
+++ d4x.spec	3 Feb 2008 18:25:57 -0000	1.16
@@ -1,21 +1,19 @@
-#define pre            rc4
-#define final          final
-
 Summary: Downloader for X that supports resuming and many other features
 Name: d4x
 Version: 2.5.7.1
-Release: 3%{?pre:.%{pre}}%{?dist}
+Release: 8%{?dist}
 Group: Applications/Internet
 License: Artistic
 URL: http://www.krasu.ru/soft/chuchelo/
-Source: http://d4x.krasu.ru/files/d4x-%{version}%{?pre}%{?final}.tar.bz2
+Source: http://d4x.krasu.ru/files/d4x-%{version}.tar.bz2
+Patch0: d4x-2.5.7.1-man.patch
+Patch1: d4x-2.5.7.1-desktop.patch
+Patch2: d4x-2.5.7.1.makebuild.patch
+Patch3: d4x-2.5.7.1-speed.patch
 Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root
 BuildRequires: gtk2-devel, libao-devel, openssl-devel
 BuildRequires: desktop-file-utils, boost-devel
-# Use modular X for FC5+ and non-Fedora
-%if %{!?fedora:6}%{?fedora} >= 5
 BuildRequires: libXt-devel
-%endif
 
 %description
 This program lets you download files from the internet using either the ftp
@@ -27,7 +25,21 @@
 
 
 %prep
-%setup -n %{name}-%{version}%{?pre}%{?final}
+%setup -q
+%patch0 -p1 -b .man
+%patch1 -p1 -b .desktop
+%patch2 -p1 -b .makebuild
+%patch3 -p1 -b .speed
+# Move the desktop file we just patched to the proper name
+%{__mv} share/nt.desktop share/d4x.desktop
+# Convert some docs to UTF-8, keeping their original timestamps
+for file in DOC/FAQ.* NEWS; do
+    cp -a ${file} tmp
+    iconv -f iso8859-1 -t utf-8 tmp > ${file}
+    touch -r tmp ${file}
+    rm -f tmp
+done
+
 
 %build
 %configure --enable-libao
@@ -36,39 +48,79 @@
 
 %install
 %{__rm} -rf %{buildroot}
-%makeinstall
+%{__make} install DESTDIR=%{buildroot}
 %find_lang %{name}
 
+# Install the menu entry icon
+%{__install} -D -p -m 0644 share/nt.png \
+    %{buildroot}%{_datadir}/icons/hicolor/48x48/apps/d4x.png
+
 # Now the menu entry
-%{__install} -m 0644 -D share/nt.png %{buildroot}%{_datadir}/pixmaps/nt.png
 %{__mkdir_p} %{buildroot}%{_datadir}/applications
-desktop-file-install --vendor fedora \
-  --dir %{buildroot}%{_datadir}/applications \
-  --add-category Application \
-  --add-category Network \
-  share/nt.desktop
+desktop-file-install \
+    --vendor "" \
+    --dir %{buildroot}%{_datadir}/applications \
+    --add-category Network \
+    share/d4x.desktop
 
 # Rename the man page to match the binary name
 rename nt.1 d4x.1 %{buildroot}%{_mandir}/man1/nt.1*
 
+# Rename the main binary too, overwriting the "d4x" symlink
+%{__mv} -f %{buildroot}%{_bindir}/nt %{buildroot}%{_bindir}/d4x
+
 
 %clean
 %{__rm} -rf %{buildroot}
 
 
+%post
+touch --no-create %{_datadir}/icons/hicolor || :
+%{_bindir}/gtk-update-icon-cache --quiet %{_datadir}/icons/hicolor || :
+
+%postun
+touch --no-create %{_datadir}/icons/hicolor || :
+%{_bindir}/gtk-update-icon-cache --quiet %{_datadir}/icons/hicolor || :
+
+
 %files -f %{name}.lang
-%defattr(-, root, root, 0755)
-%doc AUTHORS ChangeLog* COPYING NEWS PLANS README TODO
+%defattr(-,root,root,-)
+%doc AUTHORS ChangeLog COPYING NEWS PLANS README TODO
 %doc DOC/FAQ* DOC/THANKS DOC/TROUBLES
 %{_bindir}/d4x
-%{_bindir}/nt
-%{_datadir}/applications/fedora-nt.desktop
+%{_datadir}/applications/d4x.desktop
 %{_datadir}/d4x/
-%{_datadir}/pixmaps/nt.png
+%{_datadir}/icons/hicolor/48x48/apps/d4x.png
 %{_mandir}/man1/d4x.1*
 
 
 %changelog
+* Sun Feb  3 2008 Matthias Saou <http://freshrpms.net/> 2.5.7.1-8
+- Rebuild with the changes from Mon Sep 24 2007 merged back in.
+- Replace autoconf run with a few more lines to the makebuild patch.
+
+* Sat Jan  5 2008 Alex Lancaster <alexlan[AT]fedoraproject org> - 2.5.7.1-7
+- Add patch by Caolan McNamara (#427620) to build against new openssl
+
+* Wed Dec 05 2007 Release Engineering <rel-eng at fedoraproject dot org> - 2.5.7.1-6
+ - Rebuild for deps
+
+* Mon Sep 24 2007 Matthias Saou <http://freshrpms.net/> 2.5.7.1-6
+- Include patch to fix slow download speeds (#302121).
+- Convert doc files to UTF-8.
+
+* Fri Aug 31 2007 Matthias Saou <http://freshrpms.net/> 2.5.7.1-5
+- Rebuild for new BuildID feature.
+- License is still original Artistic, but this should be fixed shortly.
+
+* Wed Jun 20 2007 Matthias Saou <http://freshrpms.net/> 2.5.7.1-4
+- Switch to using the DESTDIR install method.
+- Remove old X build requirement conditional.
+- Remove vendor prefix and useless Application category from desktop file.
+- Patch the man page to s/nt/d4x/.
+- Add patch for the desktop entry, minor fixes and search the icon as "d4x".
+- Don't include old ChangeLog files.
+
 * Tue Nov 21 2006 Víctor Daniel <bombayvdmo at yahoo.com.mx> 2.5.7.1-3
 - Change man page rename to work when compression is set in /etc/man.config.
 




More information about the fedora-extras-commits mailing list