From owner-freebsd-ports-bugs@FreeBSD.ORG Mon Feb 18 04:50:02 2013 Return-Path: Delivered-To: freebsd-ports-bugs@smarthost.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by hub.freebsd.org (Postfix) with ESMTP id 0BB7C4C8 for ; Mon, 18 Feb 2013 04:50:02 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:1900:2254:206c::16:87]) by mx1.freebsd.org (Postfix) with ESMTP id F187AAB3 for ; Mon, 18 Feb 2013 04:50:01 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.6/8.14.6) with ESMTP id r1I4o14T087414 for ; Mon, 18 Feb 2013 04:50:01 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.6/8.14.6/Submit) id r1I4o1I8087413; Mon, 18 Feb 2013 04:50:01 GMT (envelope-from gnats) Date: Mon, 18 Feb 2013 04:50:01 GMT Message-Id: <201302180450.r1I4o1I8087413@freefall.freebsd.org> To: freebsd-ports-bugs@FreeBSD.org Cc: From: dfilter@FreeBSD.ORG (dfilter service) Subject: Re: ports/172780: commit references a PR X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: dfilter service List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 18 Feb 2013 04:50:02 -0000 The following reply was made to PR ports/172780; it has been noted by GNATS. From: dfilter@FreeBSD.ORG (dfilter service) To: bug-followup@FreeBSD.org Cc: Subject: Re: ports/172780: commit references a PR Date: Mon, 18 Feb 2013 04:44:18 +0000 (UTC) Author: miwi Date: Mon Feb 18 04:43:58 2013 New Revision: 312474 URL: http://svnweb.freebsd.org/changeset/ports/312474 Log: afpfs-ng is an Apple Filing Protocol client that will allow BSD, Linux and Mac OS X systems to access files exported from a Mac OS system with AFP over TCP. WWW: http://sourceforge.net/projects/afpfs-ng/ PR: ports/172780 Submitted by: Manuel Creach Added: head/net/afpfs-ng/ head/net/afpfs-ng/Makefile (contents, props changed) head/net/afpfs-ng/distinfo (contents, props changed) head/net/afpfs-ng/files/ head/net/afpfs-ng/files/patch-Makefile.am (contents, props changed) head/net/afpfs-ng/files/patch-cmdline__cmdline_afp.c (contents, props changed) head/net/afpfs-ng/files/patch-cmdline__cmdline_testafp.c (contents, props changed) head/net/afpfs-ng/files/patch-cmdline__getstatus.c (contents, props changed) head/net/afpfs-ng/files/patch-configure.ac (contents, props changed) head/net/afpfs-ng/files/patch-fuse__client.c (contents, props changed) head/net/afpfs-ng/files/patch-fuse__commands.c (contents, props changed) head/net/afpfs-ng/files/patch-fuse__daemon.c (contents, props changed) head/net/afpfs-ng/files/patch-fuse__fuse_error.c (contents, props changed) head/net/afpfs-ng/files/patch-fuse__fuse_int.c (contents, props changed) head/net/afpfs-ng/files/patch-include__Makefile.am (contents, props changed) head/net/afpfs-ng/files/patch-include__afp.h (contents, props changed) head/net/afpfs-ng/files/patch-include__afpfs-ng__Makefile.am (contents, props changed) head/net/afpfs-ng/files/patch-include__afpfs-ng__afp.h (contents, props changed) head/net/afpfs-ng/files/patch-include__afpfs-ng__afp_protocol.h (contents, props changed) head/net/afpfs-ng/files/patch-include__afpfs-ng__codepage.h (contents, props changed) head/net/afpfs-ng/files/patch-include__afpfs-ng__dsi.h (contents, props changed) head/net/afpfs-ng/files/patch-include__afpfs-ng__libafpclient.h (contents, props changed) head/net/afpfs-ng/files/patch-include__afpfs-ng__map_def.h (contents, props changed) head/net/afpfs-ng/files/patch-include__afpfs-ng__midlevel.h (contents, props changed) head/net/afpfs-ng/files/patch-include__afpfs-ng__uams_def.h (contents, props changed) head/net/afpfs-ng/files/patch-include__afpfs-ng__utils.h (contents, props changed) head/net/afpfs-ng/files/patch-include__codepage.h (contents, props changed) head/net/afpfs-ng/files/patch-include__dsi.h (contents, props changed) head/net/afpfs-ng/files/patch-include__libafpclient.h (contents, props changed) head/net/afpfs-ng/files/patch-include__map_def.h (contents, props changed) head/net/afpfs-ng/files/patch-include__midlevel.h (contents, props changed) head/net/afpfs-ng/files/patch-include__uams_def.h (contents, props changed) head/net/afpfs-ng/files/patch-include__utils.h (contents, props changed) head/net/afpfs-ng/files/patch-lib__Makefile.am (contents, props changed) head/net/afpfs-ng/files/patch-lib__afp.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__afp_internal.h (contents, props changed) head/net/afpfs-ng/files/patch-lib__afp_url.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__client.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__codepage.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__connect.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__did.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__dsi.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__forklist.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__identify.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__log.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__loop.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__lowlevel.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__map_def.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__meta.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__midlevel.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__proto_attr.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__proto_desktop.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__proto_directory.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__proto_files.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__proto_fork.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__proto_login.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__proto_map.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__proto_replyblock.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__proto_server.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__proto_session.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__proto_volume.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__resource.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__server.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__status.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__uams.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__users.c (contents, props changed) head/net/afpfs-ng/files/patch-lib__utils.c (contents, props changed) head/net/afpfs-ng/pkg-descr (contents, props changed) head/net/afpfs-ng/pkg-plist (contents, props changed) Modified: head/net/Makefile Modified: head/net/Makefile ============================================================================== --- head/net/Makefile Mon Feb 18 04:17:46 2013 (r312473) +++ head/net/Makefile Mon Feb 18 04:43:58 2013 (r312474) @@ -14,6 +14,7 @@ SUBDIR += abills SUBDIR += activemq SUBDIR += acx100 + SUBDIR += afpfs-ng SUBDIR += aget SUBDIR += aoe SUBDIR += apinger Added: head/net/afpfs-ng/Makefile ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/net/afpfs-ng/Makefile Mon Feb 18 04:43:58 2013 (r312474) @@ -0,0 +1,58 @@ +# Created by: Manuel Creach +# $FreeBSD$ + +PORTNAME= afpfs-ng +PORTVERSION= 0.8.1 +CATEGORIES= net +MASTER_SITES= SF + +MAINTAINER= manuel.creach@icloud.com +COMMENT= The afpfs-ng is an Apple Filing Protocol client library + +LICENSE= GPLv2 +LICENSE_FILE= ${WRKSRC}/COPYING + +OPTIONS_DEFINE= FUSE GCRYPT + +USE_BZIP2= yes +USE_GCC= any +USE_GMAKE= yes +USE_AUTOTOOLS= aclocal autoheader automake autoconf libtoolize +ACLOCAL_ARGS= -I. +AUTOMAKE_ARGS= --add-missing +USE_LDCONFIG= yes + +CFLAGS+= -D_FILE_OFFSET_BITS=64 -I${LOCALBASE}/include +LDFLAGS+= -L${LOCALBASE}/lib + +.include + +CONFIGURE_ARGS+=--prefix="${PREFIX}" + +MAN1= afpcmd.1 afpgetstatus.1 + +.if ${PORT_OPTIONS:MFUSE} +LIB_DEPENDS+= fuse:${PORTSDIR}/sysutils/fusefs-libs +CONFIGURE_ARGS+=--enable-fuse +.else +CONFIGURE_ARGS+=--disable-fuse +.endif + +.if ${PORT_OPTIONS:MGCRYPT} +LIB_DEPENDS+= gcrypt:${PORTSDIR}/security/libgcrypt +CONFIGURE_ARGS+=--enable-gcrypt +.else +CONFIGURE_ARGS+=--disable-gcrypt +.endif + +.include + +post-patch: .SILENT + ${REINPLACE_CMD} 's|$$(libdir)/\(pkgconfig\)|$$(prefix)/libdata/\1|' \ + ${WRKSRC}/Makefile.am + +post-configure: .SILENT + ${REINPLACE_CMD} 's|LIBS = |LIBS = -liconv |' \ + ${WRKSRC}/cmdline/Makefile + +.include Added: head/net/afpfs-ng/distinfo ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/net/afpfs-ng/distinfo Mon Feb 18 04:43:58 2013 (r312474) @@ -0,0 +1,2 @@ +SHA256 (afpfs-ng-0.8.1.tar.bz2) = 688560de1cde57ab8d9e0ef7dc6436dbf0267fe8884f9014e50ff92b297b01a8 +SIZE (afpfs-ng-0.8.1.tar.bz2) = 344014 Added: head/net/afpfs-ng/files/patch-Makefile.am ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/net/afpfs-ng/files/patch-Makefile.am Mon Feb 18 04:43:58 2013 (r312474) @@ -0,0 +1,11 @@ +--- Makefile.am.orig 2008-02-18 03:24:14.000000000 +0000 ++++ Makefile.am 2012-10-14 13:11:34.000000000 +0000 +@@ -1,5 +1,5 @@ + if HAVE_LIBFUSE +-SUBDIRS = lib fuse cmdline docs ++SUBDIRS = lib fuse cmdline include docs + else +-SUBDIRS = lib cmdline docs ++SUBDIRS = lib cmdline include docs + endif +diff -Naur afpfs-ng-0.8.1.orig/cmdline/cmdline_afp.c afpfs-ng-0.8.1/cmdline/cmdline_afp.c Added: head/net/afpfs-ng/files/patch-cmdline__cmdline_afp.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/net/afpfs-ng/files/patch-cmdline__cmdline_afp.c Mon Feb 18 04:43:58 2013 (r312474) @@ -0,0 +1,16 @@ +--- cmdline/cmdline_afp.c.orig 2008-02-19 01:54:19.000000000 +0000 ++++ cmdline/cmdline_afp.c 2012-10-14 13:11:33.000000000 +0000 +@@ -3,9 +3,9 @@ + + */ + +-#include "afp.h" +-#include "midlevel.h" +-#include "map_def.h" ++#include "afpfs-ng/afp.h" ++#include "afpfs-ng/midlevel.h" ++#include "afpfs-ng/map_def.h" + + #include + #include +diff -Naur afpfs-ng-0.8.1.orig/cmdline/cmdline_testafp.c afpfs-ng-0.8.1/cmdline/cmdline_testafp.c Added: head/net/afpfs-ng/files/patch-cmdline__cmdline_testafp.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/net/afpfs-ng/files/patch-cmdline__cmdline_testafp.c Mon Feb 18 04:43:58 2013 (r312474) @@ -0,0 +1,14 @@ +--- cmdline/cmdline_testafp.c.orig 2008-03-04 20:16:50.000000000 +0000 ++++ cmdline/cmdline_testafp.c 2012-10-14 13:11:33.000000000 +0000 +@@ -3,8 +3,8 @@ + + */ + +-#include "afp.h" +-#include "midlevel.h" ++#include "afpfs-ng/afp.h" ++#include "afpfs-ng/midlevel.h" + + #include "cmdline_main.h" + +diff -Naur afpfs-ng-0.8.1.orig/cmdline/getstatus.c afpfs-ng-0.8.1/cmdline/getstatus.c Added: head/net/afpfs-ng/files/patch-cmdline__getstatus.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/net/afpfs-ng/files/patch-cmdline__getstatus.c Mon Feb 18 04:43:58 2013 (r312474) @@ -0,0 +1,14 @@ +--- cmdline/getstatus.c.orig 2008-02-18 03:28:09.000000000 +0000 ++++ cmdline/getstatus.c 2012-10-14 13:11:43.000000000 +0000 +@@ -1,8 +1,9 @@ + #include ++#include + #include + #include + +-#include "afp.h" ++#include "afpfs-ng/afp.h" + + static int getstatus(char * address_string, unsigned int port) + { +diff -Naur afpfs-ng-0.8.1.orig/configure.ac afpfs-ng-0.8.1/configure.ac Added: head/net/afpfs-ng/files/patch-configure.ac ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/net/afpfs-ng/files/patch-configure.ac Mon Feb 18 04:43:58 2013 (r312474) @@ -0,0 +1,42 @@ +--- configure.ac.orig 2008-03-08 16:23:12.000000000 +0000 ++++ configure.ac 2012-10-14 13:11:39.000000000 +0000 +@@ -11,6 +11,7 @@ + AC_PROG_CC + AC_PROG_INSTALL + AC_PROG_LIBTOOL ++AM_PROG_CC_C_O + + # Checks for libraries. + # FIXME: Replace `main' with a function in `-lncurses': +@@ -50,21 +51,6 @@ + case $host in + *-*-darwin*) + AC_MSG_CHECKING([for correct gcrypt version]) +- AC_RUN_IFELSE( +- [AC_LANG_PROGRAM([ +- #include +- #include ],[ +- char*p= GCRYPT_VERSION; +- unsigned int vers; +- vers=atoi(p)*10000; +- p=strchr(p,'.')+1; +- vers+=atoi(p)*100; +- p=strchr(p,'.')+1; +- vers+=atoi(p); +- if (vers<10400) return 1; +- ])], +- [AC_MSG_RESULT([yes])], +- [AC_MSG_ERROR([version is < 1.4.0])]) + AM_CONDITIONAL(HAVE_LIBGCRYPT, true) + AC_DEFINE([HAVE_LIBGCRYPT], [1] ) + ;; +@@ -105,7 +91,7 @@ + + + +-AC_CONFIG_FILES([lib/Makefile fuse/Makefile cmdline/Makefile Makefile docs/Makefile]) ++AC_CONFIG_FILES([lib/Makefile fuse/Makefile cmdline/Makefile Makefile include/Makefile include/afpfs-ng/Makefile docs/Makefile]) + + AC_OUTPUT + +diff -Naur afpfs-ng-0.8.1.orig/fuse/client.c afpfs-ng-0.8.1/fuse/client.c Added: head/net/afpfs-ng/files/patch-fuse__client.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/net/afpfs-ng/files/patch-fuse__client.c Mon Feb 18 04:43:58 2013 (r312474) @@ -0,0 +1,30 @@ +--- fuse/client.c.orig 2008-03-08 02:44:16.000000000 +0000 ++++ fuse/client.c 2012-10-14 13:11:44.000000000 +0000 +@@ -12,11 +12,11 @@ + #include + + #include "config.h" +-#include ++#include + #include "afp_server.h" +-#include "uams_def.h" +-#include "map_def.h" +-#include "libafpclient.h" ++#include "afpfs-ng/uams_def.h" ++#include "afpfs-ng/map_def.h" ++#include "afpfs-ng/libafpclient.h" + + #define default_uam "Cleartxt Passwrd" + +@@ -61,8 +61,9 @@ + snprintf(filename, PATH_MAX, + "/usr/local/bin/%s",AFPFSD_FILENAME); + if (access(filename,X_OK)) { +- snprintf(filename, "/usr/bin/%s", ++ snprintf(filename, sizeof(filename), "/usr/bin/%s", + AFPFSD_FILENAME); ++ filename[sizeof(filename) - 1] = 0; + if (access(filename,X_OK)) { + printf("Could not find server (%s)\n", + filename); +diff -Naur afpfs-ng-0.8.1.orig/fuse/commands.c afpfs-ng-0.8.1/fuse/commands.c Added: head/net/afpfs-ng/files/patch-fuse__commands.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/net/afpfs-ng/files/patch-fuse__commands.c Mon Feb 18 04:43:58 2013 (r312474) @@ -0,0 +1,26 @@ +--- fuse/commands.c.orig 2008-03-08 16:06:25.000000000 +0000 ++++ fuse/commands.c 2012-10-14 13:11:33.000000000 +0000 +@@ -19,15 +19,15 @@ + #include + #include + +-#include "afp.h" +-#include "dsi.h" ++#include "afpfs-ng/afp.h" ++#include "afpfs-ng/dsi.h" + #include "afp_server.h" +-#include "utils.h" ++#include "afpfs-ng/utils.h" + #include "daemon.h" +-#include "uams_def.h" +-#include "codepage.h" +-#include "libafpclient.h" +-#include "map_def.h" ++#include "afpfs-ng/uams_def.h" ++#include "afpfs-ng/codepage.h" ++#include "afpfs-ng/libafpclient.h" ++#include "afpfs-ng/map_def.h" + #include "fuse_int.h" + #include "fuse_error.h" + #include "fuse_internal.h" +diff -Naur afpfs-ng-0.8.1.orig/fuse/daemon.c afpfs-ng-0.8.1/fuse/daemon.c Added: head/net/afpfs-ng/files/patch-fuse__daemon.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/net/afpfs-ng/files/patch-fuse__daemon.c Mon Feb 18 04:43:58 2013 (r312474) @@ -0,0 +1,18 @@ +--- fuse/daemon.c.orig 2008-03-04 17:26:05.000000000 +0000 ++++ fuse/daemon.c 2012-10-14 13:11:33.000000000 +0000 +@@ -23,11 +23,11 @@ + #include + #include + +-#include "afp.h" ++#include "afpfs-ng/afp.h" + +-#include "dsi.h" ++#include "afpfs-ng/dsi.h" + #include "afp_server.h" +-#include "utils.h" ++#include "afpfs-ng/utils.h" + #include "daemon.h" + #include "commands.h" + +diff -Naur afpfs-ng-0.8.1.orig/fuse/fuse_error.c afpfs-ng-0.8.1/fuse/fuse_error.c Added: head/net/afpfs-ng/files/patch-fuse__fuse_error.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/net/afpfs-ng/files/patch-fuse__fuse_error.c Mon Feb 18 04:43:58 2013 (r312474) @@ -0,0 +1,12 @@ +--- fuse/fuse_error.c.orig 2008-01-18 04:40:10.000000000 +0000 ++++ fuse/fuse_error.c 2012-10-14 13:11:33.000000000 +0000 +@@ -4,7 +4,7 @@ + #include + #include + #include +-#include "libafpclient.h" ++#include "afpfs-ng/libafpclient.h" + #include "fuse_internal.h" + + #define TMP_FILE "/tmp/fuse_stderr" +diff -Naur afpfs-ng-0.8.1.orig/fuse/fuse_int.c afpfs-ng-0.8.1/fuse/fuse_int.c Added: head/net/afpfs-ng/files/patch-fuse__fuse_int.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/net/afpfs-ng/files/patch-fuse__fuse_int.c Mon Feb 18 04:43:58 2013 (r312474) @@ -0,0 +1,36 @@ +--- fuse/fuse_int.c.orig 2008-03-02 05:06:24.000000000 +0000 ++++ fuse/fuse_int.c 2012-10-14 13:11:44.000000000 +0000 +@@ -18,7 +18,7 @@ + #define FUSE_USE_VERSION 25 + + +-#include "afp.h" ++#include "afpfs-ng/afp.h" + + #include + #include +@@ -39,10 +39,10 @@ + #include + #include + +-#include "dsi.h" +-#include "afp_protocol.h" +-#include "codepage.h" +-#include "midlevel.h" ++#include "afpfs-ng/dsi.h" ++#include "afpfs-ng/afp_protocol.h" ++#include "afpfs-ng/codepage.h" ++#include "afpfs-ng/midlevel.h" + #include "fuse_error.h" + + /* Uncomment the following line to enable full debugging: */ +@@ -197,7 +197,7 @@ + ret = ml_open(volume,path,flags,&fp); + + if (ret==0) +- fi->fh=(void *) fp; ++ fi->fh=(unsigned long) fp; + + return ret; + } +diff -Naur afpfs-ng-0.8.1.orig/include/Makefile.am afpfs-ng-0.8.1/include/Makefile.am Added: head/net/afpfs-ng/files/patch-include__Makefile.am ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/net/afpfs-ng/files/patch-include__Makefile.am Mon Feb 18 04:43:58 2013 (r312474) @@ -0,0 +1,7 @@ +--- include/Makefile.am.orig 1970-01-01 00:00:00.000000000 +0000 ++++ include/Makefile.am 2012-10-14 13:11:34.000000000 +0000 +@@ -0,0 +1,3 @@ ++## Process this file with automake to produce Makefile.in ++ ++SUBDIRS = afpfs-ng +diff -Naur afpfs-ng-0.8.1.orig/include/afp.h afpfs-ng-0.8.1/include/afp.h Added: head/net/afpfs-ng/files/patch-include__afp.h ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/net/afpfs-ng/files/patch-include__afp.h Mon Feb 18 04:43:58 2013 (r312474) @@ -0,0 +1,537 @@ +--- include/afp.h.orig 2008-03-08 16:08:18.000000000 +0000 ++++ include/afp.h 2012-10-14 13:11:34.000000000 +0000 +@@ -1,533 +0,0 @@ +- +-#ifndef _AFP_H_ +-#define _AFP_H_ +- +-#include +-#include +-#include +-#include +-#include +-#include +-#include +-#include +-#include +-#include +-#include +- +- +-#define AFPFS_VERSION "0.8.1" +- +-/* This is the maximum AFP version this library supports */ +-#define AFP_MAX_SUPPORTED_VERSION 32 +- +-/* afp_url is used to pass locations around */ +-struct afp_url { +- enum {TCPIP,AT} protocol; +- char username[AFP_MAX_USERNAME_LEN]; +- char uamname[50]; +- char password[AFP_MAX_PASSWORD_LEN]; +- char servername[AFP_SERVER_NAME_UTF8_LEN]; +- int port; +- char volumename[AFP_VOLUME_NAME_UTF8_LEN]; +- char path[AFP_MAX_PATH]; +- +- int requested_version; +- char zone[AFP_ZONE_LEN]; /* Only used for Appletalk */ +- char volpassword[9];; +-}; +- +-struct afp_token { +- unsigned int length; +- char data[AFP_TOKEN_MAX_LEN]; +-}; +- +-#define SERVER_MAX_VERSIONS 10 +-#define SERVER_MAX_UAMS 10 +- +-struct afp_rx_buffer { +- unsigned int size; +- unsigned int maxsize; +- char * data; +- int errorcode; +-}; +- +- +-struct afp_file_info { +- unsigned short attributes; +- unsigned int did; +- unsigned int creation_date; +- unsigned int modification_date; +- unsigned int backup_date; +- unsigned int fileid; +- unsigned short offspring; +- char sync; +- char finderinfo[32]; +- char name[AFP_MAX_PATH]; +- char basename[AFP_MAX_PATH]; +- char translated_name[AFP_MAX_PATH]; +- struct afp_unixprivs unixprivs; +- unsigned int accessrights; +- struct afp_file_info * next; +- struct afp_file_info * largelist_next; +- unsigned char isdir; +- unsigned long long size; +- unsigned short resourcesize; +- unsigned int resource; +- unsigned short forkid; +- struct afp_icon * icon; +- int eof; +-}; +- +- +-#define VOLUME_EXTRA_FLAGS_VOL_CHMOD_KNOWN 0x1 +-#define VOLUME_EXTRA_FLAGS_VOL_CHMOD_BROKEN 0x2 +-#define VOLUME_EXTRA_FLAGS_SHOW_APPLEDOUBLE 0x4 +-#define VOLUME_EXTRA_FLAGS_VOL_SUPPORTS_UNIX 0x8 +-#define VOLUME_EXTRA_FLAGS_NO_LOCKING 0x10 +-#define VOLUME_EXTRA_FLAGS_IGNORE_UNIXPRIVS 0x20 +-#define VOLUME_EXTRA_FLAGS_READONLY 0x40 +- +-#define AFP_VOLUME_UNMOUNTED 0 +-#define AFP_VOLUME_MOUNTED 1 +-#define AFP_VOLUME_UNMOUNTING 2 +- +-struct afp_volume { +- unsigned short volid; +- char flags; /* This is from afpGetSrvrParms */ +- unsigned short attributes; /* This is from VolOpen */ +- unsigned short signature; /* This is fixed or variable */ +- unsigned int creation_date; +- unsigned int modification_date; +- unsigned int backup_date; +- struct statvfs stat; +- unsigned char mounted; +- char mountpoint[255]; +- struct afp_server * server; +- char volume_name[AFP_VOLUME_NAME_LEN]; +- char volume_name_printable[AFP_VOLUME_NAME_UTF8_LEN]; +- unsigned short dtrefnum; +- char volpassword[AFP_VOLPASS_LEN]; +- unsigned int extra_flags; /* This is an afpfs-ng specific field */ +- +- /* Our directory ID cache */ +- struct did_cache_entry * did_cache_base; +- pthread_mutex_t did_cache_mutex; +- +- /* Our journal of open forks */ +- struct afp_file_info * open_forks; +- pthread_mutex_t open_forks_mutex; +- +- /* Used to trigger startup */ +- pthread_cond_t startup_condition_cond; +- +- struct { +- uint64_t hits; +- uint64_t misses; +- uint64_t expired; +- uint64_t force_removed; +- } did_cache_stats; +- +- void * priv; /* This is a private structure for fuse/cmdline, etc */ +- pthread_t thread; /* This is the per-volume thread */ +- +- int mapping; +- +-}; +- +-#define SERVER_STATE_CONNECTED 1 +-#define SERVER_STATE_DISCONNECTED 2 +- +-enum server_type{ +- AFPFS_SERVER_TYPE_UNKNOWN, +- AFPFS_SERVER_TYPE_NETATALK, +- AFPFS_SERVER_TYPE_AIRPORT, +- AFPFS_SERVER_TYPE_MACINTOSH, +-}; +- +-#define is_netatalk(x) ( (x)->machine_type == AFPFS_SERVER_TYPE_NETATALK ) +-#define is_airport(x) ( (x)->machine_type == AFPFS_SERVER_TYPE_AIRPORT ) +-#define is_macintosh(x) ( (x)->machine_type == AFPFS_SERVER_TYPE_MACINTOSH ) +- +- +- +-struct afp_versions { +- char *av_name; +- int av_number; +-}; +-extern struct afp_versions afp_versions[]; +- +-struct afp_server { +- +- /* Our buffer sizes */ +- unsigned int tx_quantum; +- unsigned int rx_quantum; +- +- unsigned int tx_delay; +- +- /* Connection information */ +- struct sockaddr_in address; +- int fd; +- +- /* Some stats, for information only */ +- struct { +- uint64_t runt_packets; +- uint64_t incoming_dsi; +- uint64_t rx_bytes; +- uint64_t tx_bytes; +- uint64_t requests_pending; +- } stats; +- +- /* General information */ +- char server_name[AFP_SERVER_NAME_LEN]; +- char server_name_utf8[AFP_SERVER_NAME_UTF8_LEN]; +- char server_name_printable[AFP_SERVER_NAME_UTF8_LEN]; +- +- char machine_type[17]; +- char icon[256]; +- char signature[16]; +- unsigned short flags; +- int connect_state; +- enum server_type server_type; +- +- /* This is the time we connected */ +- time_t connect_time; +- +- /* UAMs */ +- unsigned int supported_uams; +- unsigned int using_uam; +- +- /* Authentication */ +- char username[AFP_MAX_USERNAME_LEN]; +- char password[AFP_MAX_PASSWORD_LEN]; +- +- /* Session */ +- struct afp_token token; +- char need_resume; +- +- /* Versions */ +- unsigned char requested_version; +- unsigned char versions[SERVER_MAX_VERSIONS]; +- struct afp_versions *using_version; +- +- /* Volumes */ +- unsigned char num_volumes; +- struct afp_volume * volumes; +- +- void * dsi; +- unsigned int exit_flag; +- +- /* Our DSI request queue */ +- pthread_mutex_t requestid_mutex; +- pthread_mutex_t request_queue_mutex; +- unsigned short lastrequestid; +- unsigned short expectedrequestid; +- struct dsi_request * command_requests; +- +- +- char loginmesg[200]; +- char servermesg[200]; +- char path_encoding; +- +- /* This is the data for the incoming buffer */ +- char * incoming_buffer; +- int data_read; +- int bufsize; +- +- /* And this is for the outgoing queue */ +- pthread_mutex_t send_mutex; +- +- /* This is for user mapping */ +- struct passwd passwd; +- unsigned int server_uid, server_gid; +- int server_gid_valid; +- +- struct afp_server *next; +- +- /* These are for DSI attention packets */ +- unsigned int attention_quantum; +- unsigned int attention_len; +- char * attention_buffer; +- +-}; +- +-struct afp_extattr_info { +- unsigned int maxsize; +- unsigned int size; +- char data[1024]; +-}; +-struct afp_comment { +- unsigned int maxsize; +- unsigned int size; +- char *data; +-}; +- +-struct afp_icon { +- unsigned int maxsize; +- unsigned int size; +- char *data; +-}; +- +-#define AFP_DEFAULT_ATTENTION_QUANTUM 1024 +- +-void afp_unixpriv_to_stat(struct afp_file_info *fp, +- struct stat *stat); +- +-int init_uams(void) ; +- +-unsigned int find_uam_by_name(const char * name); +-char * uam_bitmap_to_string(unsigned int bitmap); +- +- +-char * get_uam_names_list(void); +- +-unsigned int default_uams_mask(void); +- +-struct afp_volume * find_volume_by_name(struct afp_server * server, +- const char * volname); +- +-struct afp_connection_request { +- unsigned int uam_mask; +- struct afp_url url; +-}; +- +-void afp_default_url(struct afp_url *url); +-int afp_parse_url(struct afp_url * url, const char * toparse, int verbose); +-void afp_print_url(struct afp_url * url); +-int afp_url_validate(char * url_string, struct afp_url * valid_url); +- +-int afp_list_volnames(struct afp_server * server, char * names, int max); +- +-/* User mapping */ +-int afp_detect_mapping(struct afp_volume * volume); +- +-/* These are some functions that help with simple status text generation */ +- +-int afp_status_header(char * text, int * len); +-int afp_status_server(struct afp_server * s,char * text, int * len); +- +- +-struct afp_server * afp_server_full_connect(void * priv, struct afp_connection_request * req); +- +-void * just_end_it_now(void *other); +-void add_fd_and_signal(int fd); +-void loop_disconnect(struct afp_server *s); +-void afp_wait_for_started_loop(void); +- +- +-struct afp_versions * pick_version(unsigned char *versions, +- unsigned char requested) ; +-int pick_uam(unsigned int u1, unsigned int u2); +- +-int afp_server_login(struct afp_server *server, +- char * mesg, unsigned int *l, unsigned int max); +- +- +-int afp_dologin(struct afp_server *server, +- unsigned int uam, char * username, char * passwd); +- +-void afp_free_server(struct afp_server **server); +- +-struct afp_server * afp_server_init(struct sockaddr_in * address); +-int afp_get_address(void * priv, const char * hostname, unsigned int port, +- struct sockaddr_in * address); +- +- +-int afp_main_loop(int command_fd); +-int afp_main_quick_startup(pthread_t * thread); +- +-int afp_server_destroy(struct afp_server *s) ; +-int afp_server_reconnect(struct afp_server * s, char * mesg, +- unsigned int *l, unsigned int max); +-int afp_server_connect(struct afp_server *s, int full); +- +-struct afp_server * afp_server_complete_connection( +- void * priv, +- struct afp_server * server, +- struct sockaddr_in * address, unsigned char * versions, +- unsigned int uams, char * username, char * password, +- unsigned int requested_version, unsigned int uam_mask); +- +-int afp_connect_volume(struct afp_volume * volume, struct afp_server * server, +- char * mesg, unsigned int * l, unsigned int max); +-int something_is_mounted(struct afp_server * server); +- +-int add_cache_entry(struct afp_file_info * file) ; +-struct afp_file_info * get_cache_by_name(char * name); +-struct afp_server * find_server_by_address(struct sockaddr_in * address); +-struct afp_server * find_server_by_signature(char * signature); +-struct afp_server * find_server_by_name(char * name); +-int server_still_valid(struct afp_server * server); +- +- +-struct afp_server * get_server_base(void); +-int afp_server_remove(struct afp_server * server); +- +-int afp_unmount_volume(struct afp_volume * volume); +-int afp_unmount_all_volumes(struct afp_server * server); +- +-#define volume_is_readonly(x) (((x)->attributes&kReadOnly) || \ +- ((x)->extra_flags & VOLUME_EXTRA_FLAGS_READONLY)) +- +-int afp_opendt(struct afp_volume *volume, unsigned short * refnum); +- +-int afp_closedt(struct afp_server * server, unsigned short * refnum); +- +-int afp_getcomment(struct afp_volume *volume, unsigned int did, +- const char * pathname, struct afp_comment * comment); +- +-int afp_addcomment(struct afp_volume *volume, unsigned int did, +- const char * pathname, char * comment,uint64_t *size); +- +-int afp_geticon(struct afp_volume * volume, unsigned int filecreator, +- unsigned int filetype, unsigned char icontype, +- unsigned short length, struct afp_icon * icon); +- +-/* Things you want to do to a server */ +- +-int afp_getsrvrmsg(struct afp_server *server, unsigned short messagetype,unsigned char utf8, unsigned char block, char * mesg); +- +-int afp_login(struct afp_server *server, char * uaname, +- char * userauthinfo, unsigned int userauthinfo_len, +- struct afp_rx_buffer *rx); +- +-int afp_changepassword(struct afp_server *server, char * uaname, +- char * userauthinfo, unsigned int userauthinfo_len, +- struct afp_rx_buffer *rx); +- +-int afp_logincont(struct afp_server *server, unsigned short id, +- char * userauthinfo, unsigned int userauthinfo_len, +- struct afp_rx_buffer *rx); +- +-int afp_getsessiontoken(struct afp_server * server, int type, +- unsigned int timestamp, struct afp_token *outgoing_token, +- struct afp_token * incoming_token); +- +-int afp_getsrvrparms(struct afp_server *server); +- +-int afp_logout(struct afp_server *server,unsigned char wait); +- +-int afp_mapname(struct afp_server * server, unsigned char subfunction, +- char * name, unsigned int * id); +- +-int afp_mapid(struct afp_server * server, unsigned char subfunction, +- unsigned int id, char *name); +- +-int afp_getuserinfo(struct afp_server * server, int thisuser, +- unsigned int userid, unsigned short bitmap, +- unsigned int *newuid, unsigned int *newgid); +- +-int afp_zzzzz(struct afp_server *server); +- +-int afp_volopen(struct afp_volume * volume, +- unsigned short bitmap, char * password); +- +-int afp_flush(struct afp_volume * volume); +- +-int afp_getfiledirparms(struct afp_volume *volume, unsigned int did, +- unsigned int filebitmap, unsigned int dirbitmap, const char * pathname, +- struct afp_file_info *fp); +- +-int afp_enumerate(struct afp_volume * volume, +- unsigned int dirid, +- unsigned int filebitmap, unsigned int dirbitmap, +- unsigned short reqcount, +- unsigned short startindex, +- char * path, +- struct afp_file_info ** file_p); +- +-int afp_enumerateext2(struct afp_volume * volume, +- unsigned int dirid, +- unsigned int filebitmap, unsigned int dirbitmap, +- unsigned short reqcount, +- unsigned long startindex, +- char * path, +- struct afp_file_info ** file_p); +- +-int afp_openfork(struct afp_volume * volume, +- unsigned char forktype, +- unsigned int dirid, +- unsigned short accessmode, +- char * filename, +- struct afp_file_info *fp); +- +-int afp_read(struct afp_volume * volume, unsigned short forkid, +- uint32_t offset, +- uint32_t count, struct afp_rx_buffer * rx); +- +-int afp_readext(struct afp_volume * volume, unsigned short forkid, +- uint64_t offset, +- uint64_t count, struct afp_rx_buffer * rx); +- +-int afp_getvolparms(struct afp_volume * volume, unsigned short bitmap); +- +- +-int afp_createdir(struct afp_volume * volume, unsigned int dirid, const char * pathname, unsigned int *did_p); +- +-int afp_delete(struct afp_volume * volume, +- unsigned int dirid, char * pathname); +- +- +-int afp_createfile(struct afp_volume * volume, unsigned char flag, +- unsigned int did, char * pathname); +- +-int afp_write(struct afp_volume * volume, unsigned short forkid, +- uint32_t offset, uint32_t reqcount, +- char * data, uint32_t * written); +- +-int afp_writeext(struct afp_volume * volume, unsigned short forkid, +- uint64_t offset, uint64_t reqcount, +- char * data, uint64_t * written); +- +-int afp_flushfork(struct afp_volume * volume, unsigned short forkid); +- +-int afp_closefork(struct afp_volume * volume, unsigned short forkid); +-int afp_setfileparms(struct afp_volume * volume, +- unsigned int dirid, const char * pathname, unsigned short bitmap, +- struct afp_file_info *fp); +-int afp_setfiledirparms(struct afp_volume * volume, +- unsigned int dirid, const char * pathname, unsigned short bitmap, +- struct afp_file_info *fp); +- +-int afp_setdirparms(struct afp_volume * volume, +- unsigned int dirid, const char * pathname, unsigned short bitmap, +- struct afp_file_info *fp); +- +-int afp_volclose(struct afp_volume * volume); +- +- +-int afp_setforkparms(struct afp_volume *volume, +- unsigned short forkid, unsigned short bitmap, unsigned long len); +- +-int afp_byterangelock(struct afp_volume * volume, +- unsigned char flag, +- unsigned short forkid, +- uint32_t offset, +- uint32_t len, uint32_t *generated_offset); +- +-int afp_byterangelockext(struct afp_volume * volume, +- unsigned char flag, +- unsigned short forkid, +- uint64_t offset, +- uint64_t len, uint64_t *generated_offset); +- +-int afp_moveandrename(struct afp_volume *volume, +- unsigned int src_did, +- unsigned int dst_did, +- char * src_path, char * dst_path, char *new_name); +- +-int afp_rename(struct afp_volume * volume, +- unsigned int dirid, +- char * path_from, char * path_to); +- +-int afp_listextattr(struct afp_volume * volume, +- unsigned int dirid, unsigned short bitmap, +- char * pathname, struct afp_extattr_info * info); +- +-/* This is a currently undocumented command */ +-int afp_newcommand76(struct afp_volume * volume, unsigned int dlen, char * data); +- +-/* For debugging */ +-char * afp_get_command_name(char code); +- +- +-#endif +diff -Naur afpfs-ng-0.8.1.orig/include/afp_protocol.h afpfs-ng-0.8.1/include/afp_protocol.h Added: head/net/afpfs-ng/files/patch-include__afpfs-ng__Makefile.am ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/net/afpfs-ng/files/patch-include__afpfs-ng__Makefile.am Mon Feb 18 04:43:58 2013 (r312474) @@ -0,0 +1,10 @@ +--- include/afpfs-ng/Makefile.am.orig 1970-01-01 00:00:00.000000000 +0000 ++++ include/afpfs-ng/Makefile.am 2012-10-14 13:11:34.000000000 +0000 +@@ -0,0 +1,6 @@ ++## Process this file with automake to produce Makefile.in ++ ++afpfsincludedir = $(includedir)/afpfs-ng ++ ++afpfsinclude_HEADERS = afp.h afp_protocol.h libafpclient.h ++nodist_afpfsinclude_HEADERS = codepage.h dsi.h map_def.h midlevel.h uams_def.h utils.h +diff -Naur afpfs-ng-0.8.1.orig/include/afpfs-ng/afp.h afpfs-ng-0.8.1/include/afpfs-ng/afp.h Added: head/net/afpfs-ng/files/patch-include__afpfs-ng__afp.h ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/net/afpfs-ng/files/patch-include__afpfs-ng__afp.h Mon Feb 18 04:43:58 2013 (r312474) @@ -0,0 +1,537 @@ +--- include/afpfs-ng/afp.h.orig 1970-01-01 00:00:00.000000000 +0000 ++++ include/afpfs-ng/afp.h 2012-10-14 13:11:44.000000000 +0000 +@@ -0,0 +1,533 @@ ++ ++#ifndef _AFP_H_ ++#define _AFP_H_ ++ ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++#include ++ ++ ++#define AFPFS_VERSION "0.8.1" ++ ++/* This is the maximum AFP version this library supports */ ++#define AFP_MAX_SUPPORTED_VERSION 32 ++ ++/* afp_url is used to pass locations around */ ++struct afp_url { ++ enum {TCPIP,AT} protocol; ++ char username[AFP_MAX_USERNAME_LEN]; ++ char uamname[50]; ++ char password[AFP_MAX_PASSWORD_LEN]; ++ char servername[AFP_SERVER_NAME_UTF8_LEN]; ++ int port; ++ char volumename[AFP_VOLUME_NAME_UTF8_LEN]; ++ char path[AFP_MAX_PATH]; ++ ++ int requested_version; ++ char zone[AFP_ZONE_LEN]; /* Only used for Appletalk */ ++ char volpassword[9];; ++}; ++ ++struct afp_token { ++ unsigned int length; ++ char data[AFP_TOKEN_MAX_LEN]; ++}; ++ ++#define SERVER_MAX_VERSIONS 10 ++#define SERVER_MAX_UAMS 10 ++ ++struct afp_rx_buffer { ++ unsigned int size; ++ unsigned int maxsize; ++ char * data; ++ int errorcode; ++}; ++ ++ ++struct afp_file_info { ++ unsigned short attributes; ++ unsigned int did; ++ unsigned int creation_date; ++ unsigned int modification_date; ++ unsigned int backup_date; ++ unsigned int fileid; ++ unsigned short offspring; ++ char sync; ++ char finderinfo[32]; ++ char name[AFP_MAX_PATH]; ++ char basename[AFP_MAX_PATH]; ++ char translated_name[AFP_MAX_PATH]; ++ struct afp_unixprivs unixprivs; ++ unsigned int accessrights; ++ struct afp_file_info * next; ++ struct afp_file_info * largelist_next; ++ unsigned char isdir; ++ unsigned long long size; ++ unsigned short resourcesize; ++ unsigned int resource; ++ unsigned short forkid; ++ struct afp_icon * icon; ++ int eof; ++}; ++ ++ ++#define VOLUME_EXTRA_FLAGS_VOL_CHMOD_KNOWN 0x1 ++#define VOLUME_EXTRA_FLAGS_VOL_CHMOD_BROKEN 0x2 ++#define VOLUME_EXTRA_FLAGS_SHOW_APPLEDOUBLE 0x4 ++#define VOLUME_EXTRA_FLAGS_VOL_SUPPORTS_UNIX 0x8 ++#define VOLUME_EXTRA_FLAGS_NO_LOCKING 0x10 ++#define VOLUME_EXTRA_FLAGS_IGNORE_UNIXPRIVS 0x20 ++#define VOLUME_EXTRA_FLAGS_READONLY 0x40 ++ ++#define AFP_VOLUME_UNMOUNTED 0 ++#define AFP_VOLUME_MOUNTED 1 ++#define AFP_VOLUME_UNMOUNTING 2 ++ ++struct afp_volume { ++ unsigned short volid; ++ char flags; /* This is from afpGetSrvrParms */ ++ unsigned short attributes; /* This is from VolOpen */ ++ unsigned short signature; /* This is fixed or variable */ ++ unsigned int creation_date; ++ unsigned int modification_date; ++ unsigned int backup_date; ++ struct statvfs stat; ++ unsigned char mounted; ++ char mountpoint[255]; ++ struct afp_server * server; ++ char volume_name[AFP_VOLUME_NAME_LEN]; *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** _______________________________________________ svn-ports-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-ports-all To unsubscribe, send any mail to "svn-ports-all-unsubscribe@freebsd.org"