Re: [patch] www/firefox-esr: add suffix - ESR to NAME in .desktop

2022-05-25 Thread Landry Breuil
Le Tue, May 24, 2022 at 10:09:41AM -0300, Juan Picca a écrit :
> On Tue, May 24, 2022 at 12:11:07PM +0200, Landry Breuil wrote:
> > in post-install
> > we already use SUBST_DATA on the desktop file; was wondering if we could
> > do both operations at the same spot in the Makefile for ease of
> > maintenance.
> 
> I used awk before SUBST_DATA to avoid messing with the file permissions
> modified by SUBST_DATA.
> 
> > If you cant wrap a complete patch (taking care of the other execs to fix
> > too) I'll try to take care of this in the coming days, poke me if i
> > forgot.
> 
> Done
> 
> Regards,
> JMPC

Thanks a lot, commited with a REVISION bump after testing that it
properly does what's it supposed to do :)

Landry



Re: www/firefox-esr + amdgpu + unveil problem

2022-05-25 Thread Landry Breuil
Le Tue, May 24, 2022 at 06:04:27PM -0400, George Koehler a écrit :
> Hi,
> 
> This mail is about the OpenBSD package of firefox-esr-91.9.1, on my
> amd64 with amdgpu.  Some tabs crashed.  My reproducer stopped crashing
> after I unveiled /dev/dri in the content process,

Thanks for the details bugreport, i'll have to undust the amdgpu laptop
to test, but some observations/questions first:
- does the same problem also affect firefox 100 ?
- i cant find a dev/dri call in the codepaths we use in firefox,
  there's one in linux sandboxing but we dont use it (cf
https://searchfox.org/mozilla-central/source/security/sandbox/linux/broker/SandboxBrokerPolicyFactory.cpp#69)
- from my understanding of the trace, iff you unveil /dev/dri then
  radeonsi_dri.so is used and the crashing codepath in swrast_dri.so
isnt used ? or in both cases swrast_dri is used, and we should rather
figure out why radeonsi_dri isnt found/used ?
- of course i have zero objections unveiling dev/dri instead of
  dev/dri/card0 if it helps webgl on amdgpu, just wondering if it should
be done only for the content process or also for the gpu process.

Landry



Re: www/firefox-esr + amdgpu + unveil problem

2022-05-25 Thread Landry Breuil
Le Wed, May 25, 2022 at 09:47:53AM +0200, Landry Breuil a écrit :
> Le Tue, May 24, 2022 at 06:04:27PM -0400, George Koehler a écrit :
> > Hi,
> > 
> > This mail is about the OpenBSD package of firefox-esr-91.9.1, on my
> > amd64 with amdgpu.  Some tabs crashed.  My reproducer stopped crashing
> > after I unveiled /dev/dri in the content process,
> 
> Thanks for the details bugreport, i'll have to undust the amdgpu laptop
> to test, but some observations/questions first:
> - does the same problem also affect firefox 100 ?

ive been able to reproduce the crash on firefox-esr on the T495s, and
can confirm that unveiling /dev/dri for content process works around the
crash.

what puzzles me then is that i cant reproduce the failure with 101.0rc1,
(using an empty new profile) where the reproducer just displays an empty
page but doesnt crash.

stderr shows this:
$firefox /tmp/crashgl.html  
Crash Annotation GraphicsCriticalError: |[0][GFX1-]: glxtest: libpci missing 
(t=0.717875) [GFX1-]: glxtest: libpci missing
ATTENTION: default value of option mesa_glthread overridden by environment.
ATTENTION: default value of option mesa_glthread overridden by environment.
amdgpu: os_same_file_description couldn't determine if two DRM fds reference 
the same file description. If they do, bad things may happen!
ATTENTION: default value of option mesa_glthread overridden by environment.
libEGL warning: MESA-LOADER: failed to retrieve device information 
libEGL warning: MESA-LOADER: failed to retrieve device information
ATTENTION: default value of option mesa_glthread overridden by environment.

I'll check other differences between /etc/firefox & /etc/firefox-esr to
see if its a difference in unveil/pledge configs or distinct codepaths
taken within firefox.

Landry



[s...@spacehopper.org: Re: 回复: [NEW]astro/py-pyerfa]

2022-05-25 Thread Stuart Henderson
Any OKs to import the deps needed to update this?

--- Begin Message ---
On 2022/03/27 11:03, wen heping wrote:
> Revised patch:
> 
>i) Add 2 new ports : devel/py-pytest-doctestplus devel/py-pytest-remoted
>   Both are TEST_DEPENDS
>ii) Now pyerfa build well and run well , pass all (260) tests.

Merged in with my versions, yours had some porting issues (I think some of
them came from using portgen, which does a poor job with Python ports),
and it was easier to do it that way round than apply my changes to yours.

"setup.py test" shouldn't be used as it is going away in a future version.

Here's an updated tar including the new deps including those needed for
running a good test of sets in astropy. It takes a long time to run them,
results:

=== short test summary info 
FAILED astropy/utils/tests/test_data.py::test_update_parallel - OSError: [Err...
FAILED astropy/utils/tests/test_data.py::test_update_parallel_multi - OSError...
FAILED 
astropy/visualization/wcsaxes/tests/test_misc.py::test_simplify_labels_usetex
FAILED astropy/visualization/wcsaxes/tests/test_misc.py::test_bbox_size[0.2]
 4 failed, 19688 passed, 224 skipped, 63 xfailed in 1637.30s (0:27:17) =

None of the failures seem important, and one of them probably goes away if the
right subpackage of texlive is installed.


astropy-deps.tgz
Description: application/tar-gz


py-astropy.diff.gz
Description: application/gunzip
--- End Message ---


Re: update devel/libffi to 3.4.2

2022-05-25 Thread Omar Polo
friendly ping :)

Omar Polo  wrote:
> Hello Jasper, ports@
> 
> I wanted to update java/jna (to work with jdk-11) but that needs an
> updated libffi too.
> 
> The development of libffi seems to have moved to github, at least for
> the release tarballs, and some patches were upstreamed.
> 
> Regarding the shlib version: looking at check_sym it seems to warrant
> only a minor bump (5 symbols added) but upstream bumped the major 2
> years ago with this commit:
> 
> https://github.com/libffi/libffi/commit/7855656148b96c7070ec362d2a73af840025a2b7
> 
> the change to FFI_TRAMPOLINE_SIZE probably requires a major bump; I went
> with it to stay on the safe side.
> 
> The list of consumer is daunting and I can't test everything nor run a
> bulk.  So far I tested on amd64:
> 
>  - java/jna: (post update, see other thread) builds fine + all tests passing
>  - lang/gforth: builds fine + all tests passing
>  - lang/guile2: builds fine + and ffi tests are passing
>  - lang/python/3.9: builds fine and the failing tests don't seem to be
>related to libffi
>  - lang/ruby/3.1: like python-3.9

gnezdo@ tested also lang/ghc and devel/cabal-install on amd64 (thanks!)

> plus some testing with guile3 (not in ports yet.)  I have the build and
> tests log for these I can share if needed.
> 
> Comments and further testing (especially on !amd64) is appreciated :)
> 
> 
> The changelog is:
> 
> Add static trampoline support for Linux on x86_64 and ARM64.
> Add support for Alibaba's CSKY architecture.
> Add support for Kalray's KVX architecture.
> Add support for Intel Control-flow Enforcement Technology (CET).
> Add support for ARM Pointer Authentication (PA).
> Fix 32-bit PPC regression.
> Fix MIPS soft-float problem.
> Enable tmpdir override with the $LIBFFI_TMPDIR environment variable.
> Enable compatibility with MSVC runtime stack checking.
> Reject float and small integer argument in ffi_prep_cif_var().
>   Callers must promote these types themselves.

Index: Makefile
===
RCS file: /home/cvs/ports/devel/libffi/Makefile,v
retrieving revision 1.45
diff -u -p -r1.45 Makefile
--- Makefile11 Mar 2022 18:50:31 -  1.45
+++ Makefile14 May 2022 09:09:29 -
@@ -1,8 +1,8 @@
 COMMENT=   Foreign Function Interface
 
-DISTNAME=  libffi-3.3
-REVISION=  1
-SHARED_LIBS +=  ffi  1.2  # .6.4
+V= 3.4.2
+DISTNAME=  libffi-$V
+SHARED_LIBS +=  ffi  2.0  # 9.0
 CATEGORIES=devel
 
 MAINTAINER=Jasper Lievisse Adriaanse 
@@ -17,8 +17,7 @@ PERMIT_PACKAGE=   Yes
 WANTLIB += c++abi
 .endif
 
-MASTER_SITES=  https://sourceware.org/pub/libffi/ \
-   ftp://sourceware.org/pub/libffi/
+MASTER_SITES= https://github.com/libffi/libffi/releases/download/v$V/
 
 DEBUG_PACKAGES =   ${BUILD_PACKAGES}
 
Index: distinfo
===
RCS file: /home/cvs/ports/devel/libffi/distinfo,v
retrieving revision 1.6
diff -u -p -r1.6 distinfo
--- distinfo10 Feb 2020 18:06:34 -  1.6
+++ distinfo14 May 2022 10:01:48 -
@@ -1,2 +1,2 @@
-SHA256 (libffi-3.3.tar.gz) = cvunkicD3fp6Ao1ROsFahcjVTI1n9V+lpIAohdxlIFY=
-SIZE (libffi-3.3.tar.gz) = 1305466
+SHA256 (libffi-3.4.2.tar.gz) = VA+3IWGaaro73u99lA2Ong5tLBk1lbwkMkG3f/npNiA=
+SIZE (libffi-3.4.2.tar.gz) = 1351355
Index: patches/patch-configure
===
RCS file: /home/cvs/ports/devel/libffi/patches/patch-configure,v
retrieving revision 1.12
diff -u -p -r1.12 patch-configure
--- patches/patch-configure 11 Mar 2022 18:50:31 -  1.12
+++ patches/patch-configure 14 May 2022 09:06:48 -
@@ -3,7 +3,7 @@
 Index: configure
 --- configure.orig
 +++ configure
-@@ -18475,6 +18475,12 @@ $as_echo "#define SYMBOL_UNDERSCORE 1" >>confdefs.h
+@@ -18650,6 +18650,12 @@ $as_echo "#define SYMBOL_UNDERSCORE 1" >>confdefs.h
  
  fi
  
Index: patches/patch-configure_host
===
RCS file: /home/cvs/ports/devel/libffi/patches/patch-configure_host,v
retrieving revision 1.2
diff -u -p -r1.2 patch-configure_host
--- patches/patch-configure_host11 Mar 2022 18:50:31 -  1.2
+++ patches/patch-configure_host14 May 2022 09:06:48 -
@@ -1,12 +1,12 @@
 Index: configure.host
 --- configure.host.orig
 +++ configure.host
-@@ -203,7 +203,7 @@ case "${host}" in
+@@ -216,7 +216,7 @@ case "${host}" in
TARGET=POWERPC_FREEBSD; TARGETDIR=powerpc
-   HAVE_LONG_DOUBLE_VARIANT=1
+   CFLAGS="$CFLAGS -D__NO_FPRS__"
;;
--  powerpc64-*-freebsd*)
-+  powerpc64-*-freebsd* | powerpc64-*-openbsd*)
+-  powerpc64-*-freebsd* | powerpc64le-*-freebsd*)
++  powerpc64-*-freebsd* | powerpc64le-*-freebsd* | powerpc64-*-openbsd*)
TARGET=POWERPC; TAR

Re: HEADS-UP: devel/cmake update - needs bulk tests

2022-05-25 Thread Stuart Henderson
On 2022/05/24 22:26, Theo Buehler wrote:
> > Nobody? New synced diff below.
> 
> How can we move this forward? I think the diff is ready to go in. If no
> bulk builders of !amd64 and !lld arches run tests, I suppose we'll have
> to sort out the fallout the hard way.

I think at this point just commit it. OK




Re: devel/cmake: allow file(DOWNLOAD, ...) for file://... URLs

2022-05-25 Thread Stuart Henderson
On 2022/05/24 21:44, Rafael Sadowski wrote:
> On Sun May 22, 2022 at 12:21:48PM +0100, Stuart Henderson wrote:
> > This does seem sensible as long as it isn't some file which you might later
> > need to patch to fix something quickly.
> > 
> > I think this is OK but will defer to ${MAINTAINER} if opinions differ :)
> > 
> 
> I agree but I want to block this until the 3.23 update is in.
> 

yes fair point.



Re: [update] geo/traccar 5.0

2022-05-25 Thread Renaud Allard


On 5/24/22 09:22, Renaud Allard wrote:


Hello,

Here is a diff for geo/traccar to version 5.0.
One notable change is that the "modern web app" is now the default 
interface. The old "legacy app" can also bve selected at login.


Best Regards



Is there any issue with the diff?


smime.p7s
Description: S/MIME Cryptographic Signature


Re: [update] geo/traccar 5.0

2022-05-25 Thread Stuart Henderson
You only sent it yesterday, it is a bit early to be prodding

On 2022/05/25 12:48, Renaud Allard wrote:
> 
> On 5/24/22 09:22, Renaud Allard wrote:
> > 
> > Hello,
> > 
> > Here is a diff for geo/traccar to version 5.0.
> > One notable change is that the "modern web app" is now the default
> > interface. The old "legacy app" can also bve selected at login.
> > 
> > Best Regards
> 
> 
> Is there any issue with the diff?




Re: update: sysutils/sec

2022-05-25 Thread Okan Demirmen
bump ok?

On Sat 2022.05.07 at 12:55 -0400, Okan Demirmen wrote:
> Hi,
> 
> Maintainer update sec to 2.9.1.
> 
> okay?
> 
> Regards,
> Okan
> 
> Index: Makefile
> ===
> RCS file: /home/open/cvs/ports/sysutils/sec/Makefile,v
> retrieving revision 1.37
> diff -u -p -r1.37 Makefile
> --- Makefile  9 Jun 2021 12:36:26 -   1.37
> +++ Makefile  7 May 2022 16:48:23 -
> @@ -2,7 +2,7 @@
>  
>  COMMENT= simple event correlator
>  
> -V=   2.9.0
> +V=   2.9.1
>  DISTNAME=sec-${V}
>  CATEGORIES=  sysutils
>  MASTER_SITES=
> https://github.com/simple-evcorr/sec/releases/download/${V}/
> Index: distinfo
> ===
> RCS file: /home/open/cvs/ports/sysutils/sec/distinfo,v
> retrieving revision 1.31
> diff -u -p -r1.31 distinfo
> --- distinfo  9 Jun 2021 12:36:26 -   1.31
> +++ distinfo  7 May 2022 16:48:38 -
> @@ -1,2 +1,2 @@
> -SHA256 (sec-2.9.0.tar.gz) = dBFU0l22lwbiIA4Rm1zTLWWuC4A9nA+u/Mz7z+HJdQM=
> -SIZE (sec-2.9.0.tar.gz) = 152136
> +SHA256 (sec-2.9.1.tar.gz) = Y6QSWTCn3I1x7mfy67QuYHrAxmIW4TSfJ57OjyhyCjQ=
> +SIZE (sec-2.9.1.tar.gz) = 153305
> 



Update: ruby-pg 1.3.5

2022-05-25 Thread Jeremy Evans
Simple update to the latest release of the pg gem. Release notes
available at https://github.com/ged/ruby-pg/blob/master/History.rdoc

Tested on amd64.  Will commit in a couple days unless I hear objections.

Thanks,
Jeremy

Index: Makefile
===
RCS file: /cvs/ports/databases/ruby-pg/Makefile,v
retrieving revision 1.44
diff -u -p -r1.44 Makefile
--- Makefile18 Mar 2022 20:47:45 -  1.44
+++ Makefile25 May 2022 20:04:12 -
@@ -1,6 +1,6 @@
 COMMENT =  PostgreSQL database interface for ruby
 
-DISTNAME = pg-1.3.4
+DISTNAME = pg-1.3.5
 CATEGORIES =   databases
 
 MAINTAINER =   Jeremy Evans 
Index: distinfo
===
RCS file: /cvs/ports/databases/ruby-pg/distinfo,v
retrieving revision 1.27
diff -u -p -r1.27 distinfo
--- distinfo18 Mar 2022 20:47:45 -  1.27
+++ distinfo25 May 2022 20:04:27 -
@@ -1,2 +1,2 @@
-SHA256 (pg-1.3.4.gem) = q7I3I0Y/3IyHf0Jnm4QOgVGO4mtHK1rE/TFW+tUcDCQ=
-SIZE (pg-1.3.4.gem) = 200192
+SHA256 (pg-1.3.5.gem) = JtY/8CenLlCVDMDtoLo4qHjdWdfMJwXSM0qWPFj9PoM=
+SIZE (pg-1.3.5.gem) = 201216



Re: [update] emulators/bochs to 2.7

2022-05-25 Thread Omar Polo
rgc  wrote:
> checking for mvaddch in -lcurses... yes
> Package curses was not found in the pkg-config search path
> checking for mvaddch in -lncurses... yes
> Package ncurses was not found in the pkg-config search path
> checking for mvaddch in -ltermlib... yes
> Package termlib was not found in the pkg-config search path
> checking for mvaddch in -lpdcurses... no
> Curses library not found: tried curses, ncurses, termlib and pdcurses.
> *** Error 1 in . (/usr/ports/infrastructure/mk/bsd.port.mk:2928 
> 'do-configure': @for d in /usr/ports/pobj/bochs-2.7/bochs-2.7;  do  cp -f 
> /u...)
> *** Error 2 in . (/usr/ports/infrastructure/mk/bsd.port.mk:2948 
> '/usr/ports/pobj/bochs-2.7/.configure_done': @cd /usr/ports/emulators/bochs 
> ...)
> *** Error 2 in /usr/ports/emulators/bochs 
> (/usr/ports/infrastructure/mk/bsd.port.mk:2607 'all': @lock=bochs-2.7;  
> export _LOCKS_HELD=" bochs...)
> 
> one thing to note about the patch i originally submitted.
> i removed "--with-term" because i could not figure out how
> to fix the above ^^^ error, even with ncurses installed
> 
> i still haven't figured out the problem but attaching a
> modified patch with "--with-term" which, of course, does
> not compile

the configure script wants to get the LDFLAGS for ncurses using
pkg-config, but we don't ship .pc files for libncurses, so it fails.

Fixing it is not difficult, but we need to patch the configure script a
bit and regen it, I don't see a simpler solution.

I'm also a bit hesitant in dropping the no_x11 flavor yet, if we really
want to do it then we may also rearrange the makefile a bit.  I'd
postpone that matter. 

I'm attaching an updated diff that compiles, I still haven't had the
time to properly play with this :/

Thanks,

Omar Polo

Index: Makefile
===
RCS file: /home/cvs/ports/emulators/bochs/Makefile,v
retrieving revision 1.75
diff -u -p -r1.75 Makefile
--- Makefile11 Mar 2022 18:59:33 -  1.75
+++ Makefile25 May 2022 21:05:21 -
@@ -1,11 +1,10 @@
 COMMENT=   x86 machine simulator
 
-DISTNAME=  bochs-2.6.9
+DISTNAME=  bochs-2.7
 CATEGORIES=emulators
 MASTER_SITES=  ${MASTER_SITE_SOURCEFORGE:=bochs/}
-REVISION=  2
 
-HOMEPAGE=  http://bochs.sourceforge.net/
+HOMEPAGE=  https://bochs.sourceforge.net/
 
 # LGPLv2.1+ and MIT
 PERMIT_PACKAGE=Yes
@@ -14,7 +13,7 @@ WANTLIB += ${COMPILER_LIBCXX} c curses m
 
 COMPILER = base-clang ports-gcc base-gcc
 
-CONFIGURE_STYLE= gnu
+CONFIGURE_STYLE= gnu autoconf no-autoheader
 CONFIGURE_ARGS=--enable-all-optimizations \
--enable-avx \
--enable-e1000 \
@@ -28,7 +27,11 @@ CONFIGURE_ARGS=  --enable-all-optimizatio
--enable-usb \
--enable-usb-ohci \
--enable-vmx=2 \
-   --with-term
+   --with-term \
+   --enable-cet \
+   --enable-evex
+
+AUTOCONF_VERSION = 2.69
 
 FLAVORS=   debug no_x11
 FLAVOR?=
Index: distinfo
===
RCS file: /home/cvs/ports/emulators/bochs/distinfo,v
retrieving revision 1.23
diff -u -p -r1.23 distinfo
--- distinfo23 Apr 2017 13:25:29 -  1.23
+++ distinfo25 May 2022 20:53:12 -
@@ -1,2 +1,2 @@
-SHA256 (bochs-2.6.9.tar.gz) = 7ltnf9mxufSEta60YU9D3yGZMIjAwFcRh/k6ywhm6Yw=
-SIZE (bochs-2.6.9.tar.gz) = 5169187
+SHA256 (bochs-2.7.tar.gz) = oBCrG/3HKsWgjS4kEs1HHA/r1mrx2TSbwNeWh53lsXo=
+SIZE (bochs-2.7.tar.gz) = 5298413
Index: patches/patch-Makefile_in
===
RCS file: /home/cvs/ports/emulators/bochs/patches/patch-Makefile_in,v
retrieving revision 1.11
diff -u -p -r1.11 patch-Makefile_in
--- patches/patch-Makefile_in   11 Mar 2022 18:59:33 -  1.11
+++ patches/patch-Makefile_in   25 May 2022 20:53:12 -
@@ -1,8 +1,18 @@
 Don't gzip the man pages.
 
 Makefile.in.orig   Sat Mar 18 05:27:48 2017
-+++ Makefile.inTue Apr 11 21:57:44 2017
-@@ -471,8 +471,8 @@ clean_docbook::
+Index: Makefile.in
+--- Makefile.in.orig
 Makefile.in
+@@ -39,7 +39,7 @@ DESTDIR =
+ 
+ VERSION=@VERSION@
+ REL_STRING=@REL_STRING@
+-MAN_PAGE_1_LIST=bochs bximage bochs-dlx
++MAN_PAGE_1_LIST=bochs bximage
+ MAN_PAGE_5_LIST=bochsrc
+ INSTALL_LIST_SHARE=bios/BIOS-bochs-* bios/VGABIOS* bios/SeaBIOS* 
bios/SeaVGABIOS* bios/bios.bin-* bios/vgabios-cirrus.bin-* 
@INSTALL_LIST_FOR_PLATFORM@
+ INSTALL_LIST_DOC=CHANGES COPYING LICENSE README TODO misc/slirp.conf 
misc/vnet.conf
+@@ -463,8 +463,8 @@ clean_docbook::
  install_man::
-mkdir -p $(DESTDIR)$(man1dir)
-mkdir -p $(DESTDIR)$(man5dir)
Index: patches/patch-_bochsrc
===
RCS file: /home/cvs/ports/emulators/bochs/patches/patch-_bochsrc,v
retrieving revision 1.15
diff -u -p -r1.15 patch-_bochsrc
--- patches/patch-_bochsrc  11 Mar 2022 18:59

Re: shells/zsh: Update to 5.9

2022-05-25 Thread Matthew Martin
ping; still running without issues here

On Mon, May 16, 2022 at 07:46:20AM -0500, Matthew Martin wrote:
> zsh 5.9 was just announced[1]. I've been running the below for about
> a day and the prior release candidate for about a week before that
> without issues.
> 
> This update is a bit larger than usual. I finally tracked down the
> occasionally failing test in V08zpty. If you open a terminal to run make
> test, open and then close a separate terminal, and then run the tests
> without the below patch, tests that use zpty will hang because getpty
> cannot open the corresponding /dev/tty. The below patch uses openpty(3)
> instead which fixes the hang. The open and close a terminal is needed so
> the next available /dev/pty,tty pair are owned by your user.
> 
> I found this too close to the release to include in 5.9, but assuming it
> looks good and there's no fallout, will work to get it upstreamed.
> Since configure.ac is changed, need to run Util/preconfig to regenerate
> the configure script. This should all go away next release. The other
> test failure is known and because regexec(3) is not unicode aware.
> 
> - Matthew Martin
> 
> 1: https://www.zsh.org/mla/announce/msg00134.html
> 

diff --git Makefile Makefile
index 376e8298c38..b6ee32c4dfc 100644
--- Makefile
+++ Makefile
@@ -1,6 +1,6 @@
 COMMENT=   Z shell, Bourne shell-compatible
 
-V= 5.8.1
+V= 5.9
 DISTNAME=  zsh-$V
 CATEGORIES=shells
 
@@ -21,7 +21,7 @@ WANTLIB=  c curses iconv m pcre
 LIB_DEPENDS=   converters/libiconv \
devel/pcre
 
-CONFIGURE_STYLE=gnu
+CONFIGURE_STYLE=autoconf
 CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include" \
LDFLAGS="-L${LOCALBASE}/lib"
 
@@ -34,6 +34,8 @@ CONFIGURE_ARGS=   --disable-zsh-mem \
--disable-gdbm \
--with-tcsetpgrp
 
+AUTOCONF_VERSION=  2.71
+
 SUBST_VARS=V
 
 EXTFILES=  Calendar/calendar_add Example/cat Example/zless \
@@ -43,6 +45,7 @@ EXTFILES= Calendar/calendar_add Example/cat Example/zless 
\
Misc/zed Misc/zkbd
 
 pre-configure:
+   cd ${WRKSRC} && ./Util/preconfig
 .for i in ${EXTFILES}
sed -i -e "s,/bin/zsh,${TRUEPREFIX}/bin/zsh,g" \
${WRKSRC}/Functions/${i}
diff --git distinfo distinfo
index 62b4cf054d1..c5db9957732 100644
--- distinfo
+++ distinfo
@@ -1,2 +1,2 @@
-SHA256 (zsh-5.8.1.tar.xz) = tpc1ILrOYAtHeSACabHl155fUFrElSBYwRrVu/DdmRk=
-SIZE (zsh-5.8.1.tar.xz) = 3200540
+SHA256 (zsh-5.9.tar.xz) = m40ezt1bXoH78ZGOh2dSp92UjgXBoNuhCrhjhC1FrNU=
+SIZE (zsh-5.9.tar.xz) = 3332400
diff --git patches/patch-Src_Modules_zpty_c patches/patch-Src_Modules_zpty_c
new file mode 100644
index 000..4e2b3a70377
--- /dev/null
+++ patches/patch-Src_Modules_zpty_c
@@ -0,0 +1,63 @@
+Index: Src/Modules/zpty.c
+--- Src/Modules/zpty.c.orig
 Src/Modules/zpty.c
+@@ -37,6 +37,15 @@
+ #endif
+ #endif
+ 
++#ifdef HAVE_OPENPTY
++#ifdef OPENPTY_REQUIRES_PTY
++#include 
++#elif defined(OPENPTY_REQUIRES_UTIL)
++#include 
++#include 
++#endif
++#endif
++
+ /* The number of bytes we normally read when given no pattern and the
+  * upper bound on the number of bytes we read (even if we are give a
+  * pattern). */
+@@ -161,9 +170,27 @@ getptycmd(char *name)
+ return NULL;
+ }
+ 
+-/* posix_openpt() seems to have some problem on OpenBSD */
+-#if defined(USE_DEV_PTMX) && !defined(__OpenBSD__)
++#ifdef HAVE_OPENPTY
+ 
++static int
++get_pty(int master, int *retfd)
++{
++static int mfd, sfd;
++
++if (master) {
++  if (openpty(&mfd, &sfd, NULL, NULL, NULL) == -1) {
++  return 1;
++  }
++  *retfd = mfd;
++  return 0;
++}
++
++*retfd = sfd;
++return 0;
++}
++
++#elifdef USE_DEV_PTMX
++
+ #ifdef HAVE_SYS_STROPTS_H
+ #include 
+ #endif
+@@ -261,12 +288,7 @@ get_pty(int master, int *retfd)
+ #elif defined(__FreeBSD__) || defined(__DragonFly__)
+ static char char1[] = "pqrsPQRS";
+ static char char2[] = "0123456789abcdefghijklmnopqrstuv";
+-#elif defined(__OpenBSD__)
+-static char char1[] = "pqrstuvwxyzPQRST";
+-static char char2[] = "0123456789"
+-  "abcdefghijklmnopqrstuvwxyz"
+-  "ABCDEFGHIJKLMNOPQRSTUVWXYZ";
+-#else /* __FreeBSD__ || __DragonFly__  || __OpenBSD*/
++#else /* __FreeBSD__ || __DragonFly__ */
+ static char char1[] = "pqrstuvwxyzPQRST";
+ static char char2[] = "0123456789abcdef";
+ #endif
diff --git patches/patch-configure_ac patches/patch-configure_ac
new file mode 100644
index 000..939be0046a2
--- /dev/null
+++ patches/patch-configure_ac
@@ -0,0 +1,41 @@
+Index: configure.ac
+--- configure.ac.orig
 configure.ac
+@@ -2401,6 +2401,37 @@ dnl ---
+ zsh_CHECK_SOCKLEN_T
+ 
+ dnl ---
++dnl Check for openpty support
++dnl ---
++AH_TEMPLATE([HAVE_OPENPTY],
++  [Define to 1 if you have the `openpty' function.])
++AH_TEMPLATE([OPENPTY_REQUIRES_PTY],
++  [Define to 1 if the `openpty' function require