From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29799 invoked by alias); 20 Mar 2018 05:02:40 -0000 Mailing-List: contact zsh-users-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Users List List-Post: List-Help: List-Unsubscribe: X-Seq: 23264 Received: (qmail 1472 invoked by uid 1010); 20 Mar 2018 05:02:40 -0000 X-Qmail-Scanner-Diagnostics: from forward102p.mail.yandex.net by f.primenet.com.au (envelope-from , uid 7791) with qmail-scanner-2.11 (clamdscan: 0.99.2/21882. spamassassin: 3.4.1. Clear:RC:0(77.88.28.102):SA:0(-2.6/5.0):. Processed in 1.894295 secs); 20 Mar 2018 05:02:40 -0000 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H2,SPF_PASS autolearn=ham autolearn_force=no version=3.4.1 X-Envelope-From: mva@mva.name X-Qmail-Scanner-Mime-Attachments: |signature.asc| X-Qmail-Scanner-Zip-Files: | From: "Vadim A. Misbakh-Soloviov" To: zsh-users@zsh.org Subject: Re: zsh/pcre module breakage when static build enabled Date: Tue, 20 Mar 2018 12:02:29 +0700 Message-ID: <6313372.JVeoKJF25W@note> In-Reply-To: <20180319234236.GA43407@tower.spodhuis.org> References: <3073701.qdQlh9y6XZ@note> <20180319234236.GA43407@tower.spodhuis.org> MIME-Version: 1.0 Content-Type: multipart/signed; boundary="nextPart3203207.uvWuC3TopE"; micalg="pgp-sha256"; protocol="application/pgp-signature" --nextPart3203207.uvWuC3TopE Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="UTF-8" =D0=92 =D0=BF=D0=B8=D1=81=D1=8C=D0=BC=D0=B5 =D0=BE=D1=82 =D0=B2=D1=82=D0=BE= =D1=80=D0=BD=D0=B8=D0=BA, 20 =D0=BC=D0=B0=D1=80=D1=82=D0=B0 2018 =D0=B3. 6:= 42:36 +07 =D0=BF=D0=BE=D0=BB=D1=8C=D0=B7=D0=BE=D0=B2=D0=B0=D1=82=D0=B5=D0= =BB=D1=8C Phil Pennock=20 =D0=BD=D0=B0=D0=BF=D0=B8=D1=81=D0=B0=D0=BB: > On 2018-03-20 at 00:33 +0700, Vadim A. Misbakh-Soloviov wrote: > > Hi there! > > I faced strange issue: when I build zsh-5.4.2 as static binary and tryi= ng > > to>=20 > > run, for example, something like that: > > > $ [[ 'foo=E2=86=92bar' =3D~ .([^[:ascii:]]). ]]; print $MATCH > >=20 > > I'm getting following errors: > > > zsh: module `zsh/pcre' has no such feature: `C:pcre-match' > > > zsh: -pcre-match not available for regex > >=20 > > Although, when I rebuild it as dynamically linked binary, pcre starting= to > > work again > >=20 > > I think, it looks like a bug. > >=20 > > Isn't it a way to fix it? >=20 > I went to do a static build on FreeBSD (Darwin doesn't support static > binaries) and when grabbing the configure options used by Ports, saw > this: >=20 > ## Some modules can only be built as a shared library. > ## If you enable STATIC, you may get strange errors if you, a script, > ## or a plugin tries to use the regex module. >=20 > So someone has spotted this before, but I don't recall seeing a > bug-report. Well, yup. Even some of my friends said they faced that too. > Here's what I did. Did you perhaps skip the '--disable-dynamic' option, > required to change how zsh manages the module code when building > statically? Well, actually, I'm using Gentoo (and it's "static" use-flag). And final=20 configure-string is (for experiment clearance I also took version from git= =20 HEAD): > ./configure --prefix=3D/usr --build=3Dx86_64-pc-linux-gnu --host=3Dx86_64= =2Dpc- linux-gnu --mandir=3D/usr/share/man --infodir=3D/usr/share/info --datadir= =3D/usr/ share --sysconfdir=3D/etc --localstatedir=3D/var/lib --docdir=3D/usr/share/= doc/ zsh-9999 --htmldir=3D/usr/share/doc/zsh-9999/html --bindir=3D/bin --libdir= =3D/usr/ lib64 --enable-etcdir=3D/etc/zsh --enable-runhelpdir=3D/usr/share/zsh/9999/= help -- enable-fndir=3D/usr/share/zsh/9999/functions --enable-site-fndir=3D/usr/sha= re/zsh/ site-functions --enable-function-subdirs --with-tcsetpgrp --enable-maildir- support --enable-pcre --enable-cap --enable-multibyte --enable-unicode9 -- enable-gdbm --disable-dynamic And there is also seddig similar to yours, and, as result: > name=3Dzsh/pcre modfile=3DSrc/Modules/pcre.mdd link=3Dstatic auto=3Dyes l= oad=3Dno > name=3Dzsh/regex modfile=3DSrc/Modules/regex.mdd link=3Dstatic auto=3Dyes= load=3Dno Although, result still the same as in release version. > make install.bin install.modules install.fns Although, instead of this, ebuild just doing `make install install.info`, a= nd=20 then copies completions and so on by itself. But as far as I understand principles of static build, it shouldn't interfe= re=20 in any way, since the binary (zsh) --nextPart3203207.uvWuC3TopE Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part. Content-Transfer-Encoding: 7Bit -----BEGIN PGP SIGNATURE----- iHUEABYIAB0WIQTxiw6i5QzSBiZgM/FnZfRvKOlgfgUCWrCV5QAKCRBnZfRvKOlg fmdcAP9Mb+8h9y+E/n8sPQOBl00YovM83K63c2Tww2dULzSxxAEAxUom110K/i3l PC6tJBd2+5IJGgu6L/J5iX8DyZfWwgM= =9y6N -----END PGP SIGNATURE----- --nextPart3203207.uvWuC3TopE--