On Fri, Dec 27 2019, Jeremy Evans <jer...@openbsd.org> wrote:
> On 12/27 12:58, Jeremy Evans wrote:
>> On 12/26 11:38, George Koehler wrote:
>> > On Thu, 26 Dec 2019 21:58:36 +0100
>> > Jeremie Courreges-Anglas <j...@wxcvbn.org> wrote:
>> > 
>> > > On Wed, Dec 25 2019, Jeremy Evans <jer...@openbsd.org> wrote:
>> > > > Tested on amd64, for about 9 months starting with the first preview
>> > > > release. OK to import?
>> > > 
>> > > This fails on sparc64, log attached.  It *seems* that the configure
>> > > tests are picky because of APIWARN and libgmp.  And indeed the build
>> > > fails similarly on amd64 with USE_LLD=No (only ld.bfd warns about unsafe
>> > > functions, ld.lld does not).
>> > 
>> > I built ruby-2.7.0 on macppc/powerpc with the diff below.
>> > 
>> > The ld.bfd warning from libgmp broke the configure test for __func__, so
>> > RUBY_FUNCTION_NAME_STRING went missing.  This test might have been
>> > broken for a long time, but RUBY_FUNCTION_NAME_STRING was optional until
>> > Nov 17 [1], so it didn't break the build before 2.7.0.  Some other tests
>> > in my config.log get the same warning from libgmp, but seem to ignore
>> > the warning.  For upstream Ruby, I suggest to check if __func__ can
>> > become an allowed C99 feature [2].  If so, Ruby can remove this
>> > configure test and always use __func__.
>> > 
>> > I got another error where coroutine/copy/Context.h included <alloca.h>,
>> > so I deleted the include.  OpenBSD (except amd64, i386) is the only
>> > system where Ruby enables --with-coroutine=copy by default, so this code
>> > is mostly for OpenBSD, but didn't work on OpenBSD, because we have no
>> > <alloca.h>!  I don't check HAVE_ALLOCA_H because the coroutine code
>> > doesn't include the Ruby header for HAVE_ALLOCA_H.
>> > 
>> > I have not reported these bugs to https://bugs.ruby-lang.org/ but might
>> > report them tomorrow.  --George
>> 
>> Thank you very much to both Jeremie for the report and George for the
>> analysis and patch.  Jeremie, does the diff below work for sparc64?  If
>> so, is it OK to import?

The diff did fix the build and packaging.  make test fails, though:

--8<--
[...]
exec ./miniruby -I./lib -I. -I.ext/common  ./tool/runruby.rb --extout=.ext  -- 
--disable-gems "./bootstraptest/runner.rb" --ruby="ruby27 -I./lib 
--disable-gems" -q
test_attr.rb             ..
test_autoload.rb         ........
test_block.rb            
..........................................................
test_class.rb            ................................................
test_env.rb              ..
test_eval.rb             .....................................
test_exception.rb        ..................................
test_fiber.rb            [BUG] Bus Error at 0x0000007f196a6a38
ruby 2.7.0p0 (2019-12-25 revision 647ee6f091) [sparc64-openbsd]

-- Control frame information -----------------------------------------------
c:0001 p:---- s:0003 e:000002 (none) [FINISH]


-- Other runtime information -----------------------------------------------

* Loaded script: bootstraptest.tmp.rb

* Loaded features:

    0 enumerator.so
    1 thread.rb
    2 rational.so
    3 complex.so
    4 ruby2_keywords.rb
    5 /usr/ports/pobj/ruby-2.7.0/ruby-2.7.0/.ext/sparc64-openbsd/enc/encdb.so
    6 
/usr/ports/pobj/ruby-2.7.0/ruby-2.7.0/.ext/sparc64-openbsd/enc/trans/transdb.so

./bootstraptest/runner.rb:456:in `get_result_string': core dumped 
(CoreDumpError)
        from ./bootstraptest/runner.rb:267:in `show_limit'
        from 
/usr/ports/pobj/ruby-2.7.0/ruby-2.7.0/bootstraptest/test_fiber.rb:1:in `<top 
(required)>'
        from ./bootstraptest/runner.rb:196:in `load'
        from ./bootstraptest/runner.rb:196:in `block in exec_test'
        from ./bootstraptest/runner.rb:188:in `each'
        from ./bootstraptest/runner.rb:188:in `exec_test'
        from ./bootstraptest/runner.rb:169:in `block in main'
        from ./bootstraptest/runner.rb:509:in `block (2 levels) in 
in_temporary_working_directory'
        from ./bootstraptest/runner.rb:508:in `chdir'
        from ./bootstraptest/runner.rb:508:in `block in 
in_temporary_working_directory'
        from /usr/ports/pobj/ruby-2.7.0/ruby-2.7.0/lib/tmpdir.rb:89:in 
`mktmpdir'
        from ./bootstraptest/runner.rb:507:in `in_temporary_working_directory'
        from ./bootstraptest/runner.rb:168:in `main'
        from ./bootstraptest/runner.rb:530:in `<main>'
*** Error 1 in /usr/ports/pobj/ruby-2.7.0/ruby-2.7.0 (Makefile:1439 
'yes-btest-ruby')
*** Error 1 in . (Makefile:43 'do-test')
*** Error 1 in . (/usr/ports/infrastructure/mk/bsd.port.mk:2919 
'/usr/ports/pobj/ruby-2.7.0/.test_done')
*** Error 1 in /usr/ports/lang/ruby/2.7 
(/usr/ports/infrastructure/mk/bsd.port.mk:2556 'test')
-->8--

I removed test_fiber.rb and am now running the tests again, trying to
sort out why I'm hitting resource exhaustion...

-- 
jca | PGP : 0x1524E7EE / 5135 92C1 AD36 5293 2BDF  DDCC 0DFA 74AE 1524 E7EE

Reply via email to