After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 756519 - `make check' fails - Sequence (?R...) not recognized in regex
`make check' fails - Sequence (?R...) not recognized in regex
Status: RESOLVED FIXED
Product: gtk-doc
Classification: Platform
Component: general
unspecified
Other Windows
: Normal normal
: 1.25
Assigned To: gtk-doc maintainers
gtk-doc maintainers
Depends on:
Blocks:
 
 
Reported: 2015-10-13 17:12 UTC by testuser448
Modified: 2015-10-15 19:50 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description testuser448 2015-10-13 17:12:41 UTC
I am building gtk-doc
(git commit e7b705c7aebc9534a1a9707e815a66a763bc7c3f, 2015-10-05)
on Windows using MinGW/MSYS.

`make check' fails with:
make[3]: Entering directory `/c/gnome/gtk-doc-git-build/tests/empty/d
ocs'
make  check-local
make[4]: Entering directory `/c/gnome/gtk-doc-git-build/tests/empty/d
ocs'
  DOC   Preparing build
  DOC   00:00:00.125000000: Scanning header files
  DOC   00:00:00.562000000: Building XML
Sequence (?R...) not recognized in regex; marked by <-- HERE in m/\[((?:[^][]|(?
R <-- HERE ))*)\]/ at /c/gnome/gtk-doc-git-build/gtkdoc-mkdb line 516
5.
make[4]: *** No rule to make target `tester-docs.xml', needed by `html-build.sta
mp'.  Stop.
make[4]: Leaving directory `/c/gnome/gtk-doc-git-build/tests/empty/do
cs'

What does this mean?
Comment 1 Stefan Sauer (gstreamer, gtkdoc dev) 2015-10-13 20:29:13 UTC
what version of perl are you using? For me it is:
> perl --version

This is perl 5, version 18, subversion 2 (v5.18.2) built for x86_64-linux-gnu-thread-multi
(with 41 registered patches, see perl -V for more detail)
Comment 2 Stefan Sauer (gstreamer, gtkdoc dev) 2015-10-13 20:32:07 UTC
and please double-check that you actually run that git version:

https://git.gnome.org/browse/gtk-doc/tree/gtkdoc-mkdb.in?id=e7b705c7aebc9534a1a9707e815a66a763bc7c3f#n516

The line 516 of gtkdoc-mkdb at this revision is a blank line.
Comment 3 testuser448 2015-10-13 20:39:06 UTC
The line broke at 516 on my screen and I didn't edit it. The line number is actually 5165:

5158     $markup .= substr ($text, 0, $closest_marker_position);
5159     $text = substr ($text, $closest_marker_position);
5160     @markers_rest = map { $markers{$_} ? ($_ eq $closest_marker ? () : $
: () } keys %markers;
5161
5162     if ($closest_marker eq "![" || $closest_marker eq "[") {
5163       my %element;
5164
5165       if (index ($text, "]") && $text =~ /\[((?:[^][]|(?R))*)\]/) {
5166         my $remaining_text;
5167
5168         %element = ( "!" => (substr ($text, 0, 1) eq "!"),
5169                      "a" => $1 );
5170
5171         $offset = length ($&);
5172         if ($element{"!"}) {
5173           $offset++;
5174         }
5175
5176         $remaining_text = substr ($text, $offset);
Comment 4 testuser448 2015-10-13 20:42:09 UTC
(In reply to Stefan Sauer (gstreamer, gtkdoc dev) from comment #2)
> and please double-check that you actually run that git version:
> 

$ perl --version

This is perl, v5.8.8 built for msys-64int
Comment 5 testuser448 2015-10-14 15:40:57 UTC
Can someone show me how to display the value of $text at line 5165? I tried
 printing to STDOUT and STDERR. I tried to write to a file, but the file was not created. I searched the entire build tree (which is now the source tree because I am now seeing that an out-of-tree build cannot work). I don't know perl at all so maybe I made a mistake.
Comment 6 Stefan Sauer (gstreamer, gtkdoc dev) 2015-10-15 11:25:09 UTC
If you do:
print "text: $text\n"
that will print the value to stdout.


Regarding the '?R', here are the docs for it:
http://perldoc.perl.org/perlre.html (search for ?R). An alternative would be to use (?0) if that makes it work for you.
Comment 7 testuser448 2015-10-15 13:43:44 UTC
(In reply to Stefan Sauer (gstreamer, gtkdoc dev) from comment #6)
> If you do:
> print "text: $text\n"
> that will print the value to stdout.
>

I'm sure that I tried that, but it did not work. No text appeared. I ran:
$make check > check.txt 2>&1 &
$tail -F check.txt

and also inspected check.txt at the end.
 
> 
> Regarding the '?R', here are the docs for it:
> http://perldoc.perl.org/perlre.html (search for ?R). An alternative would be
> to use (?0) if that makes it work for you.

?0 does not work either. However, I tried a newer perl (ActiveState):
$ /c/perl/perl/bin/perl --version

This is perl 5, version 20, subversion 2 (v5.20.2) built for MSWin32-x86-multi-t
hread-64int.

All 12 tests now pass, but no PDFs are built. I will open a new bug for that. For this incident, perhaps the configure script's perl version check could be updated. Currently it is:
checking if Perl version >= 5.6.0... yes
but my perl v5.8.8 does not recognise the ?R regular expression in gtkdoc-mkdb.

You can close this bug with whatever status you consider appropriate.
Comment 8 Stefan Sauer (gstreamer, gtkdoc dev) 2015-10-15 19:50:46 UTC
Regarding the logging, in the tests the the logs are already redirected, check the gtkdoc-*.log. When running this normally stdout and stderr work as usual.

Thanks a lot for testing with a newer version of perl. I bumped the required version in commit ea7536e70f783cdd04809d68e04ba07bb754693e.