summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBernard Cafarelli <voyageur@gentoo.org>2007-12-14 14:22:17 +0000
committerBernard Cafarelli <voyageur@gentoo.org>2007-12-14 14:22:17 +0000
commitb41dda2e49fc223547f86d8daf9014e148ec0070 (patch)
tree3fc266e87131aabb78bde40b8a2ac68d73d0d014 /net-misc
parentSymlink mf from mf-nowin when X useflag is off, some scripts expect it to exi... (diff)
downloadgentoo-2-b41dda2e49fc223547f86d8daf9014e148ec0070.tar.gz
gentoo-2-b41dda2e49fc223547f86d8daf9014e148ec0070.tar.bz2
gentoo-2-b41dda2e49fc223547f86d8daf9014e148ec0070.zip
Fix mounting smb shares
(Portage version: 2.1.4_rc9)
Diffstat (limited to 'net-misc')
-rw-r--r--net-misc/nxserver-freenx/ChangeLog9
-rw-r--r--net-misc/nxserver-freenx/files/digest-nxserver-freenx-0.7.1-r2 (renamed from net-misc/nxserver-freenx/files/digest-nxserver-freenx-0.7.1)0
-rw-r--r--net-misc/nxserver-freenx/files/nxserver-freenx-0.7.1-samba.patch32
-rw-r--r--net-misc/nxserver-freenx/nxserver-freenx-0.7.1-r2.ebuild (renamed from net-misc/nxserver-freenx/nxserver-freenx-0.7.1.ebuild)12
4 files changed, 50 insertions, 3 deletions
diff --git a/net-misc/nxserver-freenx/ChangeLog b/net-misc/nxserver-freenx/ChangeLog
index 360f3d317c9d..753911abd4db 100644
--- a/net-misc/nxserver-freenx/ChangeLog
+++ b/net-misc/nxserver-freenx/ChangeLog
@@ -1,6 +1,13 @@
# ChangeLog for net-misc/nxserver-freenx
# Copyright 1999-2007 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-misc/nxserver-freenx/ChangeLog,v 1.39 2007/12/03 20:00:26 voyageur Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-misc/nxserver-freenx/ChangeLog,v 1.40 2007/12/14 14:22:17 voyageur Exp $
+
+*nxserver-freenx-0.7.1-r2 (14 Dec 2007)
+
+ 14 Dec 2007; Bernard Cafarelli <voyageur@gentoo.org>
+ +files/nxserver-freenx-0.7.1-samba.patch, -nxserver-freenx-0.7.1.ebuild,
+ +nxserver-freenx-0.7.1-r2.ebuild:
+ Fix mounting smb shares, thanks again Bruno Redondi in bug #202045
*nxserver-freenx-0.7.1-r1 (03 Dec 2007)
diff --git a/net-misc/nxserver-freenx/files/digest-nxserver-freenx-0.7.1 b/net-misc/nxserver-freenx/files/digest-nxserver-freenx-0.7.1-r2
index aad19a87b1b6..aad19a87b1b6 100644
--- a/net-misc/nxserver-freenx/files/digest-nxserver-freenx-0.7.1
+++ b/net-misc/nxserver-freenx/files/digest-nxserver-freenx-0.7.1-r2
diff --git a/net-misc/nxserver-freenx/files/nxserver-freenx-0.7.1-samba.patch b/net-misc/nxserver-freenx/files/nxserver-freenx-0.7.1-samba.patch
new file mode 100644
index 000000000000..01601dd966f1
--- /dev/null
+++ b/net-misc/nxserver-freenx/files/nxserver-freenx-0.7.1-samba.patch
@@ -0,0 +1,32 @@
+--- nxnode~ 2007-12-05 18:41:09.714867153 +0100
++++ nxnode 2007-12-10 18:19:20.572614463 +0100
+@@ -56,7 +56,7 @@
+ {
+ stringinstring "&$1=" "$CMDLINE" || return 1
+
+- echo "$CMDLINE" | tr "&" "\n" | egrep "^"$1"=" | awk -F= '{ VAL=$2 } END { print VAL }'
++ echo "$CMDLINE" | tr "&" "\n" | egrep "^"$1"=" | awk -F= '{ VAL=$2 } END { print VAL }' | sed 's|%24|$|'
+
+ return 0
+ }
+@@ -720,7 +720,7 @@
+ # Catch NXAGENT SMB Port (sometimes the port differs from what we got from nxserver)
+ #
+
+- if stringinstring "Info: Listening for SMB connections on port" "$line"
++ if stringinstring "Info: Listening * SMB connections on port" "$line"
+ then
+ SMBMOUNT_PORT=$(echo $line | cut -d"'" -f2)
+ echo "$SMBMOUNT_PORT" >"$USER_FAKE_HOME/.nx/C-$sess_id/scripts/mport"
+@@ -1314,8 +1314,9 @@
+ sleep 1
+ done
+ # sometimes the samba port we get from nxserver is not the right one, so let's get it from nxagent
+- port=$(cat "$USER_FAKE_HOME/.nx/C-$SERVER_NAME-$display-$sessionid/scripts/mport")
+- error=$(PASSWD="$password" $COMMAND_SMBMOUNT "//$computername/$share" "$HOME/$dir" -o username="$username,ip=127.0.0.1,port=$port" 2>&1)
++ realport=$(cat "$USER_FAKE_HOME/.nx/C-$SERVER_NAME-$display-$sessionid/scripts/mport")
++ [ -n "$realport" ] && port=$realport
++ error=$(PASSWD="$password" $COMMAND_SMBMOUNT "//$computername/$share" "$HOME/$dir" -o username="$username",ip=127.0.0.1,port=$port 2>&1)
+ if [ $? -eq 0 ]
+ then
+ $PATH_BIN/nxdialog -dialog ok -caption "NXServer Message" -message "Info: Share: '//$computername/$share' mounted on: '$HOME/$dir'" -display :$display &
diff --git a/net-misc/nxserver-freenx/nxserver-freenx-0.7.1.ebuild b/net-misc/nxserver-freenx/nxserver-freenx-0.7.1-r2.ebuild
index d13ccef56152..ade3e165ef9e 100644
--- a/net-misc/nxserver-freenx/nxserver-freenx-0.7.1.ebuild
+++ b/net-misc/nxserver-freenx/nxserver-freenx-0.7.1-r2.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2007 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/net-misc/nxserver-freenx/nxserver-freenx-0.7.1.ebuild,v 1.4 2007/11/07 09:52:51 voyageur Exp $
+# $Header: /var/cvsroot/gentoo-x86/net-misc/nxserver-freenx/nxserver-freenx-0.7.1-r2.ebuild,v 1.1 2007/12/14 14:22:17 voyageur Exp $
inherit multilib eutils
@@ -32,7 +32,8 @@ RDEPEND="${DEPEND}
media-fonts/font-misc-misc
media-fonts/font-cursor-misc
x11-apps/xauth
- x11-apps/xrdb"
+ x11-apps/xrdb
+ x11-apps/sessreg"
S=${WORKDIR}/${MY_PN}-${PV}
@@ -52,6 +53,9 @@ src_unpack() {
epatch "${FILESDIR}"/${P}-cups.patch
epatch "${FILESDIR}"/${P}-nxdialog.patch
epatch "${FILESDIR}"/${P}-nscd.patch
+ epatch "${FILESDIR}"/${P}-usession_fixes.patch
+ epatch "${FILESDIR}"/${P}-nxserver_fixes.patch
+ epatch "${FILESDIR}"/${P}-samba.patch
sed -i "/PATH_LIB=/s/lib/$(get_libdir)/g" nxloadconfig || die
sed -i "/REAL_PATH_BIN=/s/lib/$(get_libdir)/g" nxloadconfig || die
@@ -111,6 +115,8 @@ src_install() {
keepdir ${NX_SESS_DIR}/$x
fperms 0700 ${NX_SESS_DIR}/$x
done
+
+ newinitd "${FILESDIR}"/nxserver.init nxserver
}
pkg_postinst () {
@@ -119,11 +125,13 @@ pkg_postinst () {
if [[ ${ROOT} == "/" ]]; then
usermod -s /usr/bin/nxserver nx || die "Unable to set login shell of nx user!!"
usermod -d ${NX_HOME_DIR} nx || die "Unable to set home directory of nx user!!"
+ usermod -G utmp nx || die "Unable to add nx user to utmp group!!"
else
elog "If you had another NX server installed before, please make sure"
elog "the nx user account is correctly set to:"
elog " * login shell: /usr/bin/nxserver"
elog " * home directory: ${NX_HOME_DIR}"
+ elog " * supplementary groups: utmp"
fi
elog "To complete the installation, run:"