[113828] trunk/dports/kde/kde4-filelight/files/fix-filelight-mounts.diff

nicos at macports.org nicos at macports.org
Sun Nov 24 07:35:17 PST 2013


Revision: 113828
          https://trac.macports.org/changeset/113828
Author:   nicos at macports.org
Date:     2013-11-24 07:35:17 -0800 (Sun, 24 Nov 2013)
Log Message:
-----------
kde4-filelight: correct patch to build on Mavericks

Modified Paths:
--------------
    trunk/dports/kde/kde4-filelight/files/fix-filelight-mounts.diff

Modified: trunk/dports/kde/kde4-filelight/files/fix-filelight-mounts.diff
===================================================================
--- trunk/dports/kde/kde4-filelight/files/fix-filelight-mounts.diff	2013-11-24 15:25:30 UTC (rev 113827)
+++ trunk/dports/kde/kde4-filelight/files/fix-filelight-mounts.diff	2013-11-24 15:35:17 UTC (rev 113828)
@@ -1,60 +1,20 @@
-diff -ur ../filelight-4.8.0_orig/src/part/localLister.cpp ./src/part/localLister.cpp
---- ../filelight-4.8.0_orig/src/part/localLister.cpp	2012-01-31 14:47:57.000000000 +0900
-+++ ./src/part/localLister.cpp	2012-01-31 14:50:21.000000000 +0900
-@@ -45,6 +45,10 @@
- #include <sys/types.h>
- #include <unistd.h>
- 
-+#ifdef __APPLE_KDE__
-+#include <sys/mount.h>
-+#endif
-+
- #ifdef HAVE_MNTENT_H
- #include <mntent.h>
- #endif
-@@ -250,7 +254,25 @@
-         }
-     }
- 
--    kDebug() << "Found the following remote filesystems: " << s_remoteMounts;
-+#ifdef __APPLE_KDE__
-+    struct statfs *mounts;
-+    int nmounts = getmntinfo(&mounts, MNT_WAIT);
-+    for (int i = 0; i < nmounts; ++i) {
-+    	struct statfs *m = mounts + i;
-+    	if (m->f_flags & MNT_ROOTFS)
-+    		continue;
-+	
-+    	QString str = QString::fromUtf8(m->f_mntonname);
-+    	str += QLatin1Char('/');
-+	
-+    	QStringList &list = (m->f_flags & MNT_LOCAL)
-+    		? s_localMounts : s_remoteMounts;
-+    	if (!list.contains(str))
-+    		list.append(str);
-+    }
-+#endif
-+
-+	kDebug() << "Found the following remote filesystems: " << s_remoteMounts;
-     kDebug() << "Found the following local filesystems: " << s_localMounts;
- }
- 
-diff -ur ../filelight-4.8.0_orig/src/part/summaryWidget.cpp ./src/part/summaryWidget.cpp
---- ../filelight-4.8.0_orig/src/part/summaryWidget.cpp	2011-08-22 22:26:05.000000000 +0900
-+++ ./src/part/summaryWidget.cpp	2012-01-31 14:50:42.000000000 +0900
-@@ -45,6 +45,11 @@
+--- src/part/summaryWidget.cpp.orig	2013-11-24 22:07:54.000000000 +0900
++++ src/part/summaryWidget.cpp	2013-11-24 22:06:42.000000000 +0900
+@@ -45,6 +45,13 @@
  #include <QtGui/QMouseEvent>
  #include <QtGui/QLayout>
  
 +#ifdef __APPLE_KDE__
 +#include <QFileIconProvider>
 +#include <sys/mount.h>
++#include <sys/unistd.h>
++#include <unistd.h>
 +#endif
 +
  struct Disk
  {
      QString mount;
-@@ -137,7 +142,12 @@
+@@ -137,7 +144,12 @@
          QLabel *label = new QLabel(text, this);
          horizontalLayout->addWidget(label);
          QLabel *icon = new QLabel(this);
@@ -67,7 +27,7 @@
          horizontalLayout->addWidget(icon);
  
          horizontalLayout->setAlignment(Qt::AlignCenter);
-@@ -159,6 +169,25 @@
+@@ -159,6 +171,25 @@
  
  DiskList::DiskList()
  {
@@ -93,7 +53,7 @@
      const Solid::StorageAccess *partition;
      QStringList partitions;
  
-@@ -186,4 +215,5 @@
+@@ -186,4 +217,5 @@
  
          *this += disk;
      }
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-changes/attachments/20131124/b0ced5f3/attachment-0001.html>


More information about the macports-changes mailing list