Guys,
I have finally gotten a few minutes to dive back into Trinity. To my chagrin, we have Arch has bumped from gcc 4.5 to gcc 4.6. I am having problems building Qt3. Adding to the difficulty, the Qt3 build script for Arch has been through a number of changes lately and I haven't had time to verify the new build script under gcc 4.5 before the jump to gcc 4.6. So I am working to understand whether this build failure is gcc related or if it is a normal screw-up on my end.
The build is failing in the middle of the build, so this leads me to think this might be gcc related. If anybody can look at the error and determine whether this is a gcc issue or not, I would greatly appreciate it. I think what I'll do is drop back to a build script that I know was working on gcc 4.5 and confirm, but in the interim, I thought I would post the error in hope somebody else had seen this already. What does this error look like to the masters?:
g++ -c -pipe -Wall -W -march=i686 -mtune=generic -O2 -pipe -D_REENTRANT -fPIC -DQT_SHARED -DQT_NO_DEBUG -DQT_THREAD_SUPPORT -DQT_THREAD_SUPPORT -D_LARGEFILE_SOURCE -D_LARGE_FILES -D_FILE_OFFSET_BITS=64 -DQT_NO_IMAGEIO_MNG -DQT_NO_IMAGEIO_JPEG -DQT_NO_IMAGEIO_PNG -DQT_BUILTIN_GIF_READER=1 -DQT_NO_STYLE_MAC -DQT_NO_STYLE_AQUA -DQT_NO_STYLE_INTERLACE -DQT_NO_STYLE_WINDOWSXP -DQT_NO_STYLE_COMPACT -DQT_NO_STYLE_POCKETPC -I/home/david/tblds/trinity-qt3/src/qt-x11-free-3.3.8b/mkspecs/linux-g++ -I. -I/usr/include/freetype2 -I3rdparty/opentype -I../include -I/usr/X11R6/include -I/usr/X11R6/include -I.moc/release-shared-mt/ -o .obj/release-shared-mt/qapplication_x11.o kernel/qapplication_x11.cpp In file included from ../include/qmap.h:49:0, from kernel/qmime.h:46, from kernel/qevent.h:48, from kernel/qobject.h:48, from kernel/qwidget.h:46, from kernel/qdesktopwidget.h:43, from kernel/qapplication.h:45, from kernel/qapplication_x11.cpp:67: ../include/qvaluelist.h:91:13: error: ‘ptrdiff_t’ does not name a type ../include/qvaluelist.h:167:13: error: ‘ptrdiff_t’ does not name a type In file included from ../include/qmap.h:49:0, from kernel/qmime.h:46, from kernel/qevent.h:48, from kernel/qobject.h:48, from kernel/qwidget.h:46, from kernel/qdesktopwidget.h:43, from kernel/qapplication.h:45, from kernel/qapplication_x11.cpp:67: ../include/qvaluelist.h:427:13: error: ‘ptrdiff_t’ does not name a type In file included from kernel/qmime.h:46:0, from kernel/qevent.h:48, from kernel/qobject.h:48, from kernel/qwidget.h:46, from kernel/qdesktopwidget.h:43, from kernel/qapplication.h:45, from kernel/qapplication_x11.cpp:67: ../include/qmap.h:110:13: error: ‘ptrdiff_t’ does not name a type ../include/qmap.h:226:13: error: ‘ptrdiff_t’ does not name a type In file included from kernel/qmime.h:46:0, from kernel/qevent.h:48, from kernel/qobject.h:48, from kernel/qwidget.h:46, from kernel/qdesktopwidget.h:43, from kernel/qapplication.h:45, from kernel/qapplication_x11.cpp:67: ../include/qmap.h:607:13: error: ‘ptrdiff_t’ does not name a type kernel/qapplication_x11.cpp: In member function ‘int QApplication::x11ProcessEvent(XEvent*)’: kernel/qapplication_x11.cpp:3693:54: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses] kernel/qapplication_x11.cpp:3706:54: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses] kernel/qapplication_x11.cpp: In member function ‘bool QETWidget::translateMouseEvent(const XEvent*)’: kernel/qapplication_x11.cpp:4122:30: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses] kernel/qapplication_x11.cpp: In member function ‘bool QETWidget::translateKeyEventInternal(const XEvent*, int&, QString&, int&, char&, int&, QEvent::Type&, bool)’: kernel/qapplication_x11.cpp:5161:8: warning: suggest explicit braces to avoid ambiguous ‘else’ [-Wparentheses] kernel/qapplication_x11.cpp:5232:52: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses] kernel/qapplication_x11.cpp:5235:52: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses] kernel/qapplication_x11.cpp: In function ‘int isPaintOrScrollDoneEvent(Display*, XEvent*, XPointer)’: kernel/qapplication_x11.cpp:5524:34: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses] make[2]: *** [.obj/release-shared-mt/qapplication_x11.o] Error 1 make[2]: Leaving directory `/home/david/tblds/trinity-qt3/src/qt-x11-free-3.3.8b/src' make[1]: *** [sub-src] Error 2 make[1]: Leaving directory `/home/david/tblds/trinity-qt3/src/qt-x11-free-3.3.8b' make: *** [init] Error 2 ==> ERROR: A failure occurred in build(). Aborting...
I'll go try an older build script that used qt-x11-free-3.3.8 instead of qt-x11-free-3.3.8b. I'll report back :p
On Sunday 01 May 2011 01:57:41 David C. Rankin wrote:
I have finally gotten a few minutes to dive back into Trinity. To my chagrin, we have Arch has bumped from gcc 4.5 to gcc 4.6. I am having problems building Qt3. Adding to the difficulty, the Qt3 build script for Arch has been through a number of changes lately and I haven't had time to verify the new build script under gcc 4.5 before the jump to gcc 4.6. So I am working to understand whether this build failure is gcc related or if it is a normal screw-up on my end.
See if this can help: https://api.opensuse.org/public/source/KDE:KDE3/qt3/gcc46.diff
On 04/30/2011 06:15 PM, Ilya Chernykh wrote:
On Sunday 01 May 2011 01:57:41 David C. Rankin wrote:
I have finally gotten a few minutes to dive back into Trinity. To my
chagrin, we have Arch has bumped from gcc 4.5 to gcc 4.6. I am having problems building Qt3. Adding to the difficulty, the Qt3 build script for Arch has been through a number of changes lately and I haven't had time to verify the new build script under gcc 4.5 before the jump to gcc 4.6. So I am working to understand whether this build failure is gcc related or if it is a normal screw-up on my end.
See if this can help: https://api.opensuse.org/public/source/KDE:KDE3/qt3/gcc46.diff
Hah!
It did -- Qt3 is building as we speak. Here is the PKGBUILD I'm using (including the gcc46.diff). Baho, I don't know why the 'make subtools' works without the patch, but I guess the parts that need #include <cstddef> aren't triggered by that make. Here is what I have so far. I'll report back after I have finished the build and tested it. Then I can catch up on all the changes in the Trinity packages and what else I can build now :P
# $Id$ # Maintainer: David C. Rankin drankinatty@gmail.com # # All modifications and uses of this file are licensed under # the software for which this file was made for, should the software # be under an Open Source License, at least version 1.9, defined # by the Open Source Initiative. In other cases, this file is automatically # released to the Public Domain. #
pkgname=trinity-qt3 pkgver=3.3.8b pkgrel=1 pkgdesc="The Qt3 gui toolkit - with Trinity patch." _prefix="/opt/qt" _patchver=3.3.8c arch=(i686 x86_64) license=('GPL') url="http://www.trolltech.com/products/qt/index.html" pkgfqn=qt-x11-free-${pkgver} # install=qt.install groups=('trinity-bld') depends=('libjpeg-turbo' 'libmng' 'libmysqlclient' 'libpng' 'libxmu' 'libxcursor' 'libxinerama' 'libxft' 'libxrandr' 'mesa' 'postgresql-libs' 'unixodbc') makedepends=('cups' 'libxi' 'mysql' 'postgresql' 'unixodbc' 'sqlite3') optdepends=() # optdepends=('libmysqlclient' 'postgresql-libs' 'unixodbc') provides=('trinity-qt3' 'qt3') conflicts=('qt3' 'qt3-enhanced') replaces=('trinity-qt3') # 'ftp://ftp.trolltech.com/qt/source/${pkgfqn}.tar.gz' # ftp://ftp.trolltech.com/qt/source/qt-x11-free-3.3.8b.tar.gz source=(ftp://ftp.trolltech.com/qt/source/${pkgfqn}.tar.gz qt3-png14.patch qt-patches.tar.bz2 qt3-png14.patch eastern_asian_languagues.diff qt-odbc.patch gcc46.diff qt3_3.3.8c.arch.diff) options=(!libtool) md5sums=('9f05b4125cfe477cc52c9742c3c09009' '1dc671df42b9030dbdf68bb61cd3375e' '2f00e5c0c1e2c2a23dddc982cd79f3e0' '1dc671df42b9030dbdf68bb61cd3375e' '616f1f3029cf8375256ad6a406de3549' '2178ca88dfd75a230918593b30eb0dbe' 'e77192301879b05a4b8ebc35d5c5702b' 'd763bdc087786a45e5e5eec84f5c9896')
# qt-copy-kde-patches come from http://websvn.kde.org/trunk/qt-copy/patches/ # other qt-patches come from fedora and gentoo
build() { unset QMAKESPEC export QTDIR=${srcdir}/$pkgfqn export PATH=${QTDIR}/bin:${PATH} export LD_LIBRARY_PATH=${QTDIR}/lib:${LD_LIBRARY_PATH} export QMAKESPEC=$QTDIR/mkspecs/linux-g++ export CPATH=/usr/include/postgresql/server:/usr/include/mysql
cd ${QTDIR} # cd ${srcdir}/$pkgfqn
# apply other qt patches and one security fix from debian/gentoo for i in ../qt-patches/*; do patch -Np1 -i $i || return 1 done # fix CJK font/chars select error (FS#11245) patch -p1 -i ${srcdir}/eastern_asian_languagues.diff || return 1 # fix build problem against new unixODBC patch -p1 -i ${srcdir}/qt-odbc.patch || return 1 patch -p0 -i ${srcdir}/qt3-png14.patch || return 1
# patch for gcc 4.6 patch -p0 -i ${srcdir}/gcc46.diff || return 1
# patch for qt3_3.3.8c patch -p0 -i ${srcdir}/qt3_3.3.8c.arch.diff || return 1
# start compiling qt # baho additions # # remove runtime library search not needed when installed into /usr # sed -i '/QMAKE_RPATH/d' mkspecs/linux*/qmake.conf sed -i 's|-cp -P -f|-cp -L -f|' qmake/Makefile.unix rm -rf doc/html examples tutorial sed -i "s|sub-tutorial sub-examples||" Makefile sed -i "s|-O2|$CXXFLAGS|" mkspecs/linux-g++/qmake.conf sed -i "s|-O2|$CXXFLAGS|" mkspecs/linux-g++-32/qmake.conf sed -i "s|-O2|$CXXFLAGS|" mkspecs/linux-g++-64/qmake.conf sed -i "s|-I. |$CXXFLAGS -I. |" qmake/Makefile.unix sed -i "s|read acceptance|acceptance=yes|" configure
# remove unwanted mkspecs rm -rf mkspecs/{*aix*,*bsd*,cygwin*,dgux*,darwin*,hpux*,hurd*,irix*,lynxos*,macx*,qnx*,reliant*,sco*,solaris*,tru64*,unixware*,win32*}
# set arch if x86_64 build if [ "$CARCH" = "x86_64" ]; then export ARCH="-64" else unset ARCH fi
# ./configure -prefix /opt/qt -platform linux-g++$ARCH \ # -system-zlib -qt-gif -release -shared -sm -nis -thread -stl \ # -system-lib{png,jpeg,mng} \ # -no-g++-exceptions -plugin-sql-{mysql,psql,sqlite,odbc}
msg "Starting configure..." ./configure -prefix ${_prefix} \ -docdir ${_prefix}/share/doc/qt \ -headerdir ${_prefix}/include/qt \ -plugindir ${_prefix}/lib/qt/plugins \ -datadir ${_prefix}/share/qt \ -translationdir ${_prefix}/share/qt/translations \ -sysconfdir /etc/qt \ -qt-gif \ -system-zlib \ -system-libjpeg \ -plugin-imgfmt-jpeg \ -system-libmng \ -plugin-imgfmt-mng \ -system-libpng \ -plugin-imgfmt-png \ -plugin-sql-mysql \ -plugin-sql-psql \ -plugin-sql-sqlite \ -plugin-sql-odbc \ -no-exceptions \ -thread \ -no-tablet #-platform linux-g++ \
# fix /opt/qt/lib path [ "$CARCH" = "x86_64" ] && sed -i "s|/opt/qt/lib64|/opt/qt/lib|g" ${QTDIR}/src/Makefile [ "$CARCH" = "x86_64" ] && sed -i "s|/opt/qt/lib64|/opt/qt/lib|g" ${QTDIR}/tools/designer/designer/Makefile [ "$CARCH" = "x86_64" ] && sed -i "s|/opt/qt/lib64|/opt/qt/lib|g" ${QTDIR}/tools/designer/editor/Makefile [ "$CARCH" = "x86_64" ] && sed -i "s|/opt/qt/lib64|/opt/qt/lib|g" ${QTDIR}/tools/assistant/lib/Makefile [ "$CARCH" = "x86_64" ] && sed -i "s|/opt/qt/lib64|/opt/qt/lib|g" ${QTDIR}/tools/designer/uilib/Makefile
# bahoo make # make sub-tools
cd ${QTDIR} make -C qmake || return 1 cd ${QTDIR}/plugins/src/sqldrivers/mysql ${QTDIR}/bin/qmake -o Makefile "INCPATH+=/usr/include/mysql" "LIBS+=-L/usr/lib/mysql -lmysqlclient" mysql.pro cd ${QTDIR}/plugins/src/sqldrivers/psql ${QTDIR}/bin/qmake -o Makefile "INCPATH+=/usr/src/include /usr/include/postgresql/server" "LIBS+=-L/usr/lib -lpq" psql.pro
cd ${QTDIR} # fix the broken makefiles #sed -i 's|[[:space:]]*strip.*doc/html.*$|#|g' src/Makefile make || return 1
}
package() { msg "Packaging - $pkgname-$pkgver" cd ${QTDIR} pkgver=${_patchver} make INSTALL_ROOT=${pkgdir} install
## Original Qt Build rm -rf ${pkgdir}${_prefix}/{phrasebooks,templates,translations} sed -i "s|-L${QTDIR}/lib ||g" ${pkgdir}${_prefix}/lib/*.prl install -D -m755 qmake/qmake ${pkgdir}${_prefix}/bin/qmake
# Build and install qt.profile echo "export QTDIR=${_prefix}" > ${srcdir}/qt.profile echo "export QT_XFT=true" >> ${srcdir}/qt.profile echo 'export PATH=$PATH:$QTDIR/bin' >> ${srcdir}/qt.profile echo 'export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:$QTDIR/pkgconfig' >> ${srcdir}/qt.profile install -D -m755 ${srcdir}/qt.profile ${pkgdir}/etc/profile.d/qt3.sh
ln -sf ${_prefix}/bin/qtconfig ${pkgdir}${_prefix}/bin/qt3config rm -f ${pkgdir}${_prefix}/mkspecs/linux-g++$ARCH/linux-g++$ARCH
# install man pages mkdir -p ${pkgdir}${_prefix}/man cp -r ${QTDIR}/doc/man/{man1,man3} ${pkgdir}${_prefix}/man/
# Uncomment to install examples # cp -v -r ${QTDIR}/examples ${pkgdir}${_prefix}/share/doc/qt
install -d -m755 ${pkgdir}/etc/ld.so.conf.d/ echo "${_prefix}/lib" > ${pkgdir}/etc/ld.so.conf.d/qt3.conf
On 04/30/2011 11:17 PM, David C. Rankin wrote:
On 04/30/2011 06:15 PM, Ilya Chernykh wrote:
On Sunday 01 May 2011 01:57:41 David C. Rankin wrote:
I have finally gotten a few minutes to dive back into Trinity. To my chagrin, we have Arch has bumped from gcc 4.5 to gcc 4.6. I am having problems building Qt3. Adding to the difficulty, the Qt3 build script for Arch has been through a number of changes lately and I haven't had time to verify the new build script under gcc 4.5 before the jump to gcc 4.6. So I am working to understand whether this build failure is gcc related or if it is a normal screw-up on my end.
See if this can help: https://api.opensuse.org/public/source/KDE:KDE3/qt3/gcc46.diff
Hah!
It did -- Qt3 is building as we speak. Here is the PKGBUILD I'm using (including the gcc46.diff). Baho, I don't know why the 'make subtools' works without the patch, but I guess the parts that need #include <cstddef> aren't triggered by that make. Here is what I have so far. I'll report back after I have finished the build and tested it. Then I can catch up on all the changes in the Trinity packages and what else I can build now :P
Wohoo!
==> Tidying install... -> Purging other files... -> Compressing man and info pages... -> Stripping unneeded symbols from binaries and libraries... -> Removing libtool .la files... ==> WARNING: Package contains reference to $srcdir ==> Creating package... -> Generating .PKGINFO file... -> Compressing package... ==> Leaving fakeroot environment. ==> Finished making: trinity-qt3 3.3.8b-1 (Sat Apr 30 23:32:12 CDT 2011) 23:32 supersff:~/tblds/trinity-qt3> l total 25868 drwxr-xr-x 4 david david 4096 Apr 30 23:31 . drwxr-xr-x 7 david david 4096 Apr 30 16:38 .. drwxr-xr-x 4 david david 4096 Apr 30 23:31 pkg drwxr-xr-x 4 david david 4096 Apr 30 23:30 src -rw-r--r-- 1 david david 10386 Apr 30 23:11 PKGBUILD -rw-r--r-- 1 david david 1437 Jan 21 17:32 eastern_asian_languagues.diff -rw-r--r-- 1 david david 1824 Apr 30 22:59 gcc46.diff -rw-r--r-- 1 david david 698 Jan 21 17:32 qt-odbc.patch -rw-r--r-- 1 david david 3708 Jan 21 17:32 qt-patches.tar.bz2 -rw-r--r-- 1 david david 17313883 Apr 30 16:38 qt-x11-free-3.3.8b.tar.gz -rw-r--r-- 1 david david 1339 Jan 21 17:32 qt3-png14.patch -rw-r--r-- 1 david david 2378 Mar 25 19:17 qt3_3.3.8c.arch.diff -rw-r--r-- 1 david david 9075324 Apr 30 23:32 trinity-qt3-3.3.8c-1-i686.pkg.tar.xz
Back in the saddle again :)
On 05/01/2011 12:43 AM, David C. Rankin wrote:
On 04/30/2011 11:17 PM, David C. Rankin wrote:
On 04/30/2011 06:15 PM, Ilya Chernykh wrote:
On Sunday 01 May 2011 01:57:41 David C. Rankin wrote:
I have finally gotten a few minutes to dive back into Trinity. To my chagrin, we have Arch has bumped from gcc 4.5 to gcc 4.6. I am having problems building Qt3. Adding to the difficulty, the Qt3 build script for Arch has been through a number of changes lately and I haven't had time to verify the new build script under gcc 4.5 before the jump to gcc 4.6. So I am working to understand whether this build failure is gcc related or if it is a normal screw-up on my end.
See if this can help: https://api.opensuse.org/public/source/KDE:KDE3/qt3/gcc46.diff
Hah!
It did -- Qt3 is building as we speak. Here is the PKGBUILD I'm using (including the gcc46.diff). Baho, I don't know why the 'make subtools' works without the patch, but I guess the parts that need #include <cstddef> aren't triggered by that make. Here is what I have so far. I'll report back after I have finished the build and tested it. Then I can catch up on all the changes in the Trinity packages and what else I can build now :P
make without sub-tools works as well without the patch.
Le Sat, 30 Apr 2011 16:57:41 -0500, "David C. Rankin" drankinatty@suddenlinkmail.com a écrit :
Guys,
I have finally gotten a few minutes to dive back into Trinity. To my chagrin, we have Arch has bumped from gcc 4.5 to gcc 4.6. I am having problems building Qt3. Adding to the difficulty, the Qt3 build script for Arch has been through a number of changes lately and I haven't had time to verify the new build script under gcc 4.5 before the jump to gcc 4.6. So I am working to understand whether this build failure is gcc related or if it is a normal screw-up on my end.
The build is failing in the middle of the build, so this leads me to think this might be gcc related. If anybody can look at the error and determine whether this is a gcc issue or not, I would greatly appreciate it. I think what I'll do is drop back to a build script that I know was working on gcc 4.5 and confirm, but in the interim, I thought I would post the error in hope somebody else had seen this already. What does this error look like to the masters?:
g++ -c -pipe -Wall -W -march=i686 -mtune=generic -O2 -pipe -D_REENTRANT -fPIC -DQT_SHARED -DQT_NO_DEBUG -DQT_THREAD_SUPPORT -DQT_THREAD_SUPPORT -D_LARGEFILE_SOURCE -D_LARGE_FILES -D_FILE_OFFSET_BITS=64 -DQT_NO_IMAGEIO_MNG -DQT_NO_IMAGEIO_JPEG -DQT_NO_IMAGEIO_PNG -DQT_BUILTIN_GIF_READER=1 -DQT_NO_STYLE_MAC -DQT_NO_STYLE_AQUA -DQT_NO_STYLE_INTERLACE -DQT_NO_STYLE_WINDOWSXP -DQT_NO_STYLE_COMPACT -DQT_NO_STYLE_POCKETPC -I/home/david/tblds/trinity-qt3/src/qt-x11-free-3.3.8b/mkspecs/linux-g++ -I. -I/usr/include/freetype2 -I3rdparty/opentype -I../include -I/usr/X11R6/include -I/usr/X11R6/include -I.moc/release-shared-mt/ -o .obj/release-shared-mt/qapplication_x11.o kernel/qapplication_x11.cpp In file included from ../include/qmap.h:49:0, from kernel/qmime.h:46, from kernel/qevent.h:48, from kernel/qobject.h:48, from kernel/qwidget.h:46, from kernel/qdesktopwidget.h:43, from kernel/qapplication.h:45, from kernel/qapplication_x11.cpp:67: ../include/qvaluelist.h:91:13: error: ‘ptrdiff_t’ does not name a type ../include/qvaluelist.h:167:13: error: ‘ptrdiff_t’ does not name a type In file included from ../include/qmap.h:49:0, from kernel/qmime.h:46, from kernel/qevent.h:48, from kernel/qobject.h:48, from kernel/qwidget.h:46, from kernel/qdesktopwidget.h:43, from kernel/qapplication.h:45, from kernel/qapplication_x11.cpp:67: ../include/qvaluelist.h:427:13: error: ‘ptrdiff_t’ does not name a type In file included from kernel/qmime.h:46:0, from kernel/qevent.h:48, from kernel/qobject.h:48, from kernel/qwidget.h:46, from kernel/qdesktopwidget.h:43, from kernel/qapplication.h:45, from kernel/qapplication_x11.cpp:67: ../include/qmap.h:110:13: error: ‘ptrdiff_t’ does not name a type ../include/qmap.h:226:13: error: ‘ptrdiff_t’ does not name a type In file included from kernel/qmime.h:46:0, from kernel/qevent.h:48, from kernel/qobject.h:48, from kernel/qwidget.h:46, from kernel/qdesktopwidget.h:43, from kernel/qapplication.h:45, from kernel/qapplication_x11.cpp:67: ../include/qmap.h:607:13: error: ‘ptrdiff_t’ does not name a type kernel/qapplication_x11.cpp: In member function ‘int QApplication::x11ProcessEvent(XEvent*)’: kernel/qapplication_x11.cpp:3693:54: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses] kernel/qapplication_x11.cpp:3706:54: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses] kernel/qapplication_x11.cpp: In member function ‘bool QETWidget::translateMouseEvent(const XEvent*)’: kernel/qapplication_x11.cpp:4122:30: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses] kernel/qapplication_x11.cpp: In member function ‘bool QETWidget::translateKeyEventInternal(const XEvent*, int&, QString&, int&, char&, int&, QEvent::Type&, bool)’: kernel/qapplication_x11.cpp:5161:8: warning: suggest explicit braces to avoid ambiguous ‘else’ [-Wparentheses] kernel/qapplication_x11.cpp:5232:52: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses] kernel/qapplication_x11.cpp:5235:52: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses] kernel/qapplication_x11.cpp: In function ‘int isPaintOrScrollDoneEvent(Display*, XEvent*, XPointer)’: kernel/qapplication_x11.cpp:5524:34: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses] make[2]: *** [.obj/release-shared-mt/qapplication_x11.o] Error 1 make[2]: Leaving directory `/home/david/tblds/trinity-qt3/src/qt-x11-free-3.3.8b/src' make[1]: *** [sub-src] Error 2 make[1]: Leaving directory `/home/david/tblds/trinity-qt3/src/qt-x11-free-3.3.8b' make: *** [init] Error 2 ==> ERROR: A failure occurred in build(). Aborting...
I'll go try an older build script that used qt-x11-free-3.3.8 instead of qt-x11-free-3.3.8b. I'll report back :p
This is probably a g++-4.6 related error. http://gcc.gnu.org/gcc-4.6/changes.html says : "Most libstdc++ standard headers have been changed to no longer include the cstddef header as an implementation detail. Code that relied on that header being included as side-effect of including other standard headers will need to include cstddef explicitly." And the unpatched qvaluelist.h includes <iterator> and <list>, but not <cstddef>. So we probably just need to patch the error-producing headers to #include <cstddef>.
On Sat, Apr 30, 2011 at 19:24, /dev/ammo42 mickeytintincolle@yahoo.fr wrote:
Le Sat, 30 Apr 2011 16:57:41 -0500, "David C. Rankin" drankinatty@suddenlinkmail.com a écrit :
Guys,
I have finally gotten a few minutes to dive back into Trinity. To my chagrin, we have Arch has bumped from gcc 4.5 to gcc 4.6. I am having problems building Qt3. Adding to the difficulty, the Qt3 build script for Arch has been through a number of changes lately and I haven't had time to verify the new build script under gcc 4.5 before the jump to gcc 4.6. So I am working to understand whether this build failure is gcc related or if it is a normal screw-up on my end.
The build is failing in the middle of the build, so this leads me to think this might be gcc related. If anybody can look at the error and determine whether this is a gcc issue or not, I would greatly appreciate it. I think what I'll do is drop back to a build script that I know was working on gcc 4.5 and confirm, but in the interim, I thought I would post the error in hope somebody else had seen this already. What does this error look like to the masters?:
g++ -c -pipe -Wall -W -march=i686 -mtune=generic -O2 -pipe -D_REENTRANT -fPIC -DQT_SHARED -DQT_NO_DEBUG -DQT_THREAD_SUPPORT -DQT_THREAD_SUPPORT -D_LARGEFILE_SOURCE -D_LARGE_FILES -D_FILE_OFFSET_BITS=64 -DQT_NO_IMAGEIO_MNG -DQT_NO_IMAGEIO_JPEG -DQT_NO_IMAGEIO_PNG -DQT_BUILTIN_GIF_READER=1 -DQT_NO_STYLE_MAC -DQT_NO_STYLE_AQUA -DQT_NO_STYLE_INTERLACE -DQT_NO_STYLE_WINDOWSXP -DQT_NO_STYLE_COMPACT -DQT_NO_STYLE_POCKETPC -I/home/david/tblds/trinity-qt3/src/qt-x11-free-3.3.8b/mkspecs/linux-g++ -I. -I/usr/include/freetype2 -I3rdparty/opentype -I../include -I/usr/X11R6/include -I/usr/X11R6/include -I.moc/release-shared-mt/ -o .obj/release-shared-mt/qapplication_x11.o kernel/qapplication_x11.cpp In file included from ../include/qmap.h:49:0, from kernel/qmime.h:46, from kernel/qevent.h:48, from kernel/qobject.h:48, from kernel/qwidget.h:46, from kernel/qdesktopwidget.h:43, from kernel/qapplication.h:45, from kernel/qapplication_x11.cpp:67: ../include/qvaluelist.h:91:13: error: ‘ptrdiff_t’ does not name a type ../include/qvaluelist.h:167:13: error: ‘ptrdiff_t’ does not name a type In file included from ../include/qmap.h:49:0, from kernel/qmime.h:46, from kernel/qevent.h:48, from kernel/qobject.h:48, from kernel/qwidget.h:46, from kernel/qdesktopwidget.h:43, from kernel/qapplication.h:45, from kernel/qapplication_x11.cpp:67: ../include/qvaluelist.h:427:13: error: ‘ptrdiff_t’ does not name a type In file included from kernel/qmime.h:46:0, from kernel/qevent.h:48, from kernel/qobject.h:48, from kernel/qwidget.h:46, from kernel/qdesktopwidget.h:43, from kernel/qapplication.h:45, from kernel/qapplication_x11.cpp:67: ../include/qmap.h:110:13: error: ‘ptrdiff_t’ does not name a type ../include/qmap.h:226:13: error: ‘ptrdiff_t’ does not name a type In file included from kernel/qmime.h:46:0, from kernel/qevent.h:48, from kernel/qobject.h:48, from kernel/qwidget.h:46, from kernel/qdesktopwidget.h:43, from kernel/qapplication.h:45, from kernel/qapplication_x11.cpp:67: ../include/qmap.h:607:13: error: ‘ptrdiff_t’ does not name a type kernel/qapplication_x11.cpp: In member function ‘int QApplication::x11ProcessEvent(XEvent*)’: kernel/qapplication_x11.cpp:3693:54: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses] kernel/qapplication_x11.cpp:3706:54: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses] kernel/qapplication_x11.cpp: In member function ‘bool QETWidget::translateMouseEvent(const XEvent*)’: kernel/qapplication_x11.cpp:4122:30: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses] kernel/qapplication_x11.cpp: In member function ‘bool QETWidget::translateKeyEventInternal(const XEvent*, int&, QString&, int&, char&, int&, QEvent::Type&, bool)’: kernel/qapplication_x11.cpp:5161:8: warning: suggest explicit braces to avoid ambiguous ‘else’ [-Wparentheses] kernel/qapplication_x11.cpp:5232:52: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses] kernel/qapplication_x11.cpp:5235:52: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses] kernel/qapplication_x11.cpp: In function ‘int isPaintOrScrollDoneEvent(Display*, XEvent*, XPointer)’: kernel/qapplication_x11.cpp:5524:34: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses] make[2]: *** [.obj/release-shared-mt/qapplication_x11.o] Error 1 make[2]: Leaving directory `/home/david/tblds/trinity-qt3/src/qt-x11-free-3.3.8b/src' make[1]: *** [sub-src] Error 2 make[1]: Leaving directory `/home/david/tblds/trinity-qt3/src/qt-x11-free-3.3.8b' make: *** [init] Error 2 ==> ERROR: A failure occurred in build(). Aborting...
I'll go try an older build script that used qt-x11-free-3.3.8 instead of qt-x11-free-3.3.8b. I'll report back :p
This is probably a g++-4.6 related error. http://gcc.gnu.org/gcc-4.6/changes.html says : "Most libstdc++ standard headers have been changed to no longer include the cstddef header as an implementation detail. Code that relied on that header being included as side-effect of including other standard headers will need to include cstddef explicitly." And the unpatched qvaluelist.h includes <iterator> and <list>, but not <cstddef>. So we probably just need to patch the error-producing headers to #include <cstddef>.
which is what the gcc46.diff patch does, so you're right on target :P
On 04/30/2011 05:57 PM, David C. Rankin wrote:
../include/qmap.h:607:13: error: ‘ptrdiff_t’ does not name a type kernel/qapplication_x11.cpp: In member function ‘int QApplication::x11ProcessEvent(XEvent*)’: kernel/qapplication_x11.cpp:3693:54: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses] kernel/qapplication_x11.cpp:3706:54: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses] kernel/qapplication_x11.cpp: In member function ‘bool QETWidget::translateMouseEvent(const XEvent*)’: kernel/qapplication_x11.cpp:4122:30: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses] kernel/qapplication_x11.cpp: In member function ‘bool QETWidget::translateKeyEventInternal(const XEvent*, int&, QString&, int&, char&, int&, QEvent::Type&, bool)’: kernel/qapplication_x11.cpp:5161:8: warning: suggest explicit braces to avoid ambiguous ‘else’ [-Wparentheses] kernel/qapplication_x11.cpp:5232:52: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses] kernel/qapplication_x11.cpp:5235:52: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses] kernel/qapplication_x11.cpp: In function ‘int isPaintOrScrollDoneEvent(Display*, XEvent*, XPointer)’: kernel/qapplication_x11.cpp:5524:34: warning: suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses] make[2]: *** [.obj/release-shared-mt/qapplication_x11.o] Error 1 make[2]: Leaving directory `/home/david/tblds/trinity-qt3/src/qt-x11-free-3.3.8b/src' make[1]: *** [sub-src] Error 2 make[1]: Leaving directory `/home/david/tblds/trinity-qt3/src/qt-x11-free-3.3.8b' make: *** [init] Error 2 ==> ERROR: A failure occurred in build(). Aborting...
I'll go try an older build script that used qt-x11-free-3.3.8 instead of qt-x11-free-3.3.8b. I'll report back :p
Works for me
$ gcc --version gcc (GCC) 4.6.0 20110415 (prerelease) Copyright (C) 2011 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
cp -f "../doc/html/xml-sax-walkthrough.html" "/build/pkg/usr/qt3/doc/html/" cp -f "../doc/html/xml-tools.html" "/build/pkg/usr/qt3/doc/html/" cp -f "../doc/html/xml.html" "/build/pkg/usr/qt3/doc/html/" cp -f "../doc/html/y2k.html" "/build/pkg/usr/qt3/doc/html/" make[2]: Leaving directory `/build/src/qt-x11-free-3.3.8b/src' make[1]: Leaving directory `/build/src/qt-x11-free-3.3.8b' `/build/pkg/usr/qt3/mkspecs/linux-g++/linux-g++' -> `../linux-g++' `/build/pkg/usr/qt3/lib/libqt.so' -> `libqt-mt.so' install: creating directory `/build/pkg/etc' install: creating directory `/build/pkg/etc/profile.d' ==> Tidying install... -> Removing doc files... -> Purging other files... -> Compressing man and info pages... -> Stripping unneeded symbols from binaries and libraries... ==> WARNING: Package contains reference to $srcdir ==> Creating package... -> Generating .PKGINFO file... -> Compressing package... ==> Leaving fakeroot environment ==> Finished making: qt3 3.3.8b-3 (Sun May 1 00:31:55 UTC 2011)
PKGBUILD Follows:
# $Id$ # Maintainer: Baho Utot baho-utot@columbus.rr.com _module=qt-x11-free _pkgname=${_module} _pkgver=3.3.8c _prefix="/usr/qt3" pkgname=qt3 pkgver=3.3.8b pkgrel=3 arch=('i686' 'x86_64') url="http://qt.nokia.com/products/" license=('GPL2') groups=('trinity') pkgdesc="Trinity - ${_module}" depends=(libjpeg-turbo libxft libxrandr libxcursor libxinerama unixodbc postgresql-libs libmysqlclient libpng libmng libsm) makedepends=(sqlite3 cups postgresql libxi) optdepends=( ) options=(!docs) provides=(qt3) conflicts=(qt3 qt3-enhanced) source=( ftp://ftp.trolltech.com/qt/source/qt-x11-free-3.3.8b.tar.gz qt-patches.tar.bz2 qt3-png14.patch eastern_asian_languagues.diff qt-odbc.patch qt3_3.3.8c.diff) build() { cd "${srcdir}/${_module}-${pkgver}" export PATH=${PWD}/bin:${PATH} export LD_LIBRARY_PATH=${PWD}/lib:${LD_LIBRARY_PATH} export CPATH=/usr/include/postgresql/server:/usr/include/mysql # # makum' apache A la Ke # msg "Patching source files....." # apply other qt patches and one security fix from debian/gentoo for i in ../qt-patches/*; do patch -Np1 -i $i || return 1 done # fix CJK font/chars select error (FS#11245) patch -p1 -i ${srcdir}/eastern_asian_languagues.diff || return 1 # fix build problem against new unixODBC patch -p1 -i ${srcdir}/qt-odbc.patch || return 1 patch -p0 -i ${srcdir}/qt3-png14.patch # patch for qt3_3.3.8c patch -p0 -i ${srcdir}/qt3_3.3.8c.diff || return 1 # remove runtime library search not needed when installed into /usr sed -i '/QMAKE_RPATH/d' mkspecs/linux*/qmake.conf sed -i 's|-cp -P -f|-cp -L -f|' qmake/Makefile.unix sed -i "s|read acceptance|acceptance=yes|" configure # Remove mkspecs not needed rm -rf mkspecs/{*aix*,*bsd*,cygwin*,dgux*,darwin*,hpux*,hurd*,irix*,lynxos*,macx*,qnx*,reliant*,sco*,solaris*,tru64*,unixware*,win32*} # Lets do it! msg "Starting configure..." ./configure -prefix ${_prefix} \ -sysconfdir /etc/qt \ -sm \ -qt-gif \ -system-zlib \ -no-exceptions \ -platform linux-g++ \ -plugin-sql-mysql \ -plugin-sql-psql \ -plugin-sql-sqlite \ -plugin-sql-odbc \ -thread \ -no-nis \ -cups \ -no-stl \ -no-ipv6 \ -plugin-imgfmt-jpeg \ -plugin-imgfmt-mng \ -plugin-imgfmt-png \ -system-libmng \ -system-libjpeg \ -system-libpng \ -no-nas-sound \ -no-tablet make sub-tools } package() { msg "Packaging - $pkgname-$pkgver" cd "${srcdir}/${_module}-${pkgver}" pkgver=${_pkgver} make INSTALL_ROOT=${pkgdir} install rm ${pkgdir}${_prefix}/mkspecs/linux-g++/linux-g++ ln -v -snf ../linux-g++ ${pkgdir}${_prefix}/mkspecs/linux-g++/linux-g++ ln -v -sf libqt-mt.so ${pkgdir}${_prefix}/lib/libqt.so # Don't doc/man pages rm -rf ${pkgdir}/usr/qt3/doc # Don't do examples #cp -v -r examples ${pkgdir}${_prefix}/share/doc/qt # Build qt.profile install -vd -m 755 ${pkgdir}/etc/profile.d echo 'export QT_XFT=true' > ${pkgdir}/etc/profile.d/qt3.sh echo "QTDIR=${_prefix}" >> ${pkgdir}/etc/profile.d/qt3.sh echo 'PATH=${QTDIR}/bin:${PATH:=}' >> ${pkgdir}/etc/profile.d/qt3.sh echo 'PATH=${PATH%:}' >> ${pkgdir}/etc/profile.d/qt3.sh echo 'LD_LIBRARY_PATH=${QTDIR}/lib:${LD_LIBRARY_PATH:=}' >> ${pkgdir}/etc/profile.d/qt3.sh echo 'LD_LIBRARY_PATH=${LD_LIBRARY_PATH%:}' >> ${pkgdir}/etc/profile.d/qt3.sh echo 'export QTDIR PATH LD_LIBRARY_PATH' >> ${pkgdir}/etc/profile.d/qt3.sh ln -sf qtconfig ${pkgdir}${_prefix}/bin/qt3config } md5sums=('9f05b4125cfe477cc52c9742c3c09009' '2f00e5c0c1e2c2a23dddc982cd79f3e0' '1dc671df42b9030dbdf68bb61cd3375e' '616f1f3029cf8375256ad6a406de3549' '2178ca88dfd75a230918593b30eb0dbe' 'd1b9c8cbc75d6da38b2528b6dc063fe8')
On 04/30/2011 07:36 PM, Baho Utot wrote:
On 04/30/2011 05:57 PM, David C. Rankin wrote:
../include/qmap.h:607:13: error: ‘ptrdiff_t’ does not name a type kernel/qapplication_x11.cpp: In member function ‘int QApplication::x11ProcessEvent(XEvent*)’:
Yep, your right,
I used your PKGBUILD and it worked fine with gcc 4.6 -- so the answer is clear -- it's me again :p
'make subtools' seems to be the key. I'll have to do more studying to understand the difference between the old way of using:
cd ${QTDIR} make -C qmake || return 1 cd ${QTDIR}/plugins/src/sqldrivers/mysql ${QTDIR}/bin/qmake -o Makefile "INCPATH+=/usr/include/mysql" "LIBS+=-L/usr/lib/mysql -lmysqlclient" mysql.pro cd ${QTDIR}/plugins/src/sqldrivers/psql ${QTDIR}/bin/qmake -o Makefile "INCPATH+=/usr/src/include /usr/include/postgresql/server" "LIBS+=-L/usr/lib -lpq" psql.pro
cd ${QTDIR} # fix the broken makefiles #sed -i 's|[[:space:]]*strip.*doc/html.*$|#|g' src/Makefile make || return 1
At least we know Qt3 is good with gcc 4.6. I'll have more time tomorrow to look at it.
On 04/30/2011 09:43 PM, David C. Rankin wrote:
On 04/30/2011 07:36 PM, Baho Utot wrote:
Yep, your right,
I used your PKGBUILD and it worked fine with gcc 4.6 -- so the answer is clear -- it's me again :p
'make subtools' seems to be the key. I'll have to do more studying to understand the difference between the old way of using:
The build time for Qt is quite long. If you want to save some time and don't want the tutorials and examples, change the make command to: make sub-tools
At least we know Qt3 is good with gcc 4.6. I'll have more time tomorrow to look at it.