فهرست منبع

upgrading package: fetchmail 6.2.5 -> 6.2.9rc9

Ralf S. Engelschall 20 سال پیش
والد
کامیت
27cab89eba
2فایلهای تغییر یافته به همراه23 افزوده شده و 66 حذف شده
  1. 0 49
      fetchmail/fetchmail.patch
  2. 23 17
      fetchmail/fetchmail.spec

+ 0 - 49
fetchmail/fetchmail.patch

@@ -10,52 +10,3 @@ Index: socket.c
  #include <ctype.h> /* isspace() */
  #ifdef HAVE_MEMORY_H
  #include <memory.h>
-Index: driver.c
---- driver.c.orig	2003-10-15 21:22:31 +0200
-+++ driver.c	2005-01-29 13:36:30 +0100
-@@ -429,7 +429,9 @@
- 	/* for POP3, we can get the size of one mail only! Unfortunately, this
- 	 * protocol specific test cannot be done elsewhere as the protocol
- 	 * could be "auto". */
--	if (ctl->server.protocol == P_POP3)
-+	if (   ctl->server.protocol == P_POP3
-+	    || ctl->server.protocol == P_APOP
-+	    || ctl->server.protocol == P_RPOP)
- 	    fetchsizelimit = 1;
- 
- 	/* Time to allocate memory to store the sizes */
-
-OpenPKG-SA-2005.016-fetchmail; CAN-2005-2335
-Patch from Ludwig Nussel @SUSE
-Index: fetchmail-6.2.5/pop3.c
-===================================================================
---- pop3.c.625
-+++ pop3.c
-@@ -613,6 +613,8 @@ static int pop3_gettopid( int sock, int 
-     return 0;
- }
- 
-+#define str(s) #s
-+#define UIDLFMT(n) "%d %" str(n) "s"
- static int pop3_getuidl( int sock, int num , char *id)
- {
-     int ok;
-@@ -620,7 +622,7 @@ static int pop3_getuidl( int sock, int n
-     gen_send(sock, "UIDL %d", num);
-     if ((ok = pop3_ok(sock, buf)) != 0)
- 	return(ok);
--    if (sscanf(buf, "%d %s", &num, id) != 2)
-+    if (sscanf(buf, UIDLFMT(IDLEN), &num, id) != 2)
- 	return(PS_PROTOCOL);
-     return(PS_SUCCESS);
- }
-@@ -862,7 +864,7 @@ static int pop3_getrange(int sock, 
- 		{
-  		    if (DOTLINE(buf))
-  			break;
-- 		    else if (sscanf(buf, "%d %s", &num, id) == 2)
-+ 		    else if (sscanf(buf, UIDLFMT(IDLEN), &num, id) == 2)
- 		    {
-  			struct idlist	*old, *new;
- 
-

+ 23 - 17
fetchmail/fetchmail.spec

@@ -22,6 +22,10 @@
 ##  SUCH DAMAGE.
 ##
 
+#   package version
+%define       V_dist 6.2.9-rc9
+%define       V_opkg 6.2.9rc9
+
 #   package information
 Name:         fetchmail
 Summary:      Batch client for POP and IMAP protocols
@@ -32,11 +36,14 @@ Distribution: OpenPKG
 Class:        BASE
 Group:        Mail
 License:      GPL
-Version:      6.2.5
-Release:      20050728
+Version:      %{V_opkg}
+Release:      20051118
+
+#   package options
+%option       with_conf  no
 
 #   list of sources
-Source0:      http://www.catb.org/~esr/fetchmail/fetchmail-%{version}.tar.gz
+Source0:      http://download.berlios.de/fetchmail/fetchmail-%{V_dist}.tar.bz2
 Source1:      rc.fetchmail
 Source2:      fetchmail.master
 Source3:      fetchmail.users
@@ -49,6 +56,9 @@ BuildPreReq:  OpenPKG, openpkg >= 20040130, make, flex, bison, config
 PreReq:       OpenPKG, openpkg >= 20040130
 BuildPreReq:  openssl
 PreReq:       openssl
+%if "%{with_conf}" == "yes"
+PreReq:       python
+%endif
 AutoReq:      no
 AutoReqProv:  no
 
@@ -62,25 +72,15 @@ AutoReqProv:  no
 
 %track
     prog fetchmail = {
-        version   = %{version}
-        url       = http://www.catb.org/~esr/fetchmail/
-        regex     = fetchmail-(__VER__)\.tar\.gz
+        version   = %{V_dist}
+        url       = http://download.berlios.de/fetchmail/
+        regex     = fetchmail-(__VER__(-rc\d+)?)\.tar\.(gz|bz2)
     }
 
 %prep
-    %setup -q
+    %setup -q -n fetchmail-%{V_dist}
     %patch -p0
 
-    #   upgrade config scripts for better platform support
-    %{l_prefix}/bin/config install
-
-    #   don't outguess configure parameters
-    %{l_shtool} subst \
-        -e 's;test -r $with_ssl/include/openssl/ssl.h;false;' \
-        -e 's;test -r /usr/include/ssl/ssl.h;false;' \
-        -e '/^#define PID_DIR /s;\$dir;%{l_prefix}/var/fetchmail;' \
-        configure
-
 %build
     CC="%{l_cc}" \
     CFLAGS="%{l_cflags -O}" \
@@ -112,6 +112,12 @@ AutoReqProv:  no
         %{SOURCE rc.fetchmail} \
         $RPM_BUILD_ROOT%{l_prefix}/etc/rc.d/
 
+%if "%{with_conf}" != "yes"
+    rm -f  $RPM_BUILD_ROOT%{l_prefix}/bin/fetchmailconf
+    rm -f  $RPM_BUILD_ROOT%{l_prefix}/man/man1/fetchmailconf.1
+    rm -rf $RPM_BUILD_ROOT%{l_prefix}/lib/python
+%endif
+
     %{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT \
         %{l_files_std} \
         '%config %{l_prefix}/etc/fetchmail/fetchmail.master' \