Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 904370 - dev-ruby/rdoc-6.5.0: fails to compile (/usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/grammar.rb:123:in `initialize': [1minvalid character property name {Zl}: /\\n|\\r\\n?|\\p{Zl}|\\p{Zp}/ (RegexpError)
Summary: dev-ruby/rdoc-6.5.0: fails to compile (/usr/lib64/ruby/gems/3.0.0/gems/kpeg-1...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal
Assignee: Gentoo Ruby Team
URL:
Whiteboard:
Keywords: PATCH
: 905261 (view as bug list)
Depends on:
Blocks:
 
Reported: 2023-04-15 13:22 UTC by raphael.senghaas
Modified: 2024-04-10 00:39 UTC (History)
4 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
emerge --info '=dev-ruby/rdoc-6.5.0::gentoo (info.txt,7.42 KB, text/plain)
2023-04-15 13:22 UTC, raphael.senghaas
Details
Build log of 'emerge -av rdoc' (build.log,6.37 KB, text/plain)
2023-04-15 13:23 UTC, raphael.senghaas
Details
build log with patches applied (build.log,6.45 KB, text/x-log)
2023-04-16 10:15 UTC, raffaele
Details
rdoc-6.4.0-kpeg-env.patch (rdoc-6.4.0-kpeg-env.patch,368 bytes, patch)
2023-05-21 07:13 UTC, Andrey Volkov
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description raphael.senghaas 2023-04-15 13:22:00 UTC
Created attachment 860156 [details]
emerge --info '=dev-ruby/rdoc-6.5.0::gentoo

The package dev-ruby/rdoc-6.5.0 keeps failing during compile phase.
Comment 1 raphael.senghaas 2023-04-15 13:23:53 UTC
Created attachment 860157 [details]
Build log of 'emerge -av rdoc'
Comment 2 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-04-16 06:10:03 UTC
>>> Compiling source in /var/tmp/portage/dev-ruby/rdoc-6.5.0/work ...
 [32m*[0m Running compile phase for ruby30
Generating lib/rdoc/rd/block_parser.rb...
/usr/bin/ruby30 /usr/lib64/ruby/gems/3.0.0/gems/racc-1.6.2/bin/racc -l -o lib/rdoc/rd/block_parser.rb lib/rdoc/rd/block_parser.ry
Generating lib/rdoc/rd/inline_parser.rb...
/usr/bin/ruby30 /usr/lib64/ruby/gems/3.0.0/gems/racc-1.6.2/bin/racc -l -o lib/rdoc/rd/inline_parser.rb lib/rdoc/rd/inline_parser.ry
Generating lib/rdoc/markdown.rb...
/usr/bin/ruby30 /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/bin/kpeg -fsv -o lib/rdoc/markdown.rb lib/rdoc/markdown.kpeg
Wrote RDoc::Markdown to lib/rdoc/markdown.rb
Generating lib/rdoc/markdown/literals.rb...
/usr/bin/ruby30 /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/bin/kpeg -fsv -o lib/rdoc/markdown/literals.rb lib/rdoc/markdown/literals.kpeg
/usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/grammar.rb:123:in `initialize': [1minvalid character property name {Zl}: /\\n|\\r\\n?|\\p{Zl}|\\p{Zp}/ ([1;4mRegexpError[m[1m)[m
	from /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/grammar.rb:123:in `new'
	from /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/grammar.rb:123:in `initialize'
	from /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/grammar.rb:754:in `new'
	from /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/grammar.rb:754:in `reg'
	from /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/format_parser.rb:1286:in `_regexp'
	from /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/format_parser.rb:330:in `apply'
	from /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/format_parser.rb:2211:in `_value'
	from /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/format_parser.rb:330:in `apply'
	from /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/format_parser.rb:2301:in `_values'
	from /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/format_parser.rb:330:in `apply'
	from /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/format_parser.rb:2384:in `_expression'
	from /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/format_parser.rb:330:in `apply'
	from /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/format_parser.rb:2606:in `_statement'
	from /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/format_parser.rb:330:in `apply'
	from /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/format_parser.rb:2868:in `_statements'
	from /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/format_parser.rb:330:in `apply'
	from /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/format_parser.rb:2882:in `_statements'
	from /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/format_parser.rb:330:in `apply'
	from /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/format_parser.rb:2882:in `_statements'
	from /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/format_parser.rb:330:in `apply'
	from /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/format_parser.rb:2882:in `_statements'
	from /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/format_parser.rb:330:in `apply'
	from /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/format_parser.rb:2882:in `_statements'
	from /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/format_parser.rb:330:in `apply'
	from /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/format_parser.rb:2882:in `_statements'
	from /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/format_parser.rb:330:in `apply'
	from /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/format_parser.rb:2918:in `_root'
	from /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/format_parser.rb:330:in `apply'
	from /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/lib/kpeg/format_parser.rb:232:in `parse'
	from /usr/lib64/ruby/gems/3.0.0/gems/kpeg-1.3.3/bin/kpeg:63:in `<main>'
rake aborted!
Command failed with status (1): [/usr/bin/ruby30 /usr/lib64/ruby/gems/3.0.0...]
/var/tmp/portage/dev-ruby/rdoc-6.5.0/work/ruby30/rdoc-6.5.0/Rakefile:83:in `block (2 levels) in <top (required)>'
Tasks: TOP => generate => lib/rdoc/markdown/literals.rb
(See full trace by running task with --trace)
 [31;01m*[0m ERROR: dev-ruby/rdoc-6.5.0::gentoo failed (compile phase):
 [31;01m*[0m   (no error message)
Comment 3 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-04-16 06:13:17 UTC
Possibly relevant commits:
- https://github.com/ruby/rdoc/commit/8c03c23311623554aa5dfc3de29067099f976bd2
- https://github.com/ruby/rdoc/commit/987c609df97e90687c1e439f19e7100651efef77

If you apply both of those (go to the URL, then append .patch to it, save in /etc/portage/patches/dev-ruby/rdoc with a .patch filename), does it help at all?
Comment 4 raffaele 2023-04-16 10:15:51 UTC
Created attachment 860181 [details]
build log with patches applied

Unfortunately applying the patches does not solve
Comment 5 Optional 2023-04-19 17:27:27 UTC
I had the same issue. Fixed it with:

> export LANG=C
> sudo emerge ...
Comment 6 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-04-29 06:30:41 UTC
*** Bug 905261 has been marked as a duplicate of this bug. ***
Comment 7 Sam James archtester Gentoo Infrastructure gentoo-dev Security 2023-05-21 05:26:14 UTC
Locale list:
- bad: OP had LANG="en_US"
- bad: Reporter on #gentoo today had LANG="en_US.iso88591"
- good: LANG=C
- good? *.UTF-8?
Comment 8 Andrey Volkov 2023-05-21 07:13:07 UTC
Created attachment 862074 [details, diff]
rdoc-6.4.0-kpeg-env.patch

This patch works for me
Comment 9 Hans de Graaff gentoo-dev Security 2023-06-12 20:42:59 UTC
It looks like we can more easily fix this in the ebuild, rather than needing to patch. The patch also does not use the correct ruby version, so we can side-step that as well.

Thanks everyone for correlating data and figuring out why this is failing.
Comment 10 Larry the Git Cow gentoo-dev 2023-06-12 20:44:26 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=50c47cdb0464a2800b7ba1d933aa21670078a0f8

commit 50c47cdb0464a2800b7ba1d933aa21670078a0f8
Author:     Hans de Graaff <graaff@gentoo.org>
AuthorDate: 2023-06-12 20:43:16 +0000
Commit:     Hans de Graaff <graaff@gentoo.org>
CommitDate: 2023-06-12 20:44:22 +0000

    dev-ruby/rdoc: provide working LANG to fix compilation issues
    
    Closes: https://bugs.gentoo.org/904370
    Signed-off-by: Hans de Graaff <graaff@gentoo.org>

 dev-ruby/rdoc/rdoc-6.5.0.ebuild | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)