LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   SBo's SLiM login manager vs. Xfce (Slackware 14.0) (https://www.linuxquestions.org/questions/slackware-14/sbos-slim-login-manager-vs-xfce-slackware-14-0-a-4175423564/)

kikinovak 08-23-2012 04:47 AM

SBo's SLiM login manager vs. Xfce (Slackware 14.0)
 
Hi,

On one of my machines, I have Slackware 14.0RC2 with Xfce. Until now, I've always more or less used GDM as login manager, but I want to try something new (following a general "the-less-GNOME-the-better" idea).

I added the according stanza in /etc/rc.d/rc.4 to start SLiM, switched manually to init4 and got the SLiM connection window OK.

But when I try to login with my user, I only get a brief "Failed to execute login command", and then there's the SLiM window again.

So what's the thing to do after a stock SLiM installation?

kikinovak 08-23-2012 04:53 AM

I did find something that works, sort of.

Edit my users' ~/.xinitrc like this:

Code:

exec startxfce4
After this, login works OK. Don't know if this is quite orthodox. I reckon all I have to do from here is put this .xinitrc file in /etc/skel for all future users to be able to login.

Correct me if I'm wrong... or if this seems too unorthodox.

Konchdrone 08-23-2012 04:53 AM

Hello,

Have you tried running xwmconfig again? I had to do that when I used slim and it solved the problem.

kikinovak 08-23-2012 05:15 AM

Quote:

Originally Posted by Konchdrone (Post 4761910)
Hello,

Have you tried running xwmconfig again? I had to do that when I used slim and it solved the problem.

No, won't do. But I sense it's time to finally do some RTFM about the innards of SLiM.

diwljina 08-23-2012 06:20 AM

I haven't tried Slim on SW 14, but I think shutdown and restart wont work with XFCE. Something about new PolicyKit. But please do let us know how that went.

yenn 08-23-2012 07:05 AM

Quote:

Originally Posted by kikinovak (Post 4761909)
After this, login works OK. Don't know if this is quite orthodox. I reckon all I have to do from here is put this .xinitrc file in /etc/skel for all future users to be able to login.

Correct me if I'm wrong... or if this seems too unorthodox.

SLiM simply execute .xinitrc, so you have to configure it somehow. You can put it in /etc/skel or tell every future user to run xwmconfig. I prefer xwmconfig, because it sets everything automatically.

'exec startxfce' seems to work (as you stated), but my auto-generated .xinitrc (by xwmconfig) looks like this:

Code:

# Slackware -current (14RC2)
# prepare environment - Xresources, Xmodmap, ...
# [...]

########################################################################
##  Start xfce Desktop Environment                                    ##
########################################################################

if [ -z "$DESKTOP_SESSION" -a -x /usr/bin/ck-launch-session ]; then
  exec ck-launch-session dbus-launch --exit-with-session /usr/bin/startxfce4
else
  exec dbus-launch --exit-with-session /usr/bin/startxfce4
fi


yenn 08-23-2012 07:24 AM

Quote:

Originally Posted by diwljina (Post 4761979)
I haven't tried Slim on SW 14, but I think shutdown and restart wont work with XFCE. Something about new PolicyKit. But please do let us know how that went.

I guess XFCE internally use D-Bus and ConsoleKit to reboot and shutdown (http://pifostap.org.ua/blog/2011/12/...down-dbus.html). In -current (few changelogs before 14.0 RC's) every window manager got updated .xinitrc so it now starts D-Bus (for DE-independent auto-mounting deamons).

kikinovak 08-23-2012 10:05 AM

OK, I did quite a lot of experimenting, and I got it right finally. I started from SBo's SlackBuild script and made a few - essentially cosmetic - alterations to it.

The trick here was to run 'xwmconfig' as simple user, of course. Which generated a nice ~/.xinitrc. Now everything works fine, logout and reboot buttons work with Xfce, and I have built a nice custom login splash for my "Microlinux Enterprise Desktop".

clifford227 08-23-2012 10:15 AM

I tried Slim recently, but it seemed to take more time and effort to get through to the desktop.

Like most pretty things, there's usually a cost involved..

kikinovak 08-23-2012 11:32 AM

Quote:

Originally Posted by clifford227 (Post 4762214)
I tried Slim recently, but it seemed to take more time and effort to get through to the desktop.

Like most pretty things, there's usually a cost involved..

I'd compare it to the NVidia driver. When you don't know how to install it, you can spend a whole afternoon pulling your hair out. But when you know it, it's done in less than two minutes, and it's dead easy.

1) Install SBo's slim, as it comes. Use 'sbopkg' maybe.

2) Edit /etc/rc.d/rc.4 and add the stanza you can find in README.Slackware in SBo's build.

3) As a normal user, run 'xwmconfig' and choose your desktop environment (Xfce, WindowMaker, ...). This will create a ~/.xinitrc file that JustWorks(tm).

4) Eventually, set initdefault to 4 in /etc/inittab if you haven't already done that.

5) Enjoy.

SLiM is easily themable. There's an excellent HOWTO on the site.

kikinovak 08-23-2012 12:44 PM

And since we just initiated the Slackware Documentation Project, I just published a more detailed explanation there.

http://docs.slackware.com/howtos:slim

Enjoy.

yars 10-02-2012 12:31 PM

Thanks to kikinovak, your thread and link in the post #11 is helpful to me.
I can add the a small patch, which changes location of the manpages from default /usr/share/man to /usr/man. Most of the Slackware packages have this. Thanks and sorry for my english.
The patch:
Code:

zcat mandir.fix.patch.gz
*** ./CMakeLists.txt.orig    2012-09-29 07:43:20.287147436 +0400
--- ./CMakeLists.txt    2012-09-29 07:43:09.370146787 +0400
***************
*** 24,30 ****
  set(CMAKE_INSTALL_PREFIX "/usr/local" CACHE PATH "Installation Directory")
  set(PKGDATADIR "${CMAKE_INSTALL_PREFIX}/share/slim")
  set(SYSCONFDIR "/etc")
! set(MANDIR "${CMAKE_INSTALL_PREFIX}/share/man")
 
  set(SLIM_DEFINITIONS)
  if(${CMAKE_SYSTEM_NAME} MATCHES "FreeBSD" OR
--- 24,30 ----
  set(CMAKE_INSTALL_PREFIX "/usr/local" CACHE PATH "Installation Directory")
  set(PKGDATADIR "${CMAKE_INSTALL_PREFIX}/share/slim")
  set(SYSCONFDIR "/etc")
! set(MANDIR "${CMAKE_INSTALL_PREFIX}/share/man" CACHE PATH "Installation Directory")
 
  set(SLIM_DEFINITIONS)
  if(${CMAKE_SYSTEM_NAME} MATCHES "FreeBSD" OR

Though maybe I'm just not very good at programming, and you can do without this patch?
UPD: This is for SLiM version 1.3.4, and you want to change SlackBuild follow:
Code:

cmake \
  -DCFLAGS="$SLKCFLAGS" \
  -DCMAKE_CXX_FLAGS="$SLKCFLAGS" \
  -DUSE_PAM=${USE_PAM} \
  -DCMAKE_INSTALL_PREFIX=/usr \
  -DCMAKE_BUILD_TYPE=$ARCH-slackware-linux \
  -DMANDIR:PATH=/usr/man



All times are GMT -5. The time now is 08:02 PM.