Opened 12 years ago
Closed 12 years ago
#36354 closed defect (fixed)
docbook-utils @ 0.6.14 regex bug
Reported by: | lockhart (Thomas Lockhart) | Owned by: | macports-tickets@… |
---|---|---|---|
Priority: | Normal | Milestone: | |
Component: | ports | Version: | 2.1.2 |
Keywords: | haspatch maintainer | Cc: | ryandesign (Ryan Carsten Schmidt), pixilla (Bradley Giesbrecht), pgf |
Port: | docbook-utils |
Description (last modified by ryandesign (Ryan Carsten Schmidt))
The jw script wrapper contains two regex patterns fed to both grep and sed. GNU grep 2.5.1 on Lion did not complain, but Mountain Lion apparently ships BSD grep 2.5.1-FreeBSD and this one complains about it. But in any case the regex seems to be broken on all versions; it uses a character class [:space:] but does not surround it with an extra bracket (e.g. [[:space:]]) and does not call grep with the -E option to allow it to recognize extended patterns. Patch is tested on both Lion and Mountain Lion.
Attachments (13)
Change History (24)
comment:2 Changed 12 years ago by ryandesign (Ryan Carsten Schmidt)
Description: | modified (diff) |
---|
comment:3 Changed 12 years ago by lockhart (Thomas Lockhart)
Changed 12 years ago by lockhart (Thomas Lockhart)
Attachment: | Portfile.diff added |
---|
Portfile using all patches available in the current Fedora 18 RPM. Includes fixes for regular expressions.
Changed 12 years ago by lockhart (Thomas Lockhart)
Attachment: | docbook-utils-2ndspaces.patch added |
---|
Patchfile from Fedora 18 RPM.
Changed 12 years ago by lockhart (Thomas Lockhart)
Attachment: | docbook-utils-grepnocolors.patch added |
---|
Patchfile from Fedora 18 RPM.
Changed 12 years ago by lockhart (Thomas Lockhart)
Attachment: | docbook-utils-newgrep.patch added |
---|
Patchfile from Fedora 18 RPM.
Changed 12 years ago by lockhart (Thomas Lockhart)
Attachment: | docbook-utils-newgrep.2.patch added |
---|
Patchfile from Fedora 18 RPM.
Changed 12 years ago by lockhart (Thomas Lockhart)
Attachment: | docbook-utils-nofinalecho.patch added |
---|
Patchfile from Fedora 18 RPM.
Changed 12 years ago by lockhart (Thomas Lockhart)
Attachment: | docbook-utils-papersize.patch added |
---|
Patchfile from Fedora 18 RPM.
Changed 12 years ago by lockhart (Thomas Lockhart)
Attachment: | docbook-utils-rtfmanpage.patch added |
---|
Patchfile from Fedora 18 RPM.
Changed 12 years ago by lockhart (Thomas Lockhart)
Attachment: | docbook-utils-sgmlinclude.patch added |
---|
Patchfile from Fedora 18 RPM.
Changed 12 years ago by lockhart (Thomas Lockhart)
Attachment: | docbook-utils-spaces.patch added |
---|
Patchfile from Fedora 18 RPM.
Changed 12 years ago by lockhart (Thomas Lockhart)
Attachment: | docbook-utils-w3mtxtconvert.patch added |
---|
Patchfile from Fedora 18 RPM.
Changed 12 years ago by lockhart (Thomas Lockhart)
Attachment: | docbook2man-spec.pl added |
---|
Patchfile from Fedora 18 RPM.
comment:4 Changed 12 years ago by lockhart (Thomas Lockhart)
Added all patch files and an extra "helper program" from the original RPM used as source for this port. Note that there is an extraneous copy of docbook-utils-newgrep.patch (*-2.patch) which I accidentally posted. Just use the original file docbook-utils-newgrep.patch. I am able to generate docbook documentation using this version of the port with all of these patches applied.
comment:5 follow-ups: 7 8 Changed 12 years ago by pgf
Does not work on Snow Leopard (10.6.8), MacPorts 2.1.2 . Install log attached.
Changed 12 years ago by pgf
Attachment: | docbook-utils.log added |
---|
comment:7 Changed 12 years ago by lockhart (Thomas Lockhart)
Replying to piergiuseppe.fogli@…:
Does not work on Snow Leopard (10.6.8), MacPorts 2.1.2 . Install log attached.
I don't have Snow Leopard to test. Do you know if the previous version of docbook-utils worked on Snow Leopard? If so I can just make some of these patches conditional on later releases of Mac OS X which apparently have newer (or different) grep and sed.
comment:8 Changed 12 years ago by pixilla (Bradley Giesbrecht)
Replying to piergiuseppe.fogli@…:
Does not work on Snow Leopard (10.6.8), MacPorts 2.1.2 . Install log attached.
Works here on Snow Leopard:
$ sw_vers -productVersion; xcodebuild -version | head -n1;uname -p; port -q installed docbook-utils 10.6.8 Xcode 3.2.6 i386 docbook-utils @0.6.14_0 docbook-utils @0.6.14_1 (active)
comment:9 follow-up: 10 Changed 12 years ago by pgf
Thank you for your reply!
Finally I succeeded in installing it.
I don't know if previous versions worked, it's a new install not an upgrade.
On a different Mac with identical software environment the install process went OK:
$ sw_vers -productVersion; xcodebuild -version | head -n1;uname -p; port version; port -q installed docbook-utils 10.6.8 Xcode 3.2.6 i386 Version: 2.1.2 docbook-utils @0.6.14_1 (active)
I discovered a difference between the two Mac in the file /opt/local/etc/sgml/catalog:
On the "working" Mac:
-- Created by XML Catalog Manager 2.2 -- CATALOG "/opt/local/share/dsssl/docbook-dsssl/catalog" CATALOG "/opt/local/share/sgml/iso8879/catalog" CATALOG "/opt/local/share/sgml/docbook/4.2/docbook.cat" CATALOG "/opt/local/share/sgml/openjade/catalog"
On the "failing" Mac:
-- Created by XML Catalog Manager 2.2 -- CATALOG "/opt/local/share/xml/docbook/4.2/docbook.cat" CATALOG "/opt/local/share/xml/docbook/4.1.2/docbook.cat" CATALOG "/opt/local/share/xml/docbook/4.3/docbook.cat" CATALOG "/opt/local/share/xml/docbook/4.4/docbook.cat" CATALOG "/opt/local/share/xml/docbook/4.5/docbook.cat" CATALOG "/opt/local/share/dsssl/docbook-dsssl/catalog" CATALOG "/opt/local/share/sgml/iso8879/catalog" CATALOG "/opt/local/share/sgml/docbook/4.2/docbook.cat" CATALOG "/opt/local/share/sgml/openjade/catalog"
When I changed the file on the "failing" Mac to:
-- Created by XML Catalog Manager 2.2 -- CATALOG "/opt/local/share/dsssl/docbook-dsssl/catalog" CATALOG "/opt/local/share/sgml/iso8879/catalog" CATALOG "/opt/local/share/sgml/docbook/4.2/docbook.cat" CATALOG "/opt/local/share/sgml/openjade/catalog" CATALOG "/opt/local/share/xml/docbook/4.2/docbook.cat" CATALOG "/opt/local/share/xml/docbook/4.1.2/docbook.cat" CATALOG "/opt/local/share/xml/docbook/4.3/docbook.cat" CATALOG "/opt/local/share/xml/docbook/4.4/docbook.cat" CATALOG "/opt/local/share/xml/docbook/4.5/docbook.cat"
the install process was successful.
comment:10 Changed 12 years ago by lockhart (Thomas Lockhart)
Replying to piergiuseppe.fogli@…:
Thank you for your reply!
Finally I succeeded in installing it.
...
the install process was successful.
Thanks for the detail on what seemed to have failed. The catalog file has basic content from sgml-common then is incrementally modified by the various other docbook-xml versions. Not sure why it was not complete. Since it worked on the next Snow Leopard machine I'm thinking that whatever the problem was it may not be specific to Snow Leopard and may have been a hiccup on the first one.
comment:11 follow-up: 12 Changed 12 years ago by lockhart (Thomas Lockhart)
The report on Snow Leopard machines indicates that in at least some cases the installation succeeds and is usable. btw the failed installation is due to a failure to have docbook-utils build its own documentation. Maybe there was an ordering problem in which packages were installed first? But for now the problem seems to be not reproducible. Can we push the updates through?
comment:12 Changed 12 years ago by pixilla (Bradley Giesbrecht)
Resolution: | → fixed |
---|---|
Status: | new → closed |
Hmm. I see that the latest RPM has patches for the same issue. Please wait until I can integrate those patches in directly to try to keep as compatible as possible with the upstream sources and packaging.