[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#928344: qtchooser: Please build with -D_FILE_OFFSET_BITS=64



Source: qtchooser
Version: 66-1
Severity: important
User: debian-68k@lists.debian.org
Usertags: m68k

Hello!

A change recently introduced to glibc with version 2.28 [1] has broken
some applications running in qemu-user when emulating 32-bit architectures
on 64-bit platforms [2].

As a result, any 32-bit application compiled without -D_FILE_OFFSET_BITS=64
will behave erratically when running on qemu-user on a 64-bit platform,
one affected package was dash [3] which has already been fixed although the
problem didn't show there in the context of qemu.

qtchooser suffers from this problem as well and the sympton is that running
qmake, for example, results in qtchooser unable to find the Qt5 installation:

(sid-sh4-sbuild)root@epyc:/# QT_SELECT=5 qmake
qmake: could not find a Qt installation of '5'
(sid-sh4-sbuild)root@epyc:/#

Luckily, there is a simply workaround which is adding the following to debian/
rules which results in qtchooser being built with -D_FILE_OFFSET_BITS=64:

export DEB_CXXFLAGS_MAINT_APPEND := -D_FILE_OFFSET_BITS=64

A locally built version of the package with the fix applied works correctly
again:

(sid-sh4-sbuild)root@epyc:/# dpkg -i qtchooser_66-1+qemu_sh4.deb        
(Reading database ... 45935 files and directories currently installed.)
Preparing to unpack qtchooser_66-1+qemu_sh4.deb ...
Unpacking qtchooser (66-1+qemu) over (66-1) ...
Setting up qtchooser (66-1+qemu) ...
Processing triggers for man-db (2.8.5-2) ...
(sid-sh4-sbuild)root@epyc:/# QT_SELECT=5 qmake
Usage: /usr/lib/qt5/bin/qmake [mode] [options] [files]
(...)
  -nocache       Don't use a cache file      [makefile mode only]
  -nodepend      Don't generate dependencies [makefile mode only]
  -nomoc         Don't generate moc targets  [makefile mode only]
  -nopwd         Don't look for files in pwd [project mode only]
(sid-sh4-sbuild)root@epyc:/#

I would highly recommend to include this fix and even try to get it included
for Buster as otherwise anyone running Qt-related tools inside qemu-user
for 32-bit applications on 64-bit targets on Buster will run into this bug
(e.g., people running an armel chroot on x86_64).

Adrian

> [1] https://sourceware.org/git/?p=glibc.git;a=commit;h=298d0e3129c0b5137f4989275b13fe30d0733c4d
> [2] https://sourceware.org/bugzilla/show_bug.cgi?id=23960
> [3] https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=916255

--
 .''`.  John Paul Adrian Glaubitz
: :' :  Debian Developer - glaubitz@debian.org
`. `'   Freie Universitaet Berlin - glaubitz@physik.fu-berlin.de
  `-    GPG: 62FF 8A75 84E0 2956 9546  0006 7426 3B37 F5B5 F913


Reply to: