[csw-devel] SF.net SVN: gar:[15188] csw/mgar/pkg/lftp/trunk
chninkel at users.sourceforge.net
chninkel at users.sourceforge.net
Fri Jul 22 23:22:52 CEST 2011
Revision: 15188
http://gar.svn.sourceforge.net/gar/?rev=15188&view=rev
Author: chninkel
Date: 2011-07-22 21:22:52 +0000 (Fri, 22 Jul 2011)
Log Message:
-----------
lftp: fixed some important build issues
Modified Paths:
--------------
csw/mgar/pkg/lftp/trunk/Makefile
csw/mgar/pkg/lftp/trunk/checksums
csw/mgar/pkg/lftp/trunk/files/changelog.CSW
Added Paths:
-----------
csw/mgar/pkg/lftp/trunk/files/disable_ipv6_configure_option.patch
csw/mgar/pkg/lftp/trunk/files/do_not_use_sun_as_a_variable.patch
csw/mgar/pkg/lftp/trunk/files/sun_len_definition.patch
Modified: csw/mgar/pkg/lftp/trunk/Makefile
===================================================================
--- csw/mgar/pkg/lftp/trunk/Makefile 2011-07-22 21:20:52 UTC (rev 15187)
+++ csw/mgar/pkg/lftp/trunk/Makefile 2011-07-22 21:22:52 UTC (rev 15188)
@@ -13,7 +13,7 @@
###### Package information #######
NAME = lftp
-VERSION = 4.0.10
+VERSION = 4.3.1
CATEGORIES = net
DESCRIPTION = A sophisticated command-line ftp/http client
@@ -57,12 +57,29 @@
PATCHFILES += dont_use_csw_getopt_h.patch
+# Add a --disable-ipv6 option to configure so we can disable ipv6 support
+# under Solaris 9 and workaround "IPV6_V6ONLY symbole missing" issue
+# see http://wiki.opencsw.org/porting-faq#toc14
+PATCHFILES += disable_ipv6_configure_option.patch
+
+# sun should not be used as a variable as sun is a macro under Solaris
+PATCHFILES += do_not_use_sun_as_a_variable.patch
+
+# SUN_LEN macro is not defined under Solaris
+PATCHFILES += sun_len_definition.patch
+
PRESERVECONF = $(sysconfdir)/lftp.conf
MIGRATE_FILES_CSWlftp = lftp.conf
##### Build and installation information #####
+# We build solaris 10 specific version to be able to enable
+# ipv6 support on these platforms
+# see http://wiki.opencsw.org/porting-faq#toc14
+PACKAGING_PLATFORMS = solaris9-sparc solaris9-i386
+PACKAGING_PLATFORMS += solaris10-sparc solaris10-i386
+
# to support shared /opt/csw setup
# see http://wiki.opencsw.org/shared-opt-csw-setup
localstatedir = /var$(prefix)
@@ -73,6 +90,13 @@
EXTRA_LINKER_FLAGS = -norunpath
CONFIGURE_ARGS = $(DIRPATHS)
+
+# Solaris 9 does not have IPV6_V6ONLY.
+# IPv6 support only works on Solaris 10.
+CONFIGURE_ARGS_5.9 = --disable-ipv6
+CONFIGURE_ARGS_5.10 = --enable-ipv6
+CONFIGURE_ARGS += $(CONFIGURE_ARGS_$(GAROSREL))
+
# previous maintainer compiled with openssl
# instead of gnutls, no need to change that
CONFIGURE_ARGS += --without-gnutls --with-openssl=/opt/csw
@@ -84,7 +108,7 @@
include gar/category.mk
# we re-run autoconf because we patched a m4 file
-pre-configure:
+pre-configure-modulated:
cd $(WORKSRC) && autoconf
@$(MAKECOOKIE)
Modified: csw/mgar/pkg/lftp/trunk/checksums
===================================================================
--- csw/mgar/pkg/lftp/trunk/checksums 2011-07-22 21:20:52 UTC (rev 15187)
+++ csw/mgar/pkg/lftp/trunk/checksums 2011-07-22 21:22:52 UTC (rev 15188)
@@ -1 +1 @@
-2729f41bc21130f96190d41d34bb8809 lftp-4.0.10.tar.gz
+3acc58840013d16890ec6e1d01fb4103 lftp-4.3.1.tar.gz
Modified: csw/mgar/pkg/lftp/trunk/files/changelog.CSW
===================================================================
--- csw/mgar/pkg/lftp/trunk/files/changelog.CSW 2011-07-22 21:20:52 UTC (rev 15187)
+++ csw/mgar/pkg/lftp/trunk/files/changelog.CSW 2011-07-22 21:22:52 UTC (rev 15188)
@@ -1,3 +1,13 @@
+lftp (4.3.1,REV=2011.07.19) unstable
+
+ * New upstream release.
+ * Updated dependancies names:
+ CSWgettextrt -> CSWlibintl8
+ CSWreadline -> CSWlibreadline6
+ * Removed SUNWspro hardcoded RPATH from binaries.
+
+ -- Yann Rouillard <yann at opencsw.org> Tue, 19 Jul 2011 00:12:44 +0200
+
lftp (4.0.10,REV=2010.09.03) unstable
* New upstream release.
Added: csw/mgar/pkg/lftp/trunk/files/disable_ipv6_configure_option.patch
===================================================================
--- csw/mgar/pkg/lftp/trunk/files/disable_ipv6_configure_option.patch (rev 0)
+++ csw/mgar/pkg/lftp/trunk/files/disable_ipv6_configure_option.patch 2011-07-22 21:22:52 UTC (rev 15188)
@@ -0,0 +1,55 @@
+--- lftp-4.3.1.orig/m4/sockpfaf.m4 Wed Mar 16 10:06:17 2011
++++ lftp-4.3.1/m4/sockpfaf.m4 Tue Jul 19 00:57:52 2011
+@@ -36,6 +36,12 @@
+ AC_DEFINE([HAVE_IPV4], [1], [Define to 1 if <sys/socket.h> defines AF_INET.])
+ fi
+
++ AC_ARG_ENABLE([ipv6],
++ AS_HELP_STRING([--disable-ipv6], [disable ipv6 support]),
++ [ enable_ipv6=$enableval; ],
++ [ enable_ipv6=; ])
++
++if test x$enable_ipv6 != xno; then
+ AC_MSG_CHECKING([for IPv6 sockets])
+ AC_CACHE_VAL([gl_cv_socket_ipv6],
+ [AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <sys/types.h>
+@@ -57,7 +63,10 @@
+ AC_MSG_RESULT([$gl_cv_socket_ipv6])
+ if test $gl_cv_socket_ipv6 = yes; then
+ AC_DEFINE([HAVE_IPV6], [1], [Define to 1 if <sys/socket.h> defines AF_INET6.])
++ elif test x$enable_ipv6 = xyes; then
++ AC_MSG_ERROR(ipv6 support not available)
+ fi
++fi
+ ])
+
+ AC_DEFUN([gl_SOCKET_FAMILY_UNIX],
+--- lftp-4.3.1.orig/configure.ac Fri Jun 24 17:34:51 2011
++++ lftp-4.3.1/configure.ac.new Tue Jul 19 16:19:22 2011
+@@ -473,7 +473,7 @@
+ # endif
+ #endif
+
+-#define INET6 (defined(AF_INET6) \
++#define INET6 (defined(HAVE_IPV6) \
+ && defined(HAVE_GETNAMEINFO) \
+ && defined(HAVE_GETADDRINFO))
+
+--- a/src/Torrent.cc
++++ b/src/Torrent.cc
+@@ -482,6 +482,7 @@ int TorrentTracker::HandleTrackerReply()
+ }
+ LogNote(4,plural("Received valid info about %d peer$|s$",peers_count),peers_count);
+ }
++#if INET6
+ peers_count=0;
+ b_peers=reply->dict.lookup("peers6");
+ if(b_peers && b_peers->type==BeNode::BE_STR) { // binary model
+@@ -499,6 +500,7 @@ int TorrentTracker::HandleTrackerReply()
+ }
+ LogNote(4,plural("Received valid info about %d IPv6 peer$|s$",peers_count),peers_count);
+ }
++#endif
+ tracker_timer.Reset();
+ tracker_reply=0;
+ return MOVED;
Added: csw/mgar/pkg/lftp/trunk/files/do_not_use_sun_as_a_variable.patch
===================================================================
--- csw/mgar/pkg/lftp/trunk/files/do_not_use_sun_as_a_variable.patch (rev 0)
+++ csw/mgar/pkg/lftp/trunk/files/do_not_use_sun_as_a_variable.patch 2011-07-22 21:22:52 UTC (rev 15188)
@@ -0,0 +1,50 @@
+--- a/src/attach.h
++++ b/src/attach.h
+@@ -88,9 +91,9 @@ public:
+ TimeoutS(1);
+ return m;
+ }
+- struct sockaddr_un sun;
+- socklen_t sa_len=sizeof(sun);
+- a_sock=accept(sock,(sockaddr*)&sun,&sa_len);
++ struct sockaddr_un s_un;
++ socklen_t sa_len=sizeof(s_un);
++ a_sock=accept(sock,(sockaddr*)&s_un,&sa_len);
+ if(a_sock==-1 && E_RETRY(errno)) {
+ Block(sock,POLLIN);
+ return m;
+@@ -161,11 +164,11 @@ public:
+ int fl=fcntl(sock,F_GETFL);
+ fcntl(sock,F_SETFL,fl|O_NONBLOCK);
+ fcntl(sock,F_SETFD,FD_CLOEXEC);
+- struct sockaddr_un sun;
+- memset(&sun,0,sizeof(sun));
+- sun.sun_family=AF_UNIX;
+- strncpy(sun.sun_path,path,sizeof(sun.sun_path));
+- if(bind(sock,(sockaddr*)&sun,SUN_LEN(&sun))==-1) {
++ struct sockaddr_un s_un;
++ memset(&s_un,0,sizeof(s_un));
++ s_un.sun_family=AF_UNIX;
++ strncpy(s_un.sun_path,path,sizeof(s_un.sun_path));
++ if(bind(sock,(sockaddr*)&s_un,SUN_LEN(&s_un))==-1) {
+ perror("bind");
+ close(sock);
+ sock=-1;
+@@ -219,12 +222,12 @@ public:
+ m=MOVED;
+ }
+ if(!connected) {
+- struct sockaddr_un sun;
+- memset(&sun,0,sizeof(sun));
+- sun.sun_family=AF_UNIX;
++ struct sockaddr_un s_un;
++ memset(&s_un,0,sizeof(s_un));
++ s_un.sun_family=AF_UNIX;
+ const char *path=AcceptTermFD::get_sock_path(pid);
+- strncpy(sun.sun_path,path,sizeof(sun.sun_path));
+- int res=connect(sock,(sockaddr*)&sun,SUN_LEN(&sun));
++ strncpy(s_un.sun_path,path,sizeof(s_un.sun_path));
++ int res=connect(sock,(sockaddr*)&s_un,SUN_LEN(&s_un));
+ if(res==-1 && !NonFatalError(errno)) {
+ error=Error::Fatal(xstring::format("connect(%s): %s",path,strerror(errno)));
+ return MOVED;
Added: csw/mgar/pkg/lftp/trunk/files/sun_len_definition.patch
===================================================================
--- csw/mgar/pkg/lftp/trunk/files/sun_len_definition.patch (rev 0)
+++ csw/mgar/pkg/lftp/trunk/files/sun_len_definition.patch 2011-07-22 21:22:52 UTC (rev 15188)
@@ -0,0 +1,12 @@
+--- a/src/attach.h
++++ b/src/attach.h
+@@ -39,6 +39,9 @@
+ #elif HAVE_WS2TCPIP_H
+ # include <ws2tcpip.h>
+ #endif
++#ifndef SUN_LEN
++# define SUN_LEN(ptr) ((size_t) (((struct sockaddr_un *) 0)->sun_path) + strlen ((ptr)->sun_path))
++#endif
+
+ #include "SMTask.h"
+ #include "Error.h"
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the devel
mailing list