Print

Print


Hi,
When building version the python modules for version 5.5.5 for openSUSE* on 32-bit systems (i586 specifically), we see builds failing due to multiple violation of the C++ ODR. These are reported thus:

```
[  114s]   [ 99%] Linking CXX shared library /home/abuild/rpmbuild/BUILD/xrootd-5.5.5/build/lib.linux-i686-cpython-39/pyxrootd/libXrdPosixPreload.so
[  114s]   /home/abuild/rpmbuild/BUILD/xrootd-5.5.5/src/./XrdPosix/XrdPosixLinkage.hh:347:7: error: type ‘struct XrdPosixLinkage’ violates the C++ One Definition Rule [-Werror=odr]
[  114s]     347 | class XrdPosixLinkage
[  114s]         |       ^
[  114s]   /home/abuild/rpmbuild/BUILD/xrootd-5.5.5/src/./XrdPosix/XrdPosixLinkage.hh:347:7: note: a different type is defined in another translation unit
[  114s]     347 | class XrdPosixLinkage
[  114s]         |       ^
[  114s]   /home/abuild/rpmbuild/BUILD/xrootd-5.5.5/src/./XrdPosix/XrdPosixLinkage.hh:365:26: note: the first difference of corresponding definitions is field ‘Fseeko’
[  114s]     365 |       Retv_Fseeko      (*Fseeko)(Args_Fseeko);
[  114s]         |                          ^
[  114s]   /home/abuild/rpmbuild/BUILD/xrootd-5.5.5/src/./XrdPosix/XrdPosixLinkage.hh:365:26: note: a field of same name but different type is defined in another translation unit
[  114s]     365 |       Retv_Fseeko      (*Fseeko)(Args_Fseeko);
[  114s]         |                          ^
[  114s]   /home/abuild/rpmbuild/BUILD/xrootd-5.5.5/src/./XrdPosix/XrdPosixLinkage.hh:347:7: note: type mismatch in parameter 2
[  114s]     347 | class XrdPosixLinkage
[  114s]         |       ^
[  114s]   /home/abuild/rpmbuild/BUILD/xrootd-5.5.5/src/XrdPosix/XrdPosixPreload32.cc:76:24: error: ‘Xunix’ violates the C++ One Definition Rule [-Werror=odr]
[  114s]      76 | extern XrdPosixLinkage Xunix;
[  114s]         |                        ^
[  114s]   /home/abuild/rpmbuild/BUILD/xrootd-5.5.5/src/./XrdPosix/XrdPosixLinkage.hh:347:7: note: type ‘struct XrdPosixLinkage’ itself violates the C++ One Definition Rule
[  114s]     347 | class XrdPosixLinkage
[  114s]         |       ^
[  114s]   /home/abuild/rpmbuild/BUILD/xrootd-5.5.5/src/XrdPosix/XrdPosixLinkage.cc:56:17: note: ‘Xunix’ was previously declared here
[  114s]      56 | XrdPosixLinkage Xunix;
[  114s]         |                 ^
[  114s]   lto1: all warnings being treated as errors

```

We see no such problems with 64 bit builds however.

Our build uses the following libraries/compilers:

* cmake 3.26
* GCC 13.1.1
* Python 3.9, 3.10, 3.11

Happy to supply any more information, if needed, to help debug and fix the issue. In the meanwhile, here is the full build log:
[xrootd_i586_build_log.zip](https://github.com/xrootd/xrootd/files/11711758/xrootd_i586_build_log.zip)

Thanks in advance.

* We include commit 2401509 as a patch (lightly rebased to apply against 5.5.5) to get the python modules building. You may have a detailed look at our patches and build status [here](https://build.opensuse.org/package/show/home:badshah400:branches:science/xrootd) temporarily.

-- 
Reply to this email directly or view it on GitHub:
https://github.com/xrootd/xrootd/issues/2032
You are receiving this because you are subscribed to this thread.

Message ID: <[log in to unmask]>
########################################################################
Use REPLY-ALL to reply to list

To unsubscribe from the XROOTD-DEV list, click the following link:
https://listserv.slac.stanford.edu/cgi-bin/wa?SUBED1=XROOTD-DEV&A=1