From 077015a8592ce541ada7a446c4cf2daf37ea7474 Mon Sep 17 00:00:00 2001 From: hauke Date: Tue, 10 Jan 2023 22:07:33 +0000 Subject: [PATCH] Update net/netatalk22 to v2.2.7. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit From the upstream ChangeLog: [2.2] Fix 'multiple definition' compile time errors by @rdmark in #136 [2.2] Remove bitrotted code by @rdmark in #139 [2.2] Fixes for the OpenSSL 1.1 API; add OpenSSL 1.0 backwards compat by @rdmark in #142 [2.2] Install afp_ldap.conf based on LDAP support, not availability of ACLs. by @rdmark in #143 [2.2] Resolve gcc 10 compile time warnings on Linux by @rdmark in #165 [2.2] Downstream patches for NetBSD compatibility by @rdmark in #148 [2.2] Make timelord work on non-big-endian systems; ability to sync localtime by @rdmark in #151 [2.2] Resolve papd compile time errors due to deprecated CUPS calls by @rdmark in #152 [2.2] Resolve automake warnings running bootstrap by @rdmark in #153 [2.2] Handle special FIRSTNET behavior on NetBSD by @rdmark in #154 [2.2] papd patches for compatibility with older Apple LaserWriter drivers on Mac and GS/OS by @rdmark in #156 [2.2] Allow non-unicode volume to be scanned by the repair tool. by @rdmark in #158 [2.2] Update init script templates to start/stop a2boot daemon. by @rdmark in #160 [2.2] Backport Netatalk 3 patches by @rdmark in #161 [2.2] papd: Send replies to client when printing to prompt more data by @rdmark in #162 [2.2] afpd: Add option to disable afp session tickles by @rdmark in #163 [2.2] Update for Unicode 14 by @rdmark in #164 [2.2] Made the AsanteTalk bridge consistently start up in AppleTalk Phase 2$A!-(B by @rdmark in #166 [2.2] Introduce fully functional systemd unit configurations for all daemons by @rdmark in #167 [2.2] General stability patches by @rdmark in #168 Fix some compile errors by @JensKSP in #176 Package changes: Distfile has been moved to github Clean up unused PLIST variables --- net/netatalk22/Makefile | 10 +- net/netatalk22/distinfo | 29 +--- net/netatalk22/options.mk | 4 +- .../patches/patch-config_Makefile.in | 13 +- .../patches/patch-config_afpd.conf.tmpl | 15 --- net/netatalk22/patches/patch-configure | 32 +---- .../patch-distrib_initscripts_Makefile.in | 45 ------- .../patches/patch-etc_afpd_afp__options.c | 16 --- .../patches/patch-etc_atalkd_main.c | 23 ---- .../patch-etc_cnid_dbd_cmd_dbd_scanvol.c | 21 --- net/netatalk22/patches/patch-etc_papd_file.c | 39 ------ net/netatalk22/patches/patch-etc_papd_file.h | 16 --- .../patches/patch-etc_papd_magics.c | 35 ----- .../patches/patch-etc_papd_print_cups.c | 124 ------------------ .../patches/patch-etc_uams_uams__dhx__pam.c | 63 --------- .../patch-etc_uams_uams__dhx__passwd.c | 53 ++------ .../patches/patch-etc_uams_uams__randnum.c | 106 --------------- .../patches/patch-include_atalk_ldapconfig.h | 22 ---- .../patches/patch-libatalk_asp_asp__getsess.c | 18 --- .../patches/patch-libatalk_bstring_bstrlib.c | 22 ---- .../patches/patch-man_man5_afpd.conf.5.tmpl | 15 --- 21 files changed, 26 insertions(+), 695 deletions(-) delete mode 100644 net/netatalk22/patches/patch-config_afpd.conf.tmpl delete mode 100644 net/netatalk22/patches/patch-distrib_initscripts_Makefile.in delete mode 100644 net/netatalk22/patches/patch-etc_afpd_afp__options.c delete mode 100644 net/netatalk22/patches/patch-etc_atalkd_main.c delete mode 100644 net/netatalk22/patches/patch-etc_cnid_dbd_cmd_dbd_scanvol.c delete mode 100644 net/netatalk22/patches/patch-etc_papd_file.c delete mode 100644 net/netatalk22/patches/patch-etc_papd_file.h delete mode 100644 net/netatalk22/patches/patch-etc_papd_magics.c delete mode 100644 net/netatalk22/patches/patch-etc_papd_print_cups.c delete mode 100644 net/netatalk22/patches/patch-etc_uams_uams__dhx__pam.c delete mode 100644 net/netatalk22/patches/patch-etc_uams_uams__randnum.c delete mode 100644 net/netatalk22/patches/patch-include_atalk_ldapconfig.h delete mode 100644 net/netatalk22/patches/patch-libatalk_asp_asp__getsess.c delete mode 100644 net/netatalk22/patches/patch-libatalk_bstring_bstrlib.c delete mode 100644 net/netatalk22/patches/patch-man_man5_afpd.conf.5.tmpl diff --git a/net/netatalk22/Makefile b/net/netatalk22/Makefile index e0f02fee0a74..6668dc38c8df 100644 --- a/net/netatalk22/Makefile +++ b/net/netatalk22/Makefile @@ -1,11 +1,9 @@ -# $NetBSD: Makefile,v 1.49 2023/01/03 17:38:02 wiz Exp $ +# $NetBSD: Makefile,v 1.50 2023/01/10 22:07:33 hauke Exp $ -DISTNAME= netatalk-2.2.6 +DISTNAME= netatalk-2.2.7 PKGNAME= ${DISTNAME:C/-/22-/} -PKGREVISION= 33 CATEGORIES= net print -MASTER_SITES= ${MASTER_SITE_SOURCEFORGE:=netatalk/} -EXTRACT_SUFX= .tar.bz2 +MASTER_SITES= ${MASTER_SITE_GITHUB:=Netatalk/}Netatalk/releases/download/netatalk-2-2-7/ #PATCHFILES= patch-adv1tov2.c PATCH_SITES= http://svn.macosforge.org/repository/macports/trunk/dports/net/netatalk/files/ \ http://mirror.lug.udel.edu/pub/macports/trunk/dports/net/netatalk/files/ @@ -59,14 +57,12 @@ SUBST_STAGE.paths= pre-configure SUBST_FILES.paths= etc/psf/etc2ps.sh SUBST_SED.paths= -e 's,^\(DVIPS="*\)/usr\(/bin\),\1${PREFIX}\2,' -PLIST_VARS+= rcd .if ${OPSYS} == "NetBSD" CONFIGURE_ARGS+= --enable-netbsd RCD_SCRIPTS= afpd atalkd papd timelord cnid_metad . for f in ${RCD_SCRIPTS} RCD_SCRIPT_SRC.${f}= ${WRKSRC}/distrib/initscripts/${f} . endfor -PLIST.rcd= yes .endif PLIST_VARS+= ea diff --git a/net/netatalk22/distinfo b/net/netatalk22/distinfo index 950af6308590..ae2d9ec76814 100644 --- a/net/netatalk22/distinfo +++ b/net/netatalk22/distinfo @@ -1,23 +1,8 @@ -$NetBSD: distinfo,v 1.13 2022/01/28 21:18:18 nat Exp $ +$NetBSD: distinfo,v 1.14 2023/01/10 22:07:33 hauke Exp $ -BLAKE2s (netatalk-2.2.6.tar.bz2) = 22951265586889d7ac4f01ade0707f1e63389a14623beec787f587e4ef74b891 -SHA512 (netatalk-2.2.6.tar.bz2) = 74aa3415a43293a8804b00b0eda564d6536310e59c3f0d067d634db89f4d612a1dfd932df18607c32b948922ae032bc25471e21635ab149a78629ff95c341f47 -Size (netatalk-2.2.6.tar.bz2) = 1301887 bytes -SHA1 (patch-config_Makefile.in) = e6b020cf4cf11572a648bee7de0937add1948ea8 -SHA1 (patch-config_afpd.conf.tmpl) = 4ff3dc9ea7af77319dc5be499e04648220022404 -SHA1 (patch-configure) = 9919625c3cd54e34ab45c6606094e12215630d33 -SHA1 (patch-distrib_initscripts_Makefile.in) = 706890f9e0aacab4d523cc1900048b7fab96f5d4 -SHA1 (patch-etc_afpd_afp__options.c) = ab65d03c61f8be65e8afc3bd102e5e13e642f1b9 -SHA1 (patch-etc_atalkd_main.c) = bdd452b9ca62e506d056e3818fb7f5b54a9d38c5 -SHA1 (patch-etc_cnid_dbd_cmd_dbd_scanvol.c) = df844b4047e614a3fd44cbcea252627f6fe43b65 -SHA1 (patch-etc_papd_file.c) = 8d050430e8013501230462375c874c8188f12e73 -SHA1 (patch-etc_papd_file.h) = 2464cc27385a8300f8cc3503643db4512d5f368f -SHA1 (patch-etc_papd_magics.c) = 3f25cb45e7a860505895c628490905fe42a1ed62 -SHA1 (patch-etc_papd_print_cups.c) = 8dada275f9525b9229a85492050de982b1e54295 -SHA1 (patch-etc_uams_uams__dhx__pam.c) = 8ed99ff32ca932367c5df7af6889db1abbde7a2e -SHA1 (patch-etc_uams_uams__dhx__passwd.c) = 52e2862aa55268349dfc64a7d71ebc17e1b8830b -SHA1 (patch-etc_uams_uams__randnum.c) = 0608eb6a7b43b0cc360879849c9ca0b38ffdc684 -SHA1 (patch-include_atalk_ldapconfig.h) = e69d212f45ace23773d15c122ca2e550b025f845 -SHA1 (patch-libatalk_asp_asp__getsess.c) = 0ae089ef4f882a1580298707fbeee5d519c83482 -SHA1 (patch-libatalk_bstring_bstrlib.c) = f43818328237b908166f956de464f532d578d2c4 -SHA1 (patch-man_man5_afpd.conf.5.tmpl) = 43dfb930851329e5fe77d2fae4b8b7237a3fe42c +BLAKE2s (netatalk-2.2.7.tar.gz) = a828870c06fcec3aaf1ec4fd6c06411ecc0e687b73f4d29257743de0667798df +SHA512 (netatalk-2.2.7.tar.gz) = fb6664b2ea700f1a8307eaf452954e2f0c3bb7d082f2df211f17a79d1fc7f3ca4dff0b805beb7b8d10fb23d749fd1990a6b07c029d89d09299677a41b8161220 +Size (netatalk-2.2.7.tar.gz) = 1849800 bytes +SHA1 (patch-config_Makefile.in) = 37ed88693c64b5e34396da26f9d7105102ed479b +SHA1 (patch-configure) = 6b9d73ac0c8ba4913834402a587b734d342c3830 +SHA1 (patch-etc_uams_uams__dhx__passwd.c) = a4eb368ae6f1698d906fe1ba2f1600b7a0b20539 diff --git a/net/netatalk22/options.mk b/net/netatalk22/options.mk index e6dae15abfae..f0263e1089b0 100644 --- a/net/netatalk22/options.mk +++ b/net/netatalk22/options.mk @@ -1,4 +1,4 @@ -# $NetBSD: options.mk,v 1.6 2021/04/02 09:54:26 hauke Exp $ +# $NetBSD: options.mk,v 1.7 2023/01/10 22:07:33 hauke Exp $ # PKG_OPTIONS_VAR= PKG_OPTIONS.netatalk PKG_SUPPORTED_OPTIONS= cups debug dnssd kerberos ldap pam slp @@ -12,7 +12,6 @@ CONFIGURE_ARGS+= --enable-cups CONFIGURE_ARGS+= --disable-cups .endif -PLIST_VARS+= debug .if !empty(PKG_OPTIONS:Mdebug) # Debugging CONFIGURE_ARGS+= --enable-debug1 @@ -22,7 +21,6 @@ CFLAGS+= -g3 INSTALL_UNSTRIPPED= yes .endif -PLIST_VARS+= dnssd .if !empty(PKG_OPTIONS:Mdnssd) .include "../../net/mDNSResponder/buildlink3.mk" CONFIGURE_ARGS+= --enable-zeroconf diff --git a/net/netatalk22/patches/patch-config_Makefile.in b/net/netatalk22/patches/patch-config_Makefile.in index 7d55e65660ec..4334c5f7b2a4 100644 --- a/net/netatalk22/patches/patch-config_Makefile.in +++ b/net/netatalk22/patches/patch-config_Makefile.in @@ -1,6 +1,4 @@ -$NetBSD: patch-config_Makefile.in,v 1.2 2021/04/02 09:54:26 hauke Exp $ - -Install afp_ldap.conf based on LDAP support, not ACL support. +$NetBSD: patch-config_Makefile.in,v 1.3 2023/01/10 22:07:33 hauke Exp $ Install config files to examples/netatalk, and leave installation to the pkginstall framerwork. @@ -9,15 +7,6 @@ Renamed from patch-ah --- config/Makefile.in.orig 2017-07-09 11:27:05.000000000 +0000 +++ config/Makefile.in -@@ -88,7 +88,7 @@ POST_UNINSTALL = : - build_triplet = @build@ - host_triplet = @host@ - target_triplet = @target@ --@HAVE_ACLS_TRUE@am__append_1 = afp_ldap.conf -+@HAVE_LDAP_TRUE@am__append_1 = afp_ldap.conf - @USE_APPLETALK_TRUE@am__append_2 = atalkd.conf papd.conf - subdir = config - ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 @@ -759,13 +759,14 @@ uninstall-local: rm -f $(DESTDIR)$(pkgconfdir)/$$f; \ done diff --git a/net/netatalk22/patches/patch-config_afpd.conf.tmpl b/net/netatalk22/patches/patch-config_afpd.conf.tmpl deleted file mode 100644 index 39f769b42a60..000000000000 --- a/net/netatalk22/patches/patch-config_afpd.conf.tmpl +++ /dev/null @@ -1,15 +0,0 @@ -$NetBSD: patch-config_afpd.conf.tmpl,v 1.2 2022/01/28 21:18:19 nat Exp $ - -Allow -1 as a vaild tickleval to disable session tickles. -As needed on appletalk 58. - ---- config/afpd.conf.tmpl.orig 2014-03-16 11:17:48.000000000 +0000 -+++ config/afpd.conf.tmpl -@@ -175,6 +175,7 @@ - # Note, this defaults to 30 seconds, and really - # shouldn't be changed. If you want to control - # the server idle timeout, use the -timeout option. -+# A value of 0 disables session timer tickles. - # -timeout Specify the number of tickles to send before - # timing out a connection. - # The default is 4, therefore a connection will diff --git a/net/netatalk22/patches/patch-configure b/net/netatalk22/patches/patch-configure index 9edb93b61245..14b311e70521 100644 --- a/net/netatalk22/patches/patch-configure +++ b/net/netatalk22/patches/patch-configure @@ -1,36 +1,10 @@ -$NetBSD: patch-configure,v 1.3 2017/07/12 13:56:00 hauke Exp $ - -Disable zeroconf explicitely, unless enabled - the distribution -appears not to allow for this. - -We do not at this point support zeroconf via avahi. Since configure -does not allow for building without avahi, and native avahi is picked -up on some Linuxen, we disable all avahi tests unconditionally here. +$NetBSD: patch-configure,v 1.4 2023/01/10 22:07:33 hauke Exp $ Fix build on SunOS by disabling the isainfo bitness check ---- configure.orig 2013-07-23 09:11:35.000000000 +0000 +--- configure.orig 2023-01-10 08:57:35.000000000 +0000 +++ configure -@@ -16109,7 +16109,7 @@ fi - if test "${enable_zeroconf+set}" = set; then : - enableval=$enable_zeroconf; zeroconf=$enableval - else -- zeroconf=try -+ zeroconf=no - - fi - -@@ -16185,7 +16185,8 @@ $as_echo "#define HAVE_MDNS 1" >>confdef - fi - - # mDNS support using Avahi -- if test x"$found_zeroconf" != x"yes" ; then -+ #if test x"$found_zeroconf" != x"yes" ; then -+ if 0 ; then - ac_fn_c_check_header_mongrel "$LINENO" "avahi-client/client.h" "ac_cv_header_avahi_client_client_h" "$ac_includes_default" - if test "x$ac_cv_header_avahi_client_client_h" = xyes; then : - { $as_echo "$as_me:${as_lineno-$LINENO}: checking for avahi_client_new in -lavahi-client" >&5 -@@ -17535,7 +17536,7 @@ $as_echo_n "checking if we have to build +@@ -19331,7 +19331,7 @@ printf %s "checking if we have to build # check for isainfo, if not found it has to be a 32 bit kernel (<=2.6) if test -x /usr/bin/isainfo; then # check for 64 bit platform diff --git a/net/netatalk22/patches/patch-distrib_initscripts_Makefile.in b/net/netatalk22/patches/patch-distrib_initscripts_Makefile.in deleted file mode 100644 index 847e5afe29ff..000000000000 --- a/net/netatalk22/patches/patch-distrib_initscripts_Makefile.in +++ /dev/null @@ -1,45 +0,0 @@ -$NetBSD: patch-distrib_initscripts_Makefile.in,v 1.2 2017/07/12 13:56:00 hauke Exp $ - -NetBSD specific adaptation to install process (christos committed -them, ask him ;) - ---- distrib/initscripts/Makefile.in.orig 2012-09-28 07:49:25.000000000 +0000 -+++ distrib/initscripts/Makefile.in -@@ -592,7 +592,7 @@ info: info-am - - info-am: - --install-data-am: install-serviceDATA install-sysvSCRIPTS -+install-data-am: install-serviceDATA - @$(NORMAL_INSTALL) - $(MAKE) $(AM_MAKEFLAGS) install-data-hook - install-dvi: install-dvi-am -@@ -723,23 +723,23 @@ uninstall: uninstall-startup - @USE_TRU64_TRUE@uninstall-startup: uninstall-am - - @USE_NETBSD_TRUE@afpd: rc.afpd.netbsd --@USE_NETBSD_TRUE@ cp -f $< $@ -+@USE_NETBSD_TRUE@ cp -f $? $@ - @USE_NETBSD_TRUE@ chmod a+x $@ - - @USE_NETBSD_TRUE@atalkd: rc.atalkd.netbsd --@USE_NETBSD_TRUE@ cp -f $< $@ -+@USE_NETBSD_TRUE@ cp -f $? $@ - @USE_NETBSD_TRUE@ chmod a+x $@ - - @USE_NETBSD_TRUE@cnid_metad: rc.cnid_metad.netbsd --@USE_NETBSD_TRUE@ cp -f $< $@ -+@USE_NETBSD_TRUE@ cp -f $? $@ - @USE_NETBSD_TRUE@ chmod a+x $@ - - @USE_NETBSD_TRUE@papd: rc.papd.netbsd --@USE_NETBSD_TRUE@ cp -f $< $@ -+@USE_NETBSD_TRUE@ cp -f $? $@ - @USE_NETBSD_TRUE@ chmod a+x $@ - - @USE_NETBSD_TRUE@timelord: rc.timelord.netbsd --@USE_NETBSD_TRUE@ cp -f $< $@ -+@USE_NETBSD_TRUE@ cp -f $? $@ - @USE_NETBSD_TRUE@ chmod a+x $@ - - @USE_NETBSD_TRUE@install-data-hook: diff --git a/net/netatalk22/patches/patch-etc_afpd_afp__options.c b/net/netatalk22/patches/patch-etc_afpd_afp__options.c deleted file mode 100644 index 443c7e7629f0..000000000000 --- a/net/netatalk22/patches/patch-etc_afpd_afp__options.c +++ /dev/null @@ -1,16 +0,0 @@ -$NetBSD: patch-etc_afpd_afp__options.c,v 1.2 2022/01/28 21:18:19 nat Exp $ - -Allow -1 as a vaild tickleval to disable session tickles. -As needed on appletalk 58. - ---- etc/afpd/afp_options.c.orig 2014-03-16 11:17:48.000000000 +0000 -+++ etc/afpd/afp_options.c -@@ -318,7 +318,7 @@ int afp_options_parseline(char *buf, str - options->loginmaxfail = atoi(c); - if ((c = getoption(buf, "-tickleval"))) { - options->tickleval = atoi(c); -- if (options->tickleval <= 0) { -+ if (options->tickleval < 0) { - options->tickleval = 30; - } - } diff --git a/net/netatalk22/patches/patch-etc_atalkd_main.c b/net/netatalk22/patches/patch-etc_atalkd_main.c deleted file mode 100644 index cbdb35535edc..000000000000 --- a/net/netatalk22/patches/patch-etc_atalkd_main.c +++ /dev/null @@ -1,23 +0,0 @@ -$NetBSD: patch-etc_atalkd_main.c,v 1.1 2021/09/12 15:52:37 nat Exp $ - -Set interface address correctly for phase 1 networks on NetBSD. - -NB: This is a kludge that should not be required. - ---- etc/atalkd/main.c.orig 2017-07-09 11:03:31.000000000 +0000 -+++ etc/atalkd/main.c -@@ -1228,8 +1228,14 @@ void bootaddr(struct interface *iface) - } - - if ( iface->i_flags & IFACE_PHASE1 ) { -+#ifndef __NetBSD__ - setaddr( iface, IFACE_PHASE1, 0, - iface->i_caddr.sat_addr.s_node, 0, 0 ); -+#else -+ setaddr( iface, IFACE_PHASE1, iface->i_caddr.sat_addr.s_net, -+ iface->i_caddr.sat_addr.s_node, -+ iface->i_rt->rt_firstnet, iface->i_rt->rt_lastnet ); -+#endif - - if ( iface->i_flags & IFACE_LOOPBACK ) { - iface->i_flags |= IFACE_CONFIG | IFACE_ADDR; diff --git a/net/netatalk22/patches/patch-etc_cnid_dbd_cmd_dbd_scanvol.c b/net/netatalk22/patches/patch-etc_cnid_dbd_cmd_dbd_scanvol.c deleted file mode 100644 index d93f688b018b..000000000000 --- a/net/netatalk22/patches/patch-etc_cnid_dbd_cmd_dbd_scanvol.c +++ /dev/null @@ -1,21 +0,0 @@ -$NetBSD: patch-etc_cnid_dbd_cmd_dbd_scanvol.c,v 1.1 2021/04/02 09:54:26 hauke Exp $ - -While upstream "officially" only supports unicode volumes, other -encodings have always worked. So, starting to enforce unicode volumes -in the repair tool is a funny approach. - ---- etc/cnid_dbd/cmd_dbd_scanvol.c.orig 2014-03-16 11:17:48.000000000 +0000 -+++ etc/cnid_dbd/cmd_dbd_scanvol.c -@@ -1204,10 +1204,10 @@ int cmd_dbd_scanvol(DBD *dbd_ref, struct - /* Make it accessible for all funcs */ - dbd = dbd_ref; - -- /* We only support unicode volumes ! */ -+ /* Officially, we only support unicode volumes */ - if ( vi->v_volcharset != CH_UTF8) { - dbd_log( LOGSTD, "Not a Unicode volume: %s, %u != %u", vi->v_volcodepage, vi->v_volcharset, CH_UTF8); -- return -1; -+ /* return -1; */ - } - - /* Get volume stamp */ diff --git a/net/netatalk22/patches/patch-etc_papd_file.c b/net/netatalk22/patches/patch-etc_papd_file.c deleted file mode 100644 index bca2cb125f72..000000000000 --- a/net/netatalk22/patches/patch-etc_papd_file.c +++ /dev/null @@ -1,39 +0,0 @@ -$NetBSD: patch-etc_papd_file.c,v 1.1 2021/09/12 15:52:37 nat Exp $ - -Introdtuce spoolreply() for sending a response back to the client. - -Required to request more data for printing. -XXX: AFAICT this should work in all cases. - ---- etc/papd/file.c.orig 2014-03-16 11:17:48.000000000 +0000 -+++ etc/papd/file.c -@@ -40,7 +40,7 @@ int markline( struct papfile *pf, char * - if ( *linelength >= pf->pf_datalen ) { - if ( pf->pf_state & PF_EOF ) { - append( pf, "\n", 1 ); -- } else if (*linelength < 1024) { -+ } else { - return( -1 ); - } - } -@@ -107,6 +107,20 @@ void append(struct papfile *pf, const ch - } - - -+void spoolreply(struct papfile *out, char *str) -+{ -+ char *pserr1 = "%%[ status: "; -+ char *pserr2 = " ]%%\n"; -+ -+ if ( str == NULL ) { -+ str = "Spooler error."; -+ } -+ -+ append( out, pserr1, strlen( pserr1 )); -+ append( out, str, strlen( str )); -+ append( out, pserr2, strlen( pserr2 )); -+} -+ - void spoolerror(struct papfile *out, char *str) - { - char *pserr1 = "%%[ Error: "; diff --git a/net/netatalk22/patches/patch-etc_papd_file.h b/net/netatalk22/patches/patch-etc_papd_file.h deleted file mode 100644 index 46335e547a64..000000000000 --- a/net/netatalk22/patches/patch-etc_papd_file.h +++ /dev/null @@ -1,16 +0,0 @@ -$NetBSD: patch-etc_papd_file.h,v 1.1 2021/09/12 15:52:37 nat Exp $ - -Introdtuce spoolreply() for sending a response back to the client. - -Required to request more data for printing. -XXX: AFAICT this should work in all cases. - ---- etc/papd/file.h.orig 2014-03-16 11:17:48.000000000 +0000 -+++ etc/papd/file.h -@@ -40,5 +40,6 @@ int markline ( struct papfile *, char ** - void morespace ( struct papfile *, const char *, int ); - void append ( struct papfile *, const char *, int ); - void spoolerror ( struct papfile *, char * ); -+void spoolreply ( struct papfile *, char * ); - - #endif /* PAPD_FILE_H */ diff --git a/net/netatalk22/patches/patch-etc_papd_magics.c b/net/netatalk22/patches/patch-etc_papd_magics.c deleted file mode 100644 index 063125b3c22b..000000000000 --- a/net/netatalk22/patches/patch-etc_papd_magics.c +++ /dev/null @@ -1,35 +0,0 @@ -$NetBSD: patch-etc_papd_magics.c,v 1.2 2022/01/28 21:18:19 nat Exp $ - -Send a reply when more data required by papd server. -As required by appletalk 58. - -Also prevent an erronous return value from ps(). - -AFAICT this should have no consequence on later appletalk versions. - ---- etc/papd/magics.c.orig 2014-03-16 11:17:48.000000000 +0000 -+++ etc/papd/magics.c -@@ -74,6 +74,7 @@ int ps( struct papfile *infile, struct p - return( 0 ); - - case -1 : -+ spoolreply( outfile, "Processing..." ); - return( 0 ); - } - -@@ -98,6 +99,7 @@ int ps( struct papfile *infile, struct p - CONSUME( infile, linelength + crlflength ); - } - } -+ return 0; - } - - int cm_psquery( struct papfile *in, struct papfile *out, struct sockaddr_at *sat _U_) -@@ -115,6 +117,7 @@ int cm_psquery( struct papfile *in, stru - return( CH_DONE ); - - case -1 : -+ spoolreply( out, "Processing..." ); - return( CH_MORE ); - - case -2 : diff --git a/net/netatalk22/patches/patch-etc_papd_print_cups.c b/net/netatalk22/patches/patch-etc_papd_print_cups.c deleted file mode 100644 index e9413e0fe959..000000000000 --- a/net/netatalk22/patches/patch-etc_papd_print_cups.c +++ /dev/null @@ -1,124 +0,0 @@ -$NetBSD: patch-etc_papd_print_cups.c,v 1.3 2019/11/23 17:55:02 hauke Exp $ - -Deprecated functions: Remove obsolete define, and disable compiler -errors for deprecation warnings, as seen in the darktable print code. - -Accessors: Cups has abstracted away access to ipp_t fields, use -accessor functions. - ---- etc/papd/print_cups.c.orig 2017-07-09 11:03:31.000000000 +0000 -+++ etc/papd/print_cups.c -@@ -39,11 +39,11 @@ - - #ifdef HAVE_CUPS - --/* enable pre-1.6 CUPS API for now */ --#define _PPD_DEPRECATED -- --/* expose structs that are private post-1.5 CUPS */ --#define _IPP_PRIVATE_STRUCTURES 1 -+/* -+ * Do not error out on deprecation messages -+ * -- darktable does this in their "src/common/cups_print.c" -+ */ -+#pragma GCC diagnostic ignored "-Wdeprecated-declarations" - - #include - #include -@@ -61,6 +61,11 @@ - #define MAXCHOOSERLEN 31 - #define HTTP_MAX_URI 1024 - -+/* Deal with post-1.7 deprecated httpConnect() */ -+#define httpConnect(host, port) httpConnect2(host, port, NULL, AF_UNSPEC, HTTP_ENCRYPTION_IF_REQUESTED, 1, 1000, NULL) -+ -+/* XXX Also: cupsGetPPD() */ -+ - static const char* cups_status_msg[] = { - "status: busy; info: \"%s\" is rejecting jobs; ", - "status: idle; info: \"%s\" is stopped, accepting jobs ;", -@@ -136,12 +141,8 @@ cups_printername_ok(char *name) - * requested-attributes - * printer-uri - */ -- -- request = ippNew(); -- -- request->request.op.operation_id = IPP_GET_PRINTER_ATTRIBUTES; -- request->request.op.request_id = 1; -- -+ request = ippNewRequest(IPP_OP_GET_PRINTER_ATTRIBUTES); -+ - language = cupsLangDefault(); - - ippAddString(request, IPP_TAG_OPERATION, IPP_TAG_CHARSET, -@@ -172,10 +173,11 @@ cups_printername_ok(char *name) - - httpClose(http); - -- if (response->request.status.status_code >= IPP_OK_CONFLICT) -+ if ( cupsLastError() >= IPP_OK_CONFLICT) - { - LOG(log_error, logtype_papd, "Unable to get printer status for %s - %s", name, -- ippErrorString(response->request.status.status_code)); -+ ippErrorString(cupsLastError())); -+ - ippDelete(response); - return (0); - } -@@ -249,10 +251,7 @@ cups_get_printer_status (struct printer - * printer-uri - */ - -- request = ippNew(); -- -- request->request.op.operation_id = IPP_GET_PRINTER_ATTRIBUTES; -- request->request.op.request_id = 1; -+ request = ippNewRequest(IPP_OP_GET_PRINTER_ATTRIBUTES); - - language = cupsLangDefault(); - -@@ -282,10 +281,11 @@ cups_get_printer_status (struct printer - return (0); - } - -- if (response->request.status.status_code >= IPP_OK_CONFLICT) -+ if (cupsLastError() >= IPP_OK_CONFLICT) - { -- LOG(log_error, logtype_papd, "Unable to get printer status for %s - %s", pr->p_printer, -- ippErrorString(response->request.status.status_code)); -+ LOG(log_error, logtype_papd, "Unable to get printer status for %s - %s", pr->p_printer, -+ ippErrorString(cupsLastError())); -+ - ippDelete(response); - httpClose(http); - return (0); -@@ -299,9 +299,9 @@ cups_get_printer_status (struct printer - - if ((attr = ippFindAttribute(response, "printer-state", IPP_TAG_ENUM)) != NULL) - { -- if (attr->values[0].integer == IPP_PRINTER_STOPPED) -+ if (ippGetInteger(attr, 0) == IPP_PRINTER_STOPPED) - status = 1; -- else if (attr->values[0].integer == IPP_NOT_ACCEPTING) -+ else if (ippGetInteger(attr,0) == IPP_NOT_ACCEPTING) - status = 0; - else - status = 2; -@@ -309,14 +309,14 @@ cups_get_printer_status (struct printer - - if ((attr = ippFindAttribute(response, "printer-is-accepting-jobs", IPP_TAG_BOOLEAN)) != NULL) - { -- if ( attr->values[0].integer == 0 ) -+ if ( ippGetInteger(attr, 0) == 0 ) - status = 0; - } - - snprintf ( pr->p_status, 255, cups_status_msg[status], pr->p_printer ); - - if ((attr = ippFindAttribute(response, "printer-state-message", IPP_TAG_TEXT)) != NULL) -- strncat ( pr->p_status, attr->values[0].string.text, 255-strlen(pr->p_status)); -+ strncat ( pr->p_status, ippGetString(attr, 0, NULL), 255-strlen(pr->p_status)); - - ippDelete(response); - diff --git a/net/netatalk22/patches/patch-etc_uams_uams__dhx__pam.c b/net/netatalk22/patches/patch-etc_uams_uams__dhx__pam.c deleted file mode 100644 index 9ff8448008cb..000000000000 --- a/net/netatalk22/patches/patch-etc_uams_uams__dhx__pam.c +++ /dev/null @@ -1,63 +0,0 @@ -$NetBSD: patch-etc_uams_uams__dhx__pam.c,v 1.2 2021/04/02 09:54:26 hauke Exp $ - -Adapt for new OpenSSL API. - ---- etc/uams/uams_dhx_pam.c.orig 2014-03-16 11:17:48.000000000 +0000 -+++ etc/uams/uams_dhx_pam.c -@@ -190,6 +190,7 @@ static int dhx_setup(void *obj, char *ib - u_int16_t sessid; - size_t i; - BIGNUM *bn, *gbn, *pbn; -+ const BIGNUM *pub_key; - DH *dh; - - /* get the client's public key */ -@@ -233,9 +234,16 @@ static int dhx_setup(void *obj, char *ib - return AFPERR_PARAM; - } - -+ if (!DH_set0_pqg(dh, pbn, NULL, gbn)) { -+ BN_free(pbn); -+ BN_free(gbn); -+ /* Log Entry */ -+ LOG(log_info, logtype_uams, "uams_dhx_pam.c :PAM DH_set0_pqg() mysteriously failed -- %s", strerror(errno)); -+ /* Log Entry */ -+ goto pam_fail; -+ } -+ - /* generate key and make sure that we have enough space */ -- dh->p = pbn; -- dh->g = gbn; - if (DH_generate_key(dh) == 0) { - unsigned long dherror; - char errbuf[256]; -@@ -249,16 +257,17 @@ static int dhx_setup(void *obj, char *ib - ERR_free_strings(); - goto pam_fail; - } -- if (BN_num_bytes(dh->pub_key) > KEYSIZE) { -+ DH_get0_key(dh, &pub_key, NULL); -+ if (BN_num_bytes(pub_key) > KEYSIZE) { - LOG(log_info, logtype_uams, "uams_dhx_pam.c :PAM: Err Generating Key -- Not enough Space? -- %s", strerror(errno)); - goto pam_fail; - } - - /* figure out the key. store the key in rbuf for now. */ -- i = DH_compute_key(rbuf, bn, dh); -+ i = DH_compute_key((unsigned char *)rbuf, bn, dh); - - /* set the key */ -- CAST_set_key(&castkey, i, rbuf); -+ CAST_set_key(&castkey, i, (unsigned char *)rbuf); - - /* session id. it's just a hashed version of the object pointer. */ - sessid = dhxhash(obj); -@@ -267,7 +276,7 @@ static int dhx_setup(void *obj, char *ib - *rbuflen += sizeof(sessid); - - /* public key */ -- BN_bn2bin(dh->pub_key, rbuf); -+ BN_bn2bin(pub_key, (unsigned char *)rbuf); - rbuf += KEYSIZE; - *rbuflen += KEYSIZE; - diff --git a/net/netatalk22/patches/patch-etc_uams_uams__dhx__passwd.c b/net/netatalk22/patches/patch-etc_uams_uams__dhx__passwd.c index 8eef848c8b13..8e9ab13d296e 100644 --- a/net/netatalk22/patches/patch-etc_uams_uams__dhx__passwd.c +++ b/net/netatalk22/patches/patch-etc_uams_uams__dhx__passwd.c @@ -1,45 +1,14 @@ -$NetBSD: patch-etc_uams_uams__dhx__passwd.c,v 1.2 2021/04/02 09:54:26 hauke Exp $ +$NetBSD: patch-etc_uams_uams__dhx__passwd.c,v 1.3 2023/01/10 22:07:33 hauke Exp $ -Adapt for new OpenSSL API. +Don't include headers that are not shipped ---- etc/uams/uams_dhx_passwd.c.orig 2014-03-16 11:17:48.000000000 +0000 +--- etc/uams/uams_dhx_passwd.c.orig 2022-07-12 04:08:24.000000000 +0000 +++ etc/uams/uams_dhx_passwd.c -@@ -81,6 +81,7 @@ static int pwd_login(void *obj, char *us - struct spwd *sp; - #endif /* SHADOWPW */ - BIGNUM *bn, *gbn, *pbn; -+ const BIGNUM *pub_key; - u_int16_t sessid; - size_t i; - DH *dh; -@@ -144,10 +145,18 @@ static int pwd_login(void *obj, char *us - return AFPERR_PARAM; - } - -+ if (!DH_set0_pqg(dh, pbn, NULL, gbn)) { -+ BN_free(pbn); -+ BN_free(gbn); -+ goto passwd_fail; -+ } -+ - /* generate key and make sure we have enough space */ -- dh->p = pbn; -- dh->g = gbn; -- if (!DH_generate_key(dh) || (BN_num_bytes(dh->pub_key) > KEYSIZE)) { -+ if (!DH_generate_key(dh)) { -+ goto passwd_fail; -+ } -+ DH_get0_key(dh, &pub_key, NULL); -+ if (BN_num_bytes(pub_key) > KEYSIZE) { - goto passwd_fail; - } - -@@ -164,7 +173,7 @@ static int pwd_login(void *obj, char *us - *rbuflen += sizeof(sessid); - - /* send our public key */ -- BN_bn2bin(dh->pub_key, (unsigned char *)rbuf); -+ BN_bn2bin(pub_key, (unsigned char *)rbuf); - rbuf += KEYSIZE; - *rbuflen += KEYSIZE; - +@@ -37,7 +37,6 @@ + #include + #include + #include +-#include "openssl_compat.h" + #else /* OPENSSL_DHX */ + #include + #include diff --git a/net/netatalk22/patches/patch-etc_uams_uams__randnum.c b/net/netatalk22/patches/patch-etc_uams_uams__randnum.c deleted file mode 100644 index 9ac7404e8ee5..000000000000 --- a/net/netatalk22/patches/patch-etc_uams_uams__randnum.c +++ /dev/null @@ -1,106 +0,0 @@ -$NetBSD: patch-etc_uams_uams__randnum.c,v 1.2 2021/04/02 09:54:26 hauke Exp $ - -Adapt for new OpenSSL API. - ---- etc/uams/uams_randnum.c.orig 2017-07-09 11:03:31.000000000 +0000 -+++ etc/uams/uams_randnum.c -@@ -55,8 +55,8 @@ char *strchr (), *strrchr (); - - #define PASSWDLEN 8 - --static C_Block seskey; --static Key_schedule seskeysched; -+static DES_cblock seskey; -+static DES_key_schedule seskeysched; - static struct passwd *randpwd; - static u_int8_t randbuf[8]; - -@@ -146,7 +146,7 @@ static int afppasswd(const struct passwd - { - u_int8_t key[DES_KEY_SZ*2]; - char buf[MAXPATHLEN + 1], *p; -- Key_schedule schedule; -+ DES_key_schedule schedule; - FILE *fp; - unsigned int i, j; - int keyfd = -1, err = 0; -@@ -203,17 +203,17 @@ afppasswd_found: - key[j] = (unhex(key[i]) << 4) | unhex(key[i + 1]); - if (j <= DES_KEY_SZ) - memset(key + j, 0, sizeof(key) - j); -- key_sched((C_Block *) key, schedule); -+ DES_key_sched((DES_cblock *) key, &schedule); - memset(key, 0, sizeof(key)); - - if (set) { - /* NOTE: this takes advantage of the fact that passwd doesn't - * get used after this call if it's being set. */ -- ecb_encrypt((C_Block *) passwd, (C_Block *) passwd, schedule, -+ DES_ecb_encrypt((DES_cblock *) passwd, (DES_cblock *) passwd, &schedule, - DES_ENCRYPT); - } else { - /* decrypt the password */ -- ecb_encrypt((C_Block *) p, (C_Block *) p, schedule, DES_DECRYPT); -+ DES_ecb_encrypt((DES_cblock *) p, (DES_cblock *) p, &schedule, DES_DECRYPT); - } - memset(&schedule, 0, sizeof(schedule)); - } -@@ -362,10 +362,10 @@ static int randnum_logincont(void *obj, - - /* encrypt. this saves a little space by using the fact that - * des can encrypt in-place without side-effects. */ -- key_sched((C_Block *) seskey, seskeysched); -+ DES_key_sched((DES_cblock *) seskey, &seskeysched); - memset(seskey, 0, sizeof(seskey)); -- ecb_encrypt((C_Block *) randbuf, (C_Block *) randbuf, -- seskeysched, DES_ENCRYPT); -+ DES_ecb_encrypt((DES_cblock *) randbuf, (DES_cblock *) randbuf, -+ &seskeysched, DES_ENCRYPT); - memset(&seskeysched, 0, sizeof(seskeysched)); - - /* test against what the client sent */ -@@ -406,10 +406,10 @@ static int rand2num_logincont(void *obj, - seskey[i] <<= 1; - - /* encrypt randbuf */ -- key_sched((C_Block *) seskey, seskeysched); -+ DES_key_sched((DES_cblock *) seskey, &seskeysched); - memset(seskey, 0, sizeof(seskey)); -- ecb_encrypt( (C_Block *) randbuf, (C_Block *) randbuf, -- seskeysched, DES_ENCRYPT); -+ DES_ecb_encrypt((DES_cblock *) randbuf, (DES_cblock *) randbuf, -+ &seskeysched, DES_ENCRYPT); - - /* test against client's reply */ - if (memcmp(randbuf, ibuf, sizeof(randbuf))) { /* != */ -@@ -421,8 +421,8 @@ static int rand2num_logincont(void *obj, - memset(randbuf, 0, sizeof(randbuf)); - - /* encrypt client's challenge and send back */ -- ecb_encrypt( (C_Block *) ibuf, (C_Block *) rbuf, -- seskeysched, DES_ENCRYPT); -+ DES_ecb_encrypt((DES_cblock *) ibuf, (DES_cblock *) rbuf, -+ &seskeysched, DES_ENCRYPT); - memset(&seskeysched, 0, sizeof(seskeysched)); - *rbuflen = sizeof(randbuf); - -@@ -457,15 +457,15 @@ static int randnum_changepw(void *obj, c - return err; - - /* use old passwd to decrypt new passwd */ -- key_sched((C_Block *) seskey, seskeysched); -+ DES_key_sched((DES_cblock *) seskey, &seskeysched); - ibuf += PASSWDLEN; /* new passwd */ - ibuf[PASSWDLEN] = '\0'; -- ecb_encrypt( (C_Block *) ibuf, (C_Block *) ibuf, seskeysched, DES_DECRYPT); -+ DES_ecb_encrypt((DES_cblock *) ibuf, (DES_cblock *) ibuf, &seskeysched, DES_DECRYPT); - - /* now use new passwd to decrypt old passwd */ -- key_sched((C_Block *) ibuf, seskeysched); -+ DES_key_sched((DES_cblock *) ibuf, &seskeysched); - ibuf -= PASSWDLEN; /* old passwd */ -- ecb_encrypt((C_Block *) ibuf, (C_Block *) ibuf, seskeysched, DES_DECRYPT); -+ DES_ecb_encrypt((DES_cblock *) ibuf, (DES_cblock *) ibuf, &seskeysched, DES_DECRYPT); - if (memcmp(seskey, ibuf, sizeof(seskey))) - err = AFPERR_NOTAUTH; - else if (memcmp(seskey, ibuf + PASSWDLEN, sizeof(seskey)) == 0) diff --git a/net/netatalk22/patches/patch-include_atalk_ldapconfig.h b/net/netatalk22/patches/patch-include_atalk_ldapconfig.h deleted file mode 100644 index 6c20d0cffcff..000000000000 --- a/net/netatalk22/patches/patch-include_atalk_ldapconfig.h +++ /dev/null @@ -1,22 +0,0 @@ -$NetBSD: patch-include_atalk_ldapconfig.h,v 1.3 2021/04/02 09:54:26 hauke Exp $ - -Correct an erroneous patch that was unfortunately submitted upstream. - -Providing an empty header because we do not support ACLs only serves -to break ldap support. - ---- include/atalk/ldapconfig.h.orig 2017-07-09 11:03:31.000000000 +0000 -+++ include/atalk/ldapconfig.h -@@ -1,5 +1,4 @@ - #ifdef HAVE_LDAP --#ifdef HAVE_ACLS - - #ifndef LDAPCONFIG_H - #define LDAPCONFIG_H -@@ -40,5 +39,5 @@ extern struct pref_array prefs_array[]; - extern int ldap_config_valid; - - #endif /* LDAPCONFIG_H */ --#endif /* HAVE_ACLS */ -+ - #endif /* HAVE_LDAP */ diff --git a/net/netatalk22/patches/patch-libatalk_asp_asp__getsess.c b/net/netatalk22/patches/patch-libatalk_asp_asp__getsess.c deleted file mode 100644 index 6a29f950a3d1..000000000000 --- a/net/netatalk22/patches/patch-libatalk_asp_asp__getsess.c +++ /dev/null @@ -1,18 +0,0 @@ -$NetBSD: patch-libatalk_asp_asp__getsess.c,v 1.2 2022/01/28 21:18:19 nat Exp $ - -Allow -1 as a vaild tickleval to disable session tickles. -As needed on appletalk 58. - ---- libatalk/asp/asp_getsess.c.orig 2014-09-01 17:19:35.000000000 +0000 -+++ libatalk/asp/asp_getsess.c -@@ -163,8 +163,8 @@ ASP asp_getsession(ASP asp, server_child - - timer.it_interval.tv_sec = timer.it_value.tv_sec = tickleval; - timer.it_interval.tv_usec = timer.it_value.tv_usec = 0; -- if ((sigaction(SIGALRM, &action, NULL) < 0) || -- (setitimer(ITIMER_REAL, &timer, NULL) < 0)) { -+ if (tickleval && ((sigaction(SIGALRM, &action, NULL) < 0) || -+ (setitimer(ITIMER_REAL, &timer, NULL) < 0))) { - free(asp_ac); - server_asp = NULL; - asp_ac = NULL; diff --git a/net/netatalk22/patches/patch-libatalk_bstring_bstrlib.c b/net/netatalk22/patches/patch-libatalk_bstring_bstrlib.c deleted file mode 100644 index f77683a6ed61..000000000000 --- a/net/netatalk22/patches/patch-libatalk_bstring_bstrlib.c +++ /dev/null @@ -1,22 +0,0 @@ -$NetBSD: patch-libatalk_bstring_bstrlib.c,v 1.1 2017/07/08 19:38:18 hauke Exp $ - -When a compiler complains about a missing prototype for a libc -function, just inserting one for what you think the interface might be -is probably not a good idea. - ---- libatalk/bstring/bstrlib.c.orig 2013-03-05 06:24:48.000000000 +0000 -+++ libatalk/bstring/bstrlib.c -@@ -2736,13 +2736,6 @@ struct genBstrList g; - #define exvsnprintf(r,b,n,f,a) {vsprintf (b,f,a); r = -1;} - #define START_VSNBUFF (256) - #else -- --#ifdef __GNUC__ --/* Something is making gcc complain about this prototype not being here, so -- I've just gone ahead and put it in. */ --extern int vsnprintf (char *buf, size_t count, const char *format, va_list arg); --#endif -- - #define exvsnprintf(r,b,n,f,a) {r = vsnprintf (b,n,f,a);} - #endif - #endif diff --git a/net/netatalk22/patches/patch-man_man5_afpd.conf.5.tmpl b/net/netatalk22/patches/patch-man_man5_afpd.conf.5.tmpl deleted file mode 100644 index 41d33c60f59a..000000000000 --- a/net/netatalk22/patches/patch-man_man5_afpd.conf.5.tmpl +++ /dev/null @@ -1,15 +0,0 @@ -$NetBSD: patch-man_man5_afpd.conf.5.tmpl,v 1.2 2022/01/28 21:18:19 nat Exp $ - -Allow -1 as a vaild tickleval to disable session tickles. -As needed on appletalk 58. - ---- man/man5/afpd.conf.5.tmpl.orig 2014-04-08 08:47:12.000000000 +0000 -+++ man/man5/afpd.conf.5.tmpl -@@ -598,6 +598,7 @@ These options are useful for debugging o - \-tickleval \fI[number]\fR - .RS 4 - Sets the tickle timeout interval (in seconds)\&. Defaults to 30\&. -+A value of 0 disables session tickles. - .RE - .PP - \-timeout \fI[number]\fR