Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

perl 5.40.1 and 5.38.3 builds #231

Open
7 of 8 tasks
shawnlaffan opened this issue Jan 17, 2025 · 11 comments
Open
7 of 8 tasks

perl 5.40.1 and 5.38.3 builds #231

shawnlaffan opened this issue Jan 17, 2025 · 11 comments

Comments

@shawnlaffan
Copy link
Contributor

shawnlaffan commented Jan 17, 2025

List of tasks for the upcoming point releases.

Extlibs:

Perl::Dist::Strawberry

@shawnlaffan
Copy link
Contributor Author

shawnlaffan commented Jan 22, 2025

XML::LibXML has issues with recent versions of libxml2: https://rt.cpan.org/Public/Bug/Display.html?id=157693

Update: Worked around by using a slightly older version that is not affected by the CVE.

@shawnlaffan
Copy link
Contributor Author

shawnlaffan commented Jan 23, 2025

PDL::IO::DBI fails some of its tests. PDL is 2.099 (latest on CPAN). It also fails with SP 5.40.0 when PDL is built using current git HEAD.

Passes when built against PDL 2.089.

Disabling for now.

Building and testing PDL-IO-DBI-0.012 ... cp lib/PDL/IO/DBI.pm blib\lib\PDL\IO\DBI.pm
"C:\strawberry\perl\bin\perl.exe" "-MExtUtils::Command::MM" "-MTest::Harness" "-e" "undef *Test::Harness::Switches; test_harness(0, 'blib\lib', 'blib\arch')" t/*.t
t/compile.t ........ ok
t/db-odbc-mssql.t .. skipped: PDL_IO_DBI_ODBC_MSSQL_TEST_DSN not set
t/db-postgresql.t .. skipped: PDL_IO_DBI_PG_TEST_DSN not set
# no PDL::DateTime
t/db-sqlite.t ...... ok
Trying to upd_data but datasv now length 20 instead of 0 at C:\strawberry_build\env\AppDataRoaming\.cpanm\work\1737637280.6864\PDL-IO-DBI-0.012\blib\lib/PDL/IO/DBI.pm line 188.
# Tests were run but no plan was declared and done_testing() was not seen.
# Looks like your test exited with 2 just after 37.
t/reuse_sth.t ......
Dubious, test returned 2 (wstat 512, 0x200)
All 37 subtests passed

Update:
This can be attributed to a recent change in PDL. PDLPorters/pdl@5f6c93b
The fix needs to be in PDL::IO::DBI so will leave it disabled until then.

Update 2: Reported to kmx/pdl-io-dbi#3

@shawnlaffan
Copy link
Contributor Author

@wesQ3
Copy link

wesQ3 commented Jan 24, 2025

Hi, thanks for your work on Strawberry Perl.

Dev build is looking good on my end so far.

@twata1
Copy link

twata1 commented Jan 26, 2025

It seems to me that fail to build Math::Pari again.

Please see http://fast-matrix.cpantesters.org/?dist=Math-Pari%202.030523

@shawnlaffan
Copy link
Contributor Author

shawnlaffan commented Jan 26, 2025

It seems to me that fail to build Math::Pari again.

Please see http://fast-matrix.cpantesters.org/?dist=Math-Pari%202.030523

The same build failures occur with SP 5.40.0.1 so this seems not to be a new problem. I can also reproduce locally with 5.40.0.1. See error below.

In file included from C:\perls\5.40.0.1_PDL\perl\lib\CORE/inline.h:1506,
                 from C:\perls\5.40.0.1_PDL\perl\lib\CORE/perl.h:7866,
                 from Pari.xs:51:
pari-2.3.5/src64/headers/parigen.h:21:14: error: conflicting types for 'llabs'; have 'long int(long int)'
   21 | #define labs llabs
      |              ^~~~~
In file included from C:/perls/5.40.0.1_PDL/c/lib/gcc/x86_64-w64-mingw32/13.2.0/include/mm_malloc.h:27,
                 from C:/perls/5.40.0.1_PDL/c/lib/gcc/x86_64-w64-mingw32/13.2.0/include/xmmintrin.h:34,
                 from C:/perls/5.40.0.1_PDL/c/lib/gcc/x86_64-w64-mingw32/13.2.0/include/immintrin.h:31,
                 from C:/perls/5.40.0.1_PDL/c/lib/gcc/x86_64-w64-mingw32/13.2.0/include/x86intrin.h:32,
                 from C:/perls/5.40.0.1_PDL/c/x86_64-w64-mingw32/include/winnt.h:1658,
                 from C:/perls/5.40.0.1_PDL/c/x86_64-w64-mingw32/include/minwindef.h:163,
                 from C:/perls/5.40.0.1_PDL/c/x86_64-w64-mingw32/include/windef.h:9,
                 from C:/perls/5.40.0.1_PDL/c/x86_64-w64-mingw32/include/windows.h:69,
                 from Pari.xs:3:
C:/perls/5.40.0.1_PDL/c/x86_64-w64-mingw32/include/stdlib.h:735:52: note: previous definition of 'llabs' with type 'long long int(long long int)'
  735 |   __MINGW_EXTENSION __CRT_INLINE long long __cdecl llabs(long long _j) { return (_j >= 0 ? _j : -_j); }
      |                                                    ^~~~~
gmake: *** [makefile:352: Pari.o] Error 1

With SP 5.38.0.1 it gets into an infinite loop reporting patching file src/language/init.c.

@twata1
Copy link

twata1 commented Feb 10, 2025

Possibly Test::Trap test t\08-fork.t will fail.

Sample fail report:
http://www.cpantesters.org/cpan/report/a0017814-6ea8-1014-8029-bfa125993ddc

@shawnlaffan
Copy link
Contributor Author

shawnlaffan commented Feb 10, 2025

Possibly Test::Trap test t\08-fork.t will fail.

Also fails on SP 5.38.3.

This is a pure perl module so building the Makefile with "OPTIMIZE=-Os" has no effect.

Update: It is also failing on all versions of 5.41 on Windows (non-Strawberry) so I wonder if this is core perl related. Are there any backports to 5.40.1 and 5.38.3 that could potentially affect things?
http://matrix.cpantesters.org/?dist=Test-Trap+v0.3.5

@shawnlaffan
Copy link
Contributor Author

The failing test is at https://metacpan.org/release/EBHANSSEN/Test-Trap-v0.3.5/source/t/08-fork.PL#L118

trap {
  trap{
    trap {
      fork;
      exit;
    };
    wait;
    is( $trap->exit, 0, "Trapped the inner exit" );
  }
};

@shawnlaffan
Copy link
Contributor Author

And the failing block of code in Trap.pm has an interesting comment in it.

          if ($$ != $pid) {
            return $outer->(@_) if $outer;
            # XXX: This is fuzzy ... how to test this right?
            CORE::exit(shift);
          }

@shawnlaffan
Copy link
Contributor Author

shawnlaffan commented Feb 11, 2025

(edited to include more of the GDB log)

GDB run and backtrace:

(gdb) run
Starting program: C:\perls\5.40.1.1_PDL_dev\perl\bin\perl.exe -Mblib t\08-fork.t
[New Thread 40644.0x9ca0]
[New Thread 40644.0x56e8]
[New Thread 40644.0x9ba0]
1..15
ok 1 - use Test::Trap;
ok 2 - Trapped the first exit
[New Thread 40644.0x52b4]
ok 3 - The inner CORE::GLOBAL::exit is called from the child
[Thread 40644.0x52b4 exited with code 0]
ok 4 - Trapped the inner exit
ok 5 - Override warning
[New Thread 40644.0x9cbc]
Free to wrong pool 35e50b0 not 127020 at C:\perls\5401~1.1_P\data\.cpanm\work\1739227221.27572\Test-Trap-v0.3.5\blib\lib/Test/Trap.pm line 74.

Thread 6 received signal SIGSEGV, Segmentation fault.
[Switching to Thread 40644.0x9cbc]
0x00007ffbe4e4d6cb in perl540!Perl_drand48_r () from C:\perls\5.40.1.1_PDL_dev\perl\bin\perl540.dll
(gdb) bt
#0  0x00007ffbe4e4d6cb in perl540!Perl_drand48_r () from C:\perls\5.40.1.1_PDL_dev\perl\bin\perl540.dll
#1  0x00007ffbe4e423a8 in perl540!Perl_leave_scope () from C:\perls\5.40.1.1_PDL_dev\perl\bin\perl540.dll
#2  0x00007ffbe4dcd85b in perl540!Perl_dounwind () from C:\perls\5.40.1.1_PDL_dev\perl\bin\perl540.dll
#3  0x00007ffbe4df3994 in perl540!Perl_nothreadhook () from C:\perls\5.40.1.1_PDL_dev\perl\bin\perl540.dll
#4  0x00007ffbe4df7ec9 in perl540!Perl_my_exit () from C:\perls\5.40.1.1_PDL_dev\perl\bin\perl540.dll
#5  0x00007ffbe4dd0307 in perl540!Perl_caller_cx () from C:\perls\5.40.1.1_PDL_dev\perl\bin\perl540.dll
#6  0x00007ffbe4e40762 in perl540!Perl_runops_standard () from C:\perls\5.40.1.1_PDL_dev\perl\bin\perl540.dll
#7  0x00007ffbe4e4f64c in perl540!Perl_drand48_r () from C:\perls\5.40.1.1_PDL_dev\perl\bin\perl540.dll
#8  0x00007ffc8ce3259d in KERNEL32!BaseThreadInitThunk () from C:\WINDOWS\System32\kernel32.dll
#9  0x00007ffc8d1eaf38 in ntdll!RtlUserThreadStart () from C:\WINDOWS\SYSTEM32\ntdll.dll
#10 0x0000000000000000 in ?? ()

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants