LinuxQuestions.org
Support LQ: Use code LQ3 and save $3 on Domain Registration
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices

Reply
 
Search this Thread
Old 03-26-2008, 09:15 PM   #1
icecubeflower
Member
 
Registered: Mar 2008
Location: USA
Distribution: Slackware 13.1
Posts: 304

Rep: Reputation: 33
wine


Hey I can only run pkgtool as root. So if I get the Slackware wine 9.58 package I install it as root. But then I can only execute wine if I'm root. How do I make wine available for non-root users?
 
Old 03-26-2008, 10:55 PM   #2
Peacepunk
Member
 
Registered: Apr 2006
Location: Cambodia
Distribution: Slackware 12.2 &... VirtualBox!
Posts: 51

Rep: Reputation: 16
Smile Dealing with exec permissions, setting up .wine folder.

============Dealing with Exec Permissions=============

There are several reasons why this could've happened; If you downloaded from linuxpackages.org, maybe the package has an issue, or if you compiled yourself there may be other stuff involved. Now, a self-compiled package should show up like:
-rwxr-xr-x 1 root root 2021120 2007-02-26 15:36 /usr/bin/e16
for instance (I don't have wine on this box, but e16 is something I compiled myself and use for real);

I don't know what's your level of knowledge either, so let's take it from the basics:
Code:
whereis wine
should return something like /usr/bin/wine or /usr/local/bin/wine something like that. You may even have several outputs, or the main one being a link, here follows a sample with the Gimp:
Code:
jphs@Slack266:~$ whereis gimp
gimp: /usr/bin/gimp /etc/gimp /usr/lib/gimp
 /usr/X11R6/bin/gimp /usr/bin/X11/gimp /usr/X11/bin/gimp
 /usr/share/gimp /usr/man/man1/gimp.1.gz /usr/share/man/man1/gimp.1.gz
 /usr/X11/man/man1/gimp.1.gz
I found Gimp! Good! let's check permissions:
Code:
jphs@Slack266:~$ ls /usr/bin/gimp -l
lrwxrwxrwx 1 root root 8 2008-03-26 14:40 /usr/bin/gimp -> gimp-2.4
Oooops, it's a link, it isn't the real stuff: noticed the -> gimp-2.4 thingy? Let's try again with the link's target:
Code:
jphs@Slack266:~$ whereis gimp-2.4
gimp-2: /usr/bin/gimp-2.4 /usr/X11R6/bin/gimp-2.4 /usr/bin/X11/gimp-2.4 /usr/X11/bin/gimp-2.4 /usr/include/gimp-2.0
gotcha!
now for the actual check, let's list (ls -l) its properties:
Code:
jphs@Slack266:~$ ls /usr/bin/gimp-2.4 -l
-rwxr-xr-x 1 root root 3738356 2007-10-24 16:01 /usr/bin/gimp-2.
So far, so good with my gimp at least: noticed the three X's? They mean Owner, Group AND Anybody can eXecute the application; If your wine looks like
Code:
-rwxr--r-- 1 root root 3738356 2007-10-24 16:01 /path-to-your-wine/
then you miss this feature, and you must do:
Code:
su -
[password]
chmod +x /path-to-your-wine/
&&

check that the x-for-execute parameter has been passed by doing
Code:
ls /path-to-your-wine/ -l

============Setting up the .wine folder=============

[a folder's name starting with a . is an invisible folder, don't forget to tick "show invisible folders" in your filebrowser of choice!]

Now issues with wine involves the fake C drive and where it's located; if your wine install failed to create a .wine directory in your end-user (non-root) home folder, then again there's a problem with the way wine installed itself; the poor hacker's way of dealing with that would be to, as root, copy this .wine folder from the root folder into the intended home account, and then do something as root like:
Code:
chown -R [end-username] /home/[end-username]/.wine
chgrp -R users /home/[end-username]/.wine
chmod -R 755 /home/[end-username]/.wine
To try it out, just browse your .wine folder to find notepad.exe and try to fire it up with either the proper command line like
Code:
wine /home/[end-username]/.wine/[path to notepad]/notepad.exe
or right-click-select "open with" if you are in konqueror, and even sometimes double-clicking does it (well, not for me on my Fedora workstation but others seems to be more lucky than I am).

This way you'd be sure your wine is sane from a non-root user' perspective, and you can start fighting your way trough making exe apps actually working on your 'Nix box. A general recommendation of me: do it all from within this .wine folder, copy your executables at the right place inside the fake ~/.wine/c_drive/... in a micro$oft way, including the installers for bigger softs: that is key to eliminate the "where can wine work/how make the soft believe it's in a win-box" issue. Again, that is key: your wine install may be good, but you are forced to go root because your are not working from the proper location & need to be root-ed to... be able mess around your entire hard drive!

Cheers.
If this was completely unusefull because far too obvious for you, well, sorry then, and let's say it may be worth reading for someone else with less experience

Last edited by Peacepunk; 03-26-2008 at 11:09 PM.
 
Old 03-26-2008, 11:08 PM   #3
dissociative
Member
 
Registered: Jul 2007
Posts: 36

Rep: Reputation: 15
I think that you have to run wineprefixcreate first as non-root but I'm not completely sure if this can be the solution
 
Old 03-26-2008, 11:14 PM   #4
Peacepunk
Member
 
Registered: Apr 2006
Location: Cambodia
Distribution: Slackware 12.2 &... VirtualBox!
Posts: 51

Rep: Reputation: 16
and winecfg too... first of all actually, or so I believe but it's been a loooong time since I set up my fedora box I must say...

Last edited by Peacepunk; 03-28-2008 at 03:48 AM.
 
Old 03-27-2008, 05:49 PM   #5
brodo
Member
 
Registered: Jan 2004
Location: Poland, Poznan
Distribution: Slackware current
Posts: 187

Rep: Reputation: 17
I've been succesfully using slackBuild scripts from slacky.eu site to build my own Wine packages for a long time.
It takes appr. one hour to produce a fresh package.
I did't encounter any serious problems going that way.
After upgrading or installing the package do not forget to clean a /tmp/ subdirectories used to compiling Wine and after that jump back to user account and invoke:

wine notepad.exe

to create ~/.wine subdirectory.

It is desirable to put some popular Windows *.ttf font files into ~/.wine/drive_c/windows/fonts directory.
 
Old 03-27-2008, 10:45 PM   #6
T3slider
Senior Member
 
Registered: Jul 2007
Distribution: Slackware64-14.1
Posts: 2,297

Rep: Reputation: 722Reputation: 722Reputation: 722Reputation: 722Reputation: 722Reputation: 722Reputation: 722
As a side note, it is important to make sure your 'umask' setting is 0022 -- if it's not, the permissions will be screwed up (and will probably mess with your system's permissions too). I always build packages using the command `su -c umask 0022 && ./package.SlackBuild` (I basically always use SlackBuilds, whether I write them myself or use others' SlackBuilds). This shouldn't affect a default setup, but I have my user's umask set to 0077 so only I may read my files (not that anyone else uses this PC, but oh well). However, this doesn't appear to be your problem since you didn't say that your entire system was messed up. Run `winecfg` as your normal user (I think) and *hopefully* that will clear stuff up. I agree with the above posters in that you should try and run all Windows programs from within the '~/.wine/drive_c' directory.

Good luck.
 
Old 03-28-2008, 09:51 AM   #7
rworkman
Slackware Contributor
 
Registered: Oct 2004
Location: Tuscaloosa, Alabama (USA)
Distribution: Slackware
Posts: 1,944

Rep: Reputation: Disabled
Quote:
Originally Posted by icecubeflower View Post
Hey I can only run pkgtool as root. So if I get the Slackware wine 9.58 package I install it as root. But then I can only execute wine if I'm root. How do I make wine available for non-root users?
Slackware packages are *supposed* to be installed as root. There's a VERY good reason that root privileges are required to write to the system as a whole.

If you can't execute wine as a normal user, then either your system is in bad shape, or the package you installed is bad. A good system with a good wine package will work just fine.
 
Old 03-29-2008, 05:12 PM   #8
T3slider
Senior Member
 
Registered: Jul 2007
Distribution: Slackware64-14.1
Posts: 2,297

Rep: Reputation: 722Reputation: 722Reputation: 722Reputation: 722Reputation: 722Reputation: 722Reputation: 722
Just a thought -- if you got it from linuxpackages.net, which is notorious for having poorly created packages, the permissions or ownership of the wine files may be screwed up (maybe the root directories like /bin, /usr, etc are fine but the ownership of the wine files are set to an owner on the packager's PC...or something stupid like that). Take a look at the permissions for sure and it'll tell you what went wrong (take a look at the permissions for /bin, /usr, /etc, etc. to make sure they weren't screwed up as well).
 
Old 03-30-2008, 12:49 AM   #9
icecubeflower
Member
 
Registered: Mar 2008
Location: USA
Distribution: Slackware 13.1
Posts: 304

Original Poster
Rep: Reputation: 33
Wait, if linuxpackages.net has poorly created packages then who has good ones? For Slackware.
 
Old 03-30-2008, 02:02 AM   #10
duryodhan
Senior Member
 
Registered: Oct 2006
Distribution: Slackware 12 Kernel 2.6.24 - probably upgraded by now
Posts: 1,054

Rep: Reputation: 46
slackbuilds.org
alien bob's repository
slacky.eu

I won't say linuxpackages.net has poorly created packages only ... the problem with it is that its package review is bad .. anyone is able to upload packages ... but there are quite a few people who upload packages to linuxpackages.net which are really good ... just make sure to check the package creators name.
 
  


Reply

Tags
execute, nonroot, root, wine


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Trouble running wine from src wine:error while loading shared libraries: libwine.so.1 brynjarh Linux - Newbie 2 05-28-2013 11:59 AM
Problems installing WINE on Fedora Core 6 using $yum install wine rubiks_nerd_90 Linux - Software 4 03-06-2008 09:36 AM
A wine question: Theming wine or changing wine's colour scheme PatrickMay16 General 8 12-17-2006 07:53 AM
Link targets - problems with Wine (Though not Wine specific - Wine site doesn't help) Kevjml Linux - Newbie 1 01-13-2006 08:53 AM
wine: chdir to /tmp/.wine-tom/server-306-33fca : No such file or directory Kinstonian Linux - Software 19 06-21-2003 06:16 AM


All times are GMT -5. The time now is 07:43 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration