commit:     ad4e2a014bd8657071af9e96ac149475b3ff5963
Author:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Fri Jun 14 20:15:30 2019 +0000
Commit:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Fri Jun 14 20:42:20 2019 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ad4e2a01

net-misc/smb4k: Fix mounting default values

Package-Manager: Portage-2.3.67, Repoman-2.3.14
Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org>

 .../smb4k-3.0.0-fix-mount-readwrite-shares.patch   | 61 +++++++++++++++++++
 net-misc/smb4k/smb4k-3.0.0-r1.ebuild               | 70 ++++++++++++++++++++++
 2 files changed, 131 insertions(+)

diff --git a/net-misc/smb4k/files/smb4k-3.0.0-fix-mount-readwrite-shares.patch 
b/net-misc/smb4k/files/smb4k-3.0.0-fix-mount-readwrite-shares.patch
new file mode 100644
index 00000000000..84d50b75b46
--- /dev/null
+++ b/net-misc/smb4k/files/smb4k-3.0.0-fix-mount-readwrite-shares.patch
@@ -0,0 +1,61 @@
+From 886af393dab0f6efe0f8bafc03522f25c15e0ba6 Mon Sep 17 00:00:00 2001
+From: Alexander Reinholdt <alexander.reinho...@kdemail.net>
+Date: Thu, 13 Jun 2019 20:57:38 +0200
+Subject: It was reported that Smb4K mounts shares read-only that were
+ previously accessible read-write. It turns out that the default for the "CIFS
+ Unix extensions" setting were not chosen very carefully. This commit changes
+ the default values back, so that mounting should work again as expected.
+
+(cherry picked from commit d3b89af5410ea8d4cb5f34921d48fdda486990f2)
+---
+ core/smb4kmountsettings_linux.kcfg | 10 +++++-----
+ 1 file changed, 5 insertions(+), 5 deletions(-)
+
+diff --git a/core/smb4kmountsettings_linux.kcfg 
b/core/smb4kmountsettings_linux.kcfg
+index 4ad329c..7e046dd 100644
+--- a/core/smb4kmountsettings_linux.kcfg
++++ b/core/smb4kmountsettings_linux.kcfg
+@@ -11,12 +11,12 @@
+     <entry name="CifsUnixExtensionsSupport" type="Bool">
+       <label>All or most of the servers support the CIFS Unix 
extensions</label>
+       <whatsthis>Most versions of Samba support the CIFS Unix or POSIX 
extensions. For these servers, some options are not needed, because the right 
values are negotiated during the mount process. For other servers, you might 
want to uncheck this option, so that predefined values can be passed to the 
server. Please note that if your computer is located in a Windows dominated 
network neighborhood with only a few Samba servers, you can safely uncheck this 
option and define custom options for the Samba servers.</whatsthis>
+-      <default>true</default>
++      <default>false</default>
+     </entry>
+     <entry name="UseUserId" type="Bool">
+       <label>User ID:</label>
+       <whatsthis>This is the user ID (a number) that the files and 
directories of the mounted share will have. If you are using the CIFS 
filesystem under Linux and the remote server supports the CIFS Unix Extensions, 
this setting will be ignored unless the assignment of the user ID is 
forced.</whatsthis>
+-      <default>false</default>
++      <default>true</default>
+     </entry>
+     <entry name="UserId" type="String">
+       <whatsthis>This is the user ID (a number) that the files and 
directories of the mounted share will have. If you are using the CIFS 
filesystem under Linux and the remote server supports the CIFS Unix Extensions, 
this setting will be ignored unless the assignment of the user ID is 
forced.</whatsthis>
+@@ -25,7 +25,7 @@
+     <entry name="UseGroupId" type="Bool">
+       <label>Group ID:</label>
+       <whatsthis>This is the group ID (a number) that the files and 
directories of the mounted share will have. If you are using the CIFS 
filesystem under Linux and the remote server supports the CIFS Unix Extensions, 
this setting will be ignored unless the assignment of the group ID is 
forced.</whatsthis>
+-      <default>false</default>
++      <default>true</default>
+     </entry>
+     <entry name="GroupId" type="String">
+       <whatsthis>This is the group ID (a number) that the files and 
directories of the mounted share will have. If you are using the CIFS 
filesystem under Linux and the remote server supports the CIFS Unix Extensions, 
this setting will be ignored unless the assignment of the group ID is 
forced.</whatsthis>
+@@ -34,7 +34,7 @@
+     <entry name="UseFileMode" type="Bool">
+       <label>File mode:</label>
+       <whatsthis>This is the file mode that will be used for creating files. 
It must be defined in octal. In case the CIFS file system is used, this setting 
only takes effect if the server does not support the CIFS Unix 
Extensions.</whatsthis>
+-      <default>false</default>
++      <default>true</default>
+     </entry>
+     <entry name="FileMode" type="String">
+       <whatsthis>This is the filemode that will be used for creating files. 
It must be defined in octal. In case the CIFS file system is used, this setting 
only takes effect if the server does not support the CIFS Unix 
Extensions.</whatsthis>
+@@ -43,7 +43,7 @@
+     <entry name="UseDirectoryMode" type="Bool">
+       <label>Directory mode:</label>
+       <whatsthis>This is the directory mode that will be used for creating 
directories. It must be defined in octal. In case the CIFS file system is used, 
this setting only takes effect if the server does not support the CIFS Unix 
Extensions.</whatsthis>
+-      <default>false</default>
++      <default>true</default>
+     </entry>
+     <entry name="DirectoryMode" type="String">
+       <whatsthis>This is the directory mode that will be used for creating 
directories. It must be defined in octal. In case the CIFS file system is used, 
this setting only takes effect if the server does not support the CIFS Unix 
Extensions.</whatsthis>
+-- 
+cgit v1.1

diff --git a/net-misc/smb4k/smb4k-3.0.0-r1.ebuild 
b/net-misc/smb4k/smb4k-3.0.0-r1.ebuild
new file mode 100644
index 00000000000..fd64fcc60aa
--- /dev/null
+++ b/net-misc/smb4k/smb4k-3.0.0-r1.ebuild
@@ -0,0 +1,70 @@
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+KDE_HANDBOOK="forceoptional"
+inherit kde5
+
+DESCRIPTION="Advanced network neighborhood browser"
+HOMEPAGE="https://sourceforge.net/p/smb4k/home/Home/";
+
+if [[ ${KDE_BUILD_TYPE} = release ]]; then
+       SRC_URI="mirror://sourceforge/${PN}/${P}.tar.xz"
+       KEYWORDS="~amd64 ~x86"
+fi
+
+LICENSE="GPL-2"
+IUSE="plasma"
+
+DEPEND="
+       $(add_frameworks_dep kauth)
+       $(add_frameworks_dep kcompletion)
+       $(add_frameworks_dep kconfig)
+       $(add_frameworks_dep kconfigwidgets)
+       $(add_frameworks_dep kcoreaddons)
+       $(add_frameworks_dep kcrash)
+       $(add_frameworks_dep kdbusaddons)
+       $(add_frameworks_dep ki18n)
+       $(add_frameworks_dep kiconthemes)
+       $(add_frameworks_dep kio)
+       $(add_frameworks_dep kjobwidgets)
+       $(add_frameworks_dep knotifications)
+       $(add_frameworks_dep kwallet)
+       $(add_frameworks_dep kwidgetsaddons)
+       $(add_frameworks_dep kwindowsystem)
+       $(add_frameworks_dep kxmlgui)
+       $(add_frameworks_dep solid)
+       $(add_qt_dep qtdeclarative)
+       $(add_qt_dep qtgui)
+       $(add_qt_dep qtnetwork)
+       $(add_qt_dep qtprintsupport)
+       $(add_qt_dep qttest)
+       $(add_qt_dep qtwidgets)
+       net-fs/samba[cups]
+"
+RDEPEND="${DEPEND}
+       plasma? (
+               $(add_frameworks_dep plasma)
+               $(add_qt_dep qtquickcontrols2)
+       )
+"
+
+PATCHES=( "${FILESDIR}/${P}-fix-mount-readwrite-shares.patch" )
+
+src_configure(){
+       local mycmakeargs=(
+               -DINSTALL_PLASMOID=$(usex plasma)
+       )
+       kde5_src_configure
+}
+
+pkg_postinst() {
+       kde5_pkg_postinst
+       elog "Users of Samba 4.7 and above please note that for the time being,"
+       elog "the following setting has to be added to or changed in the 
[global]"
+       elog "section of the smb.conf file:"
+       elog
+       elog "[global]"
+       elog "client max protocol = NT1"
+}

Reply via email to