Opened 14 months ago
Closed 14 months ago
#21885 closed defect (fixed)
subversion-1.14.5 FTBFS with Ruby 3.4.x
| Reported by: | Douglas R. Reno | Owned by: | Douglas R. Reno |
|---|---|---|---|
| Priority: | normal | Milestone: | 12.4 |
| Component: | BOOK | Version: | git |
| Severity: | medium | Keywords: | |
| Cc: |
Description
While trying to build Subversion with Ruby-3.4.5 (needed to clone a repo from Sourceforge for a data recovery program), it fails to build with incompatible pointer type errors.
I was trying to check Subversion's upstream but their ViewVC instance now requires a username and password, and there doesn't seem to be a way to register. I'll look at other distros later and provide a fix if someone else doesn't beat me to it.
The errors are as follows:
In file included from /usr/include/ruby-3.4.0/ruby/internal/assume.h:29,
from /usr/include/ruby-3.4.0/ruby/backward/2/assume.h:24,
from /usr/include/ruby-3.4.0/ruby/defines.h:72,
from /usr/include/ruby-3.4.0/ruby/ruby.h:25:
subversion/bindings/swig/ruby/svn_delta.c: In function ‘SWIG_AsVal_long’:
/usr/include/ruby-3.4.0/ruby/internal/anyargs.h:385:45: error: passing
argument 1 of ‘rb_rescue’ from incompatible pointer type [-
Wincompatible-pointer-types]
and
subversion/bindings/swig/ruby/svn_client.c: In function
‘SWIG_RubyIterateTrackings’:
subversion/bindings/swig/ruby/svn_client.c:1293:35: error: passing
argument 2 of ‘rb_st_foreach’ from incompatible pointer type [-
Wincompatible-pointer-types]
1293 | st_foreach(swig_ruby_trackings, (int (*)
(ANYARGS))&swig_ruby_internal_iterate_callback, (st_data_t)meth);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
| |
| int (*)(void)
As well as dozens of others. I've got a complete build log at https://linuxfromscratch.org/~renodr/subversion-1.14.5-fail.log
I was able to work around it on my system by setting -Wno-incompatible-pointer-types, but that isn't acceptable for the book at all. I only did it in a hurry since I need to do a fast turnaround for an old client of mine.
Change History (5)
comment:1 by , 14 months ago
| Type: | enhancement → defect |
|---|
comment:2 by , 14 months ago
comment:3 by , 14 months ago
| Owner: | changed from to |
|---|
Indeed, adding the sed above immediately before the 'make swig-rb' line allowed the ruby bindings to build but with a LOTS of warnings like '...' is deprecated.
The FTBFS issue is fairly obviously a gcc-15 issue.
In my log, the ruby related build output starts at line 1071 (43%) and ends at line 1631 (66%). The install portion started at line 2217 (90%) and ended at line 2451 (100%)
The packages for the ruby bindings needs a complete rework by upstream, but since so many developers have migrated to git, I'm not sure that there is any interest in that.
The ruby files installed were:
$ ls -lR /usr/lib/ruby/site_ruby/3.4.0 /usr/lib/ruby/site_ruby/3.4.0: total 8 drwxr-xr-x 2 root root 4096 Jul 28 14:52 svn drwxr-xr-x 3 root root 4096 Jul 28 14:52 x86_64-linux /usr/lib/ruby/site_ruby/3.4.0/svn: total 192 -rw-r--r-- 1 root root 28241 Jul 28 14:52 client.rb -rw-r--r-- 1 root root 20386 Jul 28 14:52 commit-mailer.rb -rw-r--r-- 1 root root 21968 Jul 28 14:52 core.rb -rw-r--r-- 1 root root 14599 Jul 28 14:52 delta.rb -rw-r--r-- 1 root root 3104 Jul 28 14:52 error.rb -rw-r--r-- 1 root root 15306 Jul 28 14:52 fs.rb -rw-r--r-- 1 root root 9308 Jul 28 14:52 info.rb -rw-r--r-- 1 root root 11304 Jul 28 14:52 ra.rb -rw-r--r-- 1 root root 15521 Jul 28 14:52 repos.rb -rw-r--r-- 1 root root 5251 Jul 28 14:52 synchronizer.rb -rw-r--r-- 1 root root 5010 Jul 28 14:52 util.rb -rw-r--r-- 1 root root 24794 Jul 28 14:52 wc.rb /usr/lib/ruby/site_ruby/3.4.0/x86_64-linux: total 4 drwxr-xr-x 3 root root 4096 Jul 28 14:52 svn /usr/lib/ruby/site_ruby/3.4.0/x86_64-linux/svn: total 4 drwxr-xr-x 2 root root 4096 Jul 28 14:52 ext /usr/lib/ruby/site_ruby/3.4.0/x86_64-linux/svn/ext: total 10036 -rwxr-xr-x 1 root root 1507 Jul 28 14:52 client.la -rwxr-xr-x 1 root root 1998624 Jul 28 14:52 client.so -rwxr-xr-x 1 root root 1495 Jul 28 14:52 core.la -rwxr-xr-x 1 root root 2484656 Jul 28 14:52 core.so -rwxr-xr-x 1 root root 1501 Jul 28 14:52 delta.la -rwxr-xr-x 1 root root 491576 Jul 28 14:52 delta.so -rwxr-xr-x 1 root root 1495 Jul 28 14:52 diff.la -rwxr-xr-x 1 root root 74160 Jul 28 14:52 diff.so -rwxr-xr-x 1 root root 1483 Jul 28 14:52 fs.la -rwxr-xr-x 1 root root 839904 Jul 28 14:52 fs.so -rwxr-xr-x 1 root root 1483 Jul 28 14:52 ra.la -rwxr-xr-x 1 root root 919064 Jul 28 14:52 ra.so -rwxr-xr-x 1 root root 1501 Jul 28 14:52 repos.la -rwxr-xr-x 1 root root 1116944 Jul 28 14:52 repos.so -rwxr-xr-x 1 root root 1483 Jul 28 14:52 wc.la -rwxr-xr-x 1 root root 2286856 Jul 28 14:52 wc.so
comment:4 by , 14 months ago
| Status: | new → assigned |
|---|
comment:5 by , 14 months ago
| Resolution: | → fixed |
|---|---|
| Status: | assigned → closed |

Replying to Douglas R. Reno:
I checked a couple other distros and they all seem to avoid the issue by not building the Ruby bindings when 3.4.x is installed or doing something similar. I talked with my son who works for Redhat and they also use -Wno-error=incompatible-pointer-types.
If building the Ruby bindings this sed should do it:
and then make swig-rb