LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
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 02-26-2006, 12:54 PM   #1
gravityworks
LQ Newbie
 
Registered: Jun 2004
Posts: 18

Rep: Reputation: 0
slackware build script questions


Hi All

i've been playing around with transparency in kde,and decided to give it a try in xfce..thing is the xfce that's in current doesn't have transparency enabled,so i'm going to add that feature into patrick's build script..thing is do i have to invoke his build scripts as user,su to root or login as root..reason i ask is because i've read that they should be invoked as root..but the packages a get at linux packages and the packages you get from the slackware site are not owned by root..and if you built them as root they would be..So a bit confused about how all this is handled...if this has been brought up before(i did a search and couldn't find anything) then please direct me to that thread...


Thanks in Advance..

Last edited by gravityworks; 02-26-2006 at 12:57 PM.
 
Old 02-26-2006, 01:43 PM   #2
uselpa
Senior Member
 
Registered: Oct 2004
Location: Luxemburg
Distribution: Slackware, OS X
Posts: 1,507

Rep: Reputation: 47
You need to login as root or `su -` to root, otherwise `makepkg` will not be in your path.
 
Old 02-26-2006, 03:07 PM   #3
dunric
Member
 
Registered: Jul 2004
Distribution: Void Linux, former Slackware
Posts: 498

Rep: Reputation: 100Reputation: 100
Quote:
..but the packages a get at linux packages and the packages you get from the slackware site are not owned by root..and if you built them as root they would be..So a bit confused about how all this is handled...
  • important is contents of a package and all files are and have to be owned by root. Subdirectories for binaries have to be group-owned by bin.
  • SlackBuild scripts are designed to be built as root but you may in most cases build them under normal user but then you have to change manualy ownership to root or just use simply fakeroot tool.
Quote:
You need to login as root or `su -` to root, otherwise `makepkg` will not be in your path.
To have makagepkg in PATH you need not to su or log in as root. Just add /sbin with
Code:
export PATH=/sbin:${PATH}
f.E.
 
Old 02-26-2006, 03:25 PM   #4
uselpa
Senior Member
 
Registered: Oct 2004
Location: Luxemburg
Distribution: Slackware, OS X
Posts: 1,507

Rep: Reputation: 47
from http://www.slackbook.org/html/packag...-packages.html:
Quote:
So what is a SlackBuild script? SlackBuild scripts are executable shell scripts that you run as root to configure, compile, and create Slackware packages.
Of course you can get around that, but all doc I have ever found on the subject recommends running SlackBuilds as root.
 
Old 02-26-2006, 08:19 PM   #5
gravityworks
LQ Newbie
 
Registered: Jun 2004
Posts: 18

Original Poster
Rep: Reputation: 0
Thanks for the help uselpa and dunric it's all alot clearer to me..

Much appreciated
 
Old 02-27-2006, 01:38 PM   #6
jong357
Senior Member
 
Registered: May 2003
Location: Columbus, OH
Distribution: DIYSlackware
Posts: 1,914

Rep: Reputation: 52
Quote:
Originally Posted by dunric
Subdirectories for binaries have to be group-owned by bin.
They don't have to be. That's just some really old standard that Pat can't seem to break the habbit of doing. If you look at your group file, root is a member of bin. No harm in chowning root.root on bin directories unless it's something like cups where your going to bork existing perms by doing so. For that reason alone, it's best not to mess with bin perms at all.
 
Old 02-27-2006, 07:17 PM   #7
theoffset
Member
 
Registered: Aug 2005
Location: Guadalajara, Jal, Mexico
Distribution: Slackware Linux
Posts: 211

Rep: Reputation: 31
Well, he seems to have tried to get away from his habbit...

Code:
# This is mostly a useless concept, but I'll keep with it for now...
chown root:bin $PKG/usr/bin/*
(taken from openldap-client.SlackBuild in Slackware-current)
 
Old 02-27-2006, 08:02 PM   #8
MS3FGX
LQ Guru
 
Registered: Jan 2004
Location: NJ, USA
Distribution: Slackware, Debian
Posts: 5,852

Rep: Reputation: 361Reputation: 361Reputation: 361Reputation: 361
All I did to compile Composite support was recompile XFWM with the Composite option, make a package out of it with checkinstall, and install that over the original Slackware package.

I could send it to you if you want. Unless you are trying to learn, which is always good.

Last edited by MS3FGX; 02-27-2006 at 08:05 PM.
 
Old 02-27-2006, 08:37 PM   #9
shepper
Member
 
Registered: Mar 2003
Location: Dry, Dusty and Conservative
Distribution: OpenBSD, Debian Wheezy/Jessie
Posts: 449

Rep: Reputation: 33
I was also looking at the xfce.Slackbuild script to see if it would be possible to add the --with-shutdown-style=sudo when compiling xfce4-session-4.2.3. The Slackware and Linuxpackages builds do not seem to respond as follows to allow user shudown.


Quote:
15. How do I enable the shutdown/reboot action in the session-manager logout dialog?

You have to allow the user(s) to execute $installdir/libexec/xfsm-shutdown-helper with sudo. Please install sudo, and refer to xfce4-session and sudo documentation.

user ALL=(ALL) NOPASSWD: /usr/libexec/xfsm-shutdown-helper
Can one just add the compile flag "--with-shutdown-style=sudo" in the SlackBuild script or do you need to tease out the xfce4-session-4.2.3 compile since it is the only option with this compile flag?

The other thing I noticed is the that Xfce source code comes in one giant tarball that contains all the listed packages. It looks like these previously were downloaded individually. I think the script could handle extracting the giant tarball and then the subsequent tarballs.

I am reading a book on shell scripting but am not to the level needed implement these proposed modifications.
I added the modifications on my own compile and they work well and because it is done through sudo I think it is relatively secure. I know KDE and Gnome(formerly) would allow users to shutdown. If it could be done it might be a good thing to submit to Pat V. to see if he wants to incorporate for the xfce build in the upcoming *.0 release.
 
Old 02-27-2006, 08:42 PM   #10
gbonvehi
Senior Member
 
Registered: Jun 2004
Location: Argentina (SR, LP)
Distribution: Slackware
Posts: 3,145

Rep: Reputation: 53
The changes that are explained on your quote referes to sudo configuration and not xfce itself. You've to edit /etc/sudoers file or use visudo (it's basically vi editing /etc/sudoers with some syntax checking) adding that line.
It's not good to allow anybody to shutdown the computer, and you've to change "user" to the correct user you want, that means, edit sudoers for each user, or make a special group. I don't think that would fit in a default installation.
 
Old 02-27-2006, 08:56 PM   #11
shepper
Member
 
Registered: Mar 2003
Location: Dry, Dusty and Conservative
Distribution: OpenBSD, Debian Wheezy/Jessie
Posts: 449

Rep: Reputation: 33
I am not sure I explained myself well

Quote:
user ALL=(ALL) NOPASSWD: /usr/libexec/xfsm-shutdown-helper
is a cut and paste from my visudo except I edited my user name to "user"

When I had the appropriate line in visudo I would not get the reboot/shutdown options when I logged out of xfce with Slackware 10.2 or Linuxpackages(basically used Pats Slackbuild) xfce packages. I assumed that it was because "--with-shutdown-style=sudo" had not been invoked in the xfce4-session compile. If one can add xfsm-shutdown-helper in visudo and have the standard 10.2 Slackware package provide user shutdown then I must have made a syntax error in my visudo and basically compiled my own xfce desktop needlessly.
 
Old 02-28-2006, 04:08 AM   #12
c.m.klaij
Member
 
Registered: Dec 2004
Location: netherlands
Distribution: suse, slackware, dsl, debian
Posts: 68

Rep: Reputation: 15
I guess you should add % in front of the line...
 
Old 02-28-2006, 10:28 AM   #13
dunric
Member
 
Registered: Jul 2004
Distribution: Void Linux, former Slackware
Posts: 498

Rep: Reputation: 100Reputation: 100
Quote:
Originally Posted by jong357
They don't have to be. That's just some really old standard that Pat can't seem to break the habbit of doing. If you look at your group file, root is a member of bin. No harm in chowning root.root on bin directories unless it's something like cups where your going to bork existing perms by doing so. For that reason alone, it's best not to mess with bin perms at all.
I should rather use word 'should' intead of 'have' because in this way is packaged whole Slackware. Chowning group to bin is recommended in Fosdem document about Slackware package system too. On the other hand I would agree this is mostly due to historical reasons and now it doesn't have of much importance.
 
Old 03-01-2006, 10:01 PM   #14
gravityworks
LQ Newbie
 
Registered: Jun 2004
Posts: 18

Original Poster
Rep: Reputation: 0
Quote:
Originally Posted by MS3FGX
All I did to compile Composite support was recompile XFWM with the Composite option, make a package out of it with checkinstall, and install that over the original Slackware package.

I could send it to you if you want. Unless you are trying to learn, which is always good.

Hey thanks for the offer MS3FGX,appreciate it..but i already recompiled xfce with composite support..and yes learning is my main reason for messing with the slackbuilds..really want to get the hang of them..checkinstall is great( i use it alot) but i'd like to learn to roll my own..again thanks for the offer..
 
  


Reply


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
Easy Build script system gnashley Slackware 2 01-17-2006 09:05 AM
question about the XFCE build script win32sux Slackware 13 11-28-2005 03:58 PM
vsftpd build script 0.o Slackware 4 06-06-2005 11:58 AM
Script to build Virtualusers lapthorn Linux - Software 0 10-19-2004 05:39 AM
lycoris build 66 questions heuer007 Linux - Distributions 0 01-16-2003 02:02 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 01:03 PM.

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
Open Source Consulting | Domain Registration