rev 15108 - in trunk/packages/qt4-x11/debian: . patches
Fathi Boudra
fabo at alioth.debian.org
Sat Jul 4 16:02:53 UTC 2009
Author: fabo
Date: 2009-07-04 16:02:52 +0000 (Sat, 04 Jul 2009)
New Revision: 15108
Added:
trunk/packages/qt4-x11/debian/patches/0287-attempt-to-fix-header-installation-for-phonon.diff
Modified:
trunk/packages/qt4-x11/debian/changelog
trunk/packages/qt4-x11/debian/patches/series
Log:
Add patch:
- 0287-attempt-to-fix-header-installation-for-phonon.diff
This is the long-standing issue of whether Phonon headers should be
written with a capital P or a lowercase one.
Modified: trunk/packages/qt4-x11/debian/changelog
===================================================================
--- trunk/packages/qt4-x11/debian/changelog 2009-07-04 15:41:35 UTC (rev 15107)
+++ trunk/packages/qt4-x11/debian/changelog 2009-07-04 16:02:52 UTC (rev 15108)
@@ -34,6 +34,9 @@
on dbus adaptors.
- 0286-fix-error-string.diff
Fix #error line not to have a ' as it's not correct.
+ - 0287-attempt-to-fix-header-installation-for-phonon.diff
+ This is the long-standing issue of whether Phonon headers should be
+ written with a capital P or a lowercase one.
* Build Phonon from Qt sources:
- Add epoch to Phonon packages and set it to 4
(to upgrade phonon provided previously by KDE).
Added: trunk/packages/qt4-x11/debian/patches/0287-attempt-to-fix-header-installation-for-phonon.diff
===================================================================
--- trunk/packages/qt4-x11/debian/patches/0287-attempt-to-fix-header-installation-for-phonon.diff (rev 0)
+++ trunk/packages/qt4-x11/debian/patches/0287-attempt-to-fix-header-installation-for-phonon.diff 2009-07-04 16:02:52 UTC (rev 15108)
@@ -0,0 +1,129 @@
+From 2d1727e396d5dca24ae0fb6a45d35ffc1abd0c12 Mon Sep 17 00:00:00 2001
+From: Thiago Macieira <thiago.macieira at nokia.com>
+Date: Fri, 12 Jun 2009 14:27:54 +0200
+Subject: [PATCH] Attempt to fix header installation for Phonon.
+
+This is the long-standing issue of whether Phonon headers should be
+written with a capital P or a lowercase one. KDE releases of Phonon
+had <Phonon/CapitalClassName> whereas Qt 4.4 had <phonon/filename.h>.
+
+I tried to solve this before by adding a Phonon subdir next to phonon
+in include/, but that only compounded the error: the presence of two
+dirs caused problems and the installation wasn't fixed.
+
+So instead try to place Phonon/ClassName inside include/phonon. And
+fix the installation to do it properly: just copy the include/$lib dir
+into the target, then overwrite the .h files with the sources from
+src/$lib.
+
+Reviewed-by: Marius Storm-Olsen
+(cherry picked from commit 4b43263b870c17fd813d1d34f97146f4c725083e)
+---
+ bin/syncqt | 46 ++++++++++++++++++++++------------------------
+ src/qt_install.pri | 16 ++++++++++++----
+ 2 files changed, 34 insertions(+), 28 deletions(-)
+
+--- a/bin/syncqt
++++ b/bin/syncqt
+@@ -308,8 +308,6 @@ sub syncHeader {
+ $header =~ s=\\=/=g;
+ return copyFile($iheader, $header) if($copy);
+
+- my $iheader_no_basedir = $iheader;
+- $iheader_no_basedir =~ s,^$basedir/?,,;
+ unless(-e "$header") {
+ my $header_dir = dirname($header);
+ mkpath $header_dir, 0777;
+@@ -798,10 +796,9 @@ foreach (@modules_to_sync) {
+ my $class = $_;
+ if ($class =~ m/::/) {
+ $class =~ s,::,/,g;
+- $class = "../" . $class;
+ }
+ $class_lib_map_contents .= "QT_CLASS_LIB($_, $lib, $header_base)\n";
+- $header_copies++ if(syncHeader("$out_basedir/include/$lib/$class", $header, 0));
++ $header_copies++ if(syncHeader("$out_basedir/include/$lib/$class", "$out_basedir/include/$lib/$header", 0));
+ }
+ } else {
+ @headers = ( "$out_basedir/include/$lib/private/$header" );
+@@ -823,7 +820,6 @@ foreach (@modules_to_sync) {
+ my $class = $_;
+ if ($class =~ m/::/) {
+ $class =~ s,::,/,g;
+- $class = "../" . $class;
+ }
+ my $class_header = fixPaths("$out_basedir/include/$lib/$class",
+ $current_dir) . " ";
+@@ -844,25 +840,27 @@ foreach (@modules_to_sync) {
+ $master_contents .= "#endif\n";
+
+ unless($showonly) {
+- #generate the "master" include file
+- my $master_include = "$out_basedir/include/$lib/$lib";
+- $pri_install_files .= fixPaths($master_include, "$modules{$lib}") . " "; #get the master file installed too
+- if(-e "$master_include") {
+- open MASTERINCLUDE, "<$master_include";
+- local $/;
+- binmode MASTERINCLUDE;
+- my $oldmaster = <MASTERINCLUDE>;
+- close MASTERINCLUDE;
+- $oldmaster =~ s/\r//g; # remove \r's , so comparison is ok on all platforms
+- $master_include = 0 if($oldmaster eq $master_contents);
+- }
+- if($master_include && $master_contents) {
+- my $master_dir = dirname($master_include);
+- mkpath $master_dir, 0777;
+- print "header (master) created for $lib\n";
+- open MASTERINCLUDE, ">$master_include";
+- print MASTERINCLUDE "$master_contents";
+- close MASTERINCLUDE;
++ unless ($lib eq "phonon") {
++ #generate the "master" include file
++ my $master_include = "$out_basedir/include/$lib/$lib";
++ $pri_install_files .= fixPaths($master_include, "$modules{$lib}") . " "; #get the master file installed too
++ if($master_include && -e "$master_include") {
++ open MASTERINCLUDE, "<$master_include";
++ local $/;
++ binmode MASTERINCLUDE;
++ my $oldmaster = <MASTERINCLUDE>;
++ close MASTERINCLUDE;
++ $oldmaster =~ s/\r//g; # remove \r's , so comparison is ok on all platforms
++ $master_include = 0 if($oldmaster eq $master_contents);
++ }
++ if($master_include && $master_contents) {
++ my $master_dir = dirname($master_include);
++ mkpath $master_dir, 0777;
++ print "header (master) created for $lib\n";
++ open MASTERINCLUDE, ">$master_include";
++ print MASTERINCLUDE "$master_contents";
++ close MASTERINCLUDE;
++ }
+ }
+
+ #handle the headers.pri for each module
+--- a/src/qt_install.pri
++++ b/src/qt_install.pri
+@@ -15,11 +15,19 @@ qt_install_headers {
+ $$QT_SOURCE_TREE/src/corelib/arch/$$QT_ARCH/arch
+ }
+
+- flat_headers.files = $$INSTALL_HEADERS
+- flat_headers.path = $$[QT_INSTALL_HEADERS]/Qt
+- INSTALLS += flat_headers
++ equals(TARGET, phonon) {
++ class_headers.path = $$[QT_INSTALL_HEADERS]/$$TARGET/Phonon
++ } else {
++ flat_headers.files = $$INSTALL_HEADERS
++ flat_headers.path = $$[QT_INSTALL_HEADERS]/Qt
++ INSTALLS += flat_headers
+
+- targ_headers.files = $$INSTALL_HEADERS $$SYNCQT.HEADER_CLASSES
++ class_headers.path = $$[QT_INSTALL_HEADERS]/$$TARGET
++ }
++ class_headers.files = $$SYNCQT.HEADER_CLASSES
++ INSTALLS += class_headers
++
++ targ_headers.files = $$INSTALL_HEADERS
+ targ_headers.path = $$[QT_INSTALL_HEADERS]/$$TARGET
+ INSTALLS += targ_headers
+ }
Modified: trunk/packages/qt4-x11/debian/patches/series
===================================================================
--- trunk/packages/qt4-x11/debian/patches/series 2009-07-04 15:41:35 UTC (rev 15107)
+++ trunk/packages/qt4-x11/debian/patches/series 2009-07-04 16:02:52 UTC (rev 15108)
@@ -8,6 +8,7 @@
0274-shm-native-image-fix.diff
0280-deserialization-custom-dbus-properties.diff
0286-fix-error-string.diff
+0287-attempt-to-fix-header-installation-for-phonon.diff
# debian patches
01_qmake_for_debian.diff
More information about the pkg-kde-commits
mailing list