Hi, I tried to build rpms/ruby branches below on the mock build rawhide. Then I got the build errors below. It's great if someone will take a look at it or give me advice.
I wanted to rebase Ruby 2.5 from 2.5.8 to 2.5.9 if possible on the ruby-2.5 branch. https://www.ruby-lang.org/en/news/2021/04/05/ruby-2-5-9-released/
* stream-ruby-2.7 * stream-ruby-2.6 * ruby-2.5
## stream-ruby-2.7
gcc -shared -o ../../.ext/x86_64-linux/ripper.so ripper.o -L. -L../.. -L. -Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 -Wl,-dT,/builddir/build/BUILD/ruby-2.7.4/.package_note-ruby-0.3.0-139.fc37.x86_64.ld -fstack-protector-strong -rdynamic -Wl,-export-dynamic -Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 -Wl,-dT,/builddir/build/BUILD/ruby-2.7.4/.package_note-ruby-0.3.0-139.fc37.x86_64.ld -m64 -lruby -lm -lc make[2]: Leaving directory '/builddir/build/BUILD/ruby-2.7.4/ext/ripper' make[1]: Leaving directory '/builddir/build/BUILD/ruby-2.7.4' make: *** [uncommon.mk:296: build-ext] Error 2
## stream-ruby-2.6
./configure: line 4122: syntax error near unexpected token `fi' ./configure: line 4122: `fi'
## ruby-2.5
./configure: line 4101: syntax error near unexpected token `fi' ./configure: line 4101: `fi'
Dne 01. 07. 22 v 17:27 Jun Aruga napsal(a):
Hi, I tried to build rpms/ruby branches below on the mock build rawhide. Then I got the build errors below. It's great if someone will take a look at it or give me advice.
I wanted to rebase Ruby 2.5 from 2.5.8 to 2.5.9 if possible on the ruby-2.5 branch. https://www.ruby-lang.org/en/news/2021/04/05/ruby-2-5-9-released/
- stream-ruby-2.7
- stream-ruby-2.6
- ruby-2.5
## stream-ruby-2.7
gcc -shared -o ../../.ext/x86_64-linux/ripper.so ripper.o -L. -L../.. -L. -Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 -Wl,-dT,/builddir/build/BUILD/ruby-2.7.4/.package_note-ruby-0.3.0-139.fc37.x86_64.ld -fstack-protector-strong -rdynamic -Wl,-export-dynamic -Wl,-z,relro -Wl,--as-needed -Wl,-z,now -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -Wl,--build-id=sha1 -Wl,-dT,/builddir/build/BUILD/ruby-2.7.4/.package_note-ruby-0.3.0-139.fc37.x86_64.ld -m64 -lruby -lm -lc make[2]: Leaving directory '/builddir/build/BUILD/ruby-2.7.4/ext/ripper' make[1]: Leaving directory '/builddir/build/BUILD/ruby-2.7.4' make: *** [uncommon.mk:296: build-ext] Error 2
I don't think you have included the real error in the log. The real error is here:
~~~
In file included from ../.././include/ruby.h:33, from ossl.h:16: ossl_pkey_rsa.c: In function 'Init_ossl_rsa': ossl_pkey_rsa.c:877:58: error: 'RSA_SSLV23_PADDING' undeclared (first use in this function); did you mean 'RSA_NO_PADDING'? 877 | #define DefRSAConst(x) rb_define_const(cRSA, #x, INT2NUM(RSA_##x)) | ^~~~ ../.././include/ruby/ruby.h:262:33: note: in definition of macro 'RB_INT2FIX' 262 | #define RB_INT2FIX(i) (((VALUE)(i))<<1 | RUBY_FIXNUM_FLAG) | ^ ../.././include/ruby/ruby.h:1609:20: note: in expansion of macro 'RB_INT2NUM' 1609 | #define INT2NUM(x) RB_INT2NUM(x) | ^~~~~~~~~~ ossl_pkey_rsa.c:877:50: note: in expansion of macro 'INT2NUM' 877 | #define DefRSAConst(x) rb_define_const(cRSA, #x, INT2NUM(RSA_##x)) | ^~~~~~~ ossl_pkey_rsa.c:942:5: note: in expansion of macro 'DefRSAConst' 942 | DefRSAConst(SSLV23_PADDING); | ^~~~~~~~~~~ ossl_pkey_rsa.c:877:58: note: each undeclared identifier is reported only once for each function it appears in 877 | #define DefRSAConst(x) rb_define_const(cRSA, #x, INT2NUM(RSA_##x)) | ^~~~ ../.././include/ruby/ruby.h:262:33: note: in definition of macro 'RB_INT2FIX' 262 | #define RB_INT2FIX(i) (((VALUE)(i))<<1 | RUBY_FIXNUM_FLAG) | ^ ../.././include/ruby/ruby.h:1609:20: note: in expansion of macro 'RB_INT2NUM' 1609 | #define INT2NUM(x) RB_INT2NUM(x) | ^~~~~~~~~~ ossl_pkey_rsa.c:877:50: note: in expansion of macro 'INT2NUM' 877 | #define DefRSAConst(x) rb_define_const(cRSA, #x, INT2NUM(RSA_##x)) | ^~~~~~~ ossl_pkey_rsa.c:942:5: note: in expansion of macro 'DefRSAConst' 942 | DefRSAConst(SSLV23_PADDING); | ^~~~~~~~~~~ compiling basicsocket.c gcc -I. -I../../.ext/include/x86_64-linux -I../.././include -I../.././ext/socket -I../.. -I../../. -DRUBY_EXTCONF_H="extconf.h" -fPIC -O2 -fexceptions -g -grecord-gcc-switches -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -fstack-protector-strong -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -fcf-protection -fPIC -m64 -o basicsocket.o -c basicsocket.c make[2]: *** [Makefile:313: ossl_pkey_rsa.o] Error 1 make[2]: *** Waiting for unfinished jobs....
~~~
IOW this is OpenSSL 3.x issue. There is no simple way around unless you want
1) Backport the OpenSSL 3.x patches from Ruby 3.0
2) Use some other workaround such as including upstream version of OpenSSL gem.
I'd suggest against building Ruby 3.0 on F36+
## stream-ruby-2.6
./configure: line 4122: syntax error near unexpected token `fi' ./configure: line 4122: `fi'
## ruby-2.5
./configure: line 4101: syntax error near unexpected token `fi' ./configure: line 4101: `fi'
My guess would be some autotools compatibility or some wrongly applied patch? I know that at times, we need to change the autotools version. But this was typically done just in RHEL AFAIR.
Vít
On Wed, Jul 20, 2022 at 4:04 PM Vít Ondruch vondruch@redhat.com wrote: <snip>
IOW this is OpenSSL 3.x issue. There is no simple way around unless you want
Backport the OpenSSL 3.x patches from Ruby 3.0
Use some other workaround such as including upstream version of
OpenSSL gem.
I'd suggest against building Ruby 3.0 on F36+
Oh thanks. I missed the part. How about using openssl1.1-devel instead of openssl-devel in only Ruby 2.7 (stream-ruby-2.7), 2.6 (stream-ruby-2.6) and 2.5 (ruby-2.5)? I don't see any problems in this way.
The openssl1.1 RPM is available on F34~F37(rawhide). https://src.fedoraproject.org/rpms/openssl1.1 https://koji.fedoraproject.org/koji/packageinfo?packageID=32363
## stream-ruby-2.6
./configure: line 4122: syntax error near unexpected token `fi' ./configure: line 4122: `fi'
## ruby-2.5
./configure: line 4101: syntax error near unexpected token `fi' ./configure: line 4101: `fi'
My guess would be some autotools compatibility or some wrongly applied patch? I know that at times, we need to change the autotools version. But this was typically done just in RHEL AFAIR.
Hmm, I didn't find any patch on RHEL. I may check more about this issue when I have time.
Dne 21. 07. 22 v 16:37 Jun Aruga (he / him) napsal(a):
On Wed, Jul 20, 2022 at 4:04 PM Vít Ondruch vondruch@redhat.com wrote:
<snip> > IOW this is OpenSSL 3.x issue. There is no simple way around unless you want > > 1) Backport the OpenSSL 3.x patches from Ruby 3.0 > > 2) Use some other workaround such as including upstream version of > OpenSSL gem. > > I'd suggest against building Ruby 3.0 on F36+ Oh thanks. I missed the part. How about using openssl1.1-devel
Is it really available? I know there were some discussions in the context of old Python support, but I was under impression that while openssl1.1 is available, the -devel packages is not.
So for modules, it could be actually an option.
Vít
I'd suggest against building Ruby 3.0 on F36+
Oh thanks. I missed the part. How about using openssl1.1-devel
Is it really available? I know there were some discussions in the context of old Python support, but I was under impression that while openssl1.1 is available, the -devel packages is not.
So for modules, it could be actually an option.
Not sure about it. We need to ask the maintainer maybe at devel@.
Dne 26. 07. 22 v 21:36 Jun Aruga (he / him) napsal(a):
I'd suggest against building Ruby 3.0 on F36+
Oh thanks. I missed the part. How about using openssl1.1-devel
Is it really available? I know there were some discussions in the context of old Python support, but I was under impression that while openssl1.1 is available, the -devel packages is not.
So for modules, it could be actually an option.
Not sure about it. We need to ask the maintainer maybe at devel@.
Or test it? :)
Vít
On Wed, Jul 27, 2022 at 4:08 PM Vít Ondruch vondruch@redhat.com wrote:
Dne 26. 07. 22 v 21:36 Jun Aruga (he / him) napsal(a):
I'd suggest against building Ruby 3.0 on F36+
Oh thanks. I missed the part. How about using openssl1.1-devel
Is it really available? I know there were some discussions in the context of old Python support, but I was under impression that while openssl1.1 is available, the -devel packages is not.
So for modules, it could be actually an option.
Not sure about it. We need to ask the maintainer maybe at devel@.
Or test it? :)
I am testing it now on the stream-ruby-2.7 branch. https://src.fedoraproject.org/rpms/ruby/pull-request/128
The openssl1.1-devel is used from several RPMs including python3.7 and python3.6 RPMs. A core dump in the tests. Let me know if you know the issue and how to fix. https://kojipkgs.fedoraproject.org//work/tasks/8548/90868548/build.log
ruby-sig@lists.fedoraproject.org