trinity-devel@lists.pearsoncomputing.net

Message: previous - next
Month: July 2012

TDE packaging for Debian, tqt3 and g++ 4.7.1

From: Bruce Sass <bmsass@...>
Date: Thu, 26 Jul 2012 16:28:32 -0600
Hi,

I built tqt3->tdebase on a Debian Unstable box (GCC-4.7.1, cmake-2.8.9~rc1) 
and the only show stopper was bug #1116 (kconfig_compiler should be 
renamed)--and that only cropped up because I have KDE-4 dev packages 
installed. I then started looking at the build logs for tqt3 and came across 
a few simple to fix packaging issues...

$ diff -ru tde/tde-packaging/debian/squeeze/dependencies/tqt3/debian 
tde/build/main/dependencies/tqt3/debian
Only in tde/tde-packaging/debian/squeeze/dependencies/tqt3/debian/patches: 
09_amd64_lib64.diff
diff -ru 
tde/tde-packaging/debian/squeeze/dependencies/tqt3/debian/patches/series 
tde/build/main/dependencies/tqt3/debian/patches/series
--- tde/tde-packaging/debian/squeeze/dependencies/tqt3/debian/patches/series    
2012-07-13 00:27:09.000000000 -0600
+++ tde/build/main/dependencies/tqt3/debian/patches/series      2012-07-20 
15:25:19.000000000 -0600
@@ -1,4 +1,3 @@
 06_disable_rpath.diff
-09_amd64_lib64.diff
 72_dont_trust_uname-m_use_dpkg-arch_instead.diff
 kubuntu_06_fglrx_0_size_screen.diff

... 09_amd64_lib64.diff patches to use obsolete /usr/X11R6 dirs ...

diff -ru tde/tde-packaging/debian/squeeze/dependencies/tqt3/debian/rules 
tde/build/main/dependencies/tqt3/debian/rules
--- tde/tde-packaging/debian/squeeze/dependencies/tqt3/debian/rules     
2012-07-13 00:27:09.000000000 -0600
+++ tde/build/main/dependencies/tqt3/debian/rules       2012-07-23 
19:08:09.000000000 -0600
@@ -25,7 +25,11 @@
 ifeq ($(DEB_HOST_ARCH),sparc)
        PLATFORM_ARG = linux-g++-sparc
 else #sparc
+ifeq ($(DEB_HOST_ARCH),amd64)
+       PLATFORM_ARG = linux-g++-64
+else #amd64
        PLATFORM_ARG = linux-g++
+endif #amd64
 endif #sparc
 endif #hurd

... the platform wasn't being set properly, mkspecs/linux-g++ was being used 
instead of the expected mkspecs/linux-g++-64. This patches over the problem 
but (AFAICT) shouldn't be necessary (i.e., something deeper needs fixing)...
 
@@ -230,8 +234,6 @@
        # copy all docs there first
        install -d $(P_DOC)/usr/share/tqt3/doc/html/
        for a in `cd $(TMP_INSTALL)/usr/share/tqt3/doc/html/ && find`; do cp 
$(TMP_INSTALL)/usr/share/tqt3/doc/html/"$$a" 
$(P_DOC)/usr/share/tqt3/doc/html/; done
-       #typo bugfix
-       sed -i -e 's/reveives/receives/' 
$(P_DOC)/usr/share/tqt3/doc/html/ntqwidget.html
 
        ## build designer package documentation
        # tqt3-designer

... fixing a typo via sed in the packaging is ugly, best to fix the typo in 
the source itself and be done with it for everyone, eh.

Generally, it looks like the Debian packaging of everything required to get 
tdebase up and running needs more updating than is reasonable to do via 
tweaking what exists if the packages are to conform to current Debian Policy 
and best practice--it may be best to backport the packaging currently being 
used by Debian into Trinity where possible.

While looking through the build.log for tqt3 I kept getting distracted by the 
piles of "suggest parentheses around ‘&&’ within ‘||’ [-Wparentheses]" 
warnings--so I  went through the source and added in all the missing 
parentheses g++ was complaining about (plus fixed a few more warnings where 
the fix was just as obvious). The build log is much easier to read now, and 
potentially problematic warnings (such as [-Wdelete-non-virtual-dtor][1]) are 
no longer buried among the noise.

What is the best way for me to get the tqt3 source changes to you?

- Bruce

[1] -Wdelete-non-virtual-dtor comes in two flavours, one which may result in a 
memory leak and another which will result in undefined behaviour.