SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
hi,
since much applications in slackware like Firefox, or TV application don't ship with the default installation i have to compile them and moreover create a package so that is easy to update and install/unistall.I know the existance of linuxpackages.net but there they dont supply the Slack.Build script so you have to trust the binary that you get..
So what user,group,world permisions should i give ????
(kinda very general right ? :P )
I work like a normal user.So when i install e.g. Firefox i should "chown to root:root" and just then give the world r-x ???
Or should i "chown to user:users" so that i don't have any problems while i work ?? that is risky i believe because if a user gains access to me as a user though this program he may infect it and I execute the same program another time as root i may be compomised.
I dont want to discuss what happens if he gains access as a root::we allo know
The above questions apply better to maybe Slackware Administration or in general linux administration so is there any Free E-book,web-site,resource out there that deal with this matter ???
Except from Slackware book, slackware linux unleashed 3rd edition and Running linux 4th edition O'Reilly.
The permissions/ownership applied when you "make install" are usually suitable. I don't think I've ever had to change them for a "./configure && make && make install"-type package.
Get it from -current, it's just a Slack friendly repackaged version of the official binaries.
2) Permissions
Never use chmod. Ownership is usually root.root, except for binaries in /usr/bin or /usr/local/bin or /bin, which are root.bin (same goes for the /sbin's). Let the "make install deal" with the permissions, but use DESTDIR to point to somewhere you can repackage from (run "make install DESTDIR=/tmp/package-whatever")
3) SlackBuild's
I suggest writing your own SlackBuild's if you will be frequently rebuilding a package. (You will have to run them as root though).
Originally posted by Nobber The permissions/ownership applied when you "make install" are usually suitable. I don't think I've ever had to change them for a "./configure && make && make install"-type package.
well mostly i want to create packages thats why i am asking so many things.
Without packages after a lot of installations && upgrades it's gonna be a chaos inside my /usr/local/* :P
Quote:
Originally posted by cathectic 1) Firefox
Get it from -current, it's just a Slack friendly repackaged version of the official binaries.
2) Permissions
Never use chmod. Ownership is usually root.root, except for binaries in /usr/bin or /usr/local/bin or /bin, which are root.bin (same goes for the /sbin's). Let the "make install deal" with the permissions, but use DESTDIR to point to somewhere you can repackage from (run "make install DESTDIR=/tmp/package-whatever")
3) SlackBuild's
I suggest writing your own SlackBuild's if you will be frequently rebuilding a package. (You will have to run them as root though).
i saw the firefox 1.0.3 @ current but no SlackBuild at source tree.
But firefox 1.0.3 has a critical bug, i dont know if it affect linux though :P
I've read about the DESTDIR and i am going to take a look to the permissions assigned by "make install".
I have to check SlackBuild scripts to have a more general approach so that can start to make my own ones later
Do permissions differ i you run "./configure && make" as a root and not as a user ?
Last edited by small_boy22; 05-13-2005 at 11:02 AM.
Originally posted by keefaz chown -R root:root your entire package directory then create the package
(or use -c option for makepkg but this is not the Volkerding way)
What is the Volkerding way ??? I though he supplied to us the tools that he uses to create packages
Mozilla Firefox SlackBuild's - For 1.0.4, update the version in the SlackBuild to 1.0.4, and replace all occurrences of 1.0.3 with 1.0.4 in mozilla-firefox-simple.diff.gz (you'll also need to grab the correct Firefox from Mozilla's FTP, *don't* use the Firefox installer package).
SlackBuild's:
Pat uses SlackBuild scripts to build the packages, and that's it. The only 'tools' you need are the basic utilities for manipulating files.
A SlackBuild script always runs as root. It:[list=1][*]Extracts the tar package as root (the chown root.root is run on the source files, *not* the resulting files from a "make install")[*]Runs ./configure (if /usr/local is the default install path, it uses --prefix=/usr)[*]make[*]make install DESTDIR=/tmp/<program_name>[*]Strip binaries (remove unnecessary debugging symbols, etc from the binaries to reduce their size)[*]Gzip the man pages (reduce size)[*]Create a /usr/doc/<program_name>-<version> containing ChangeLog, README, TODO, NEWS, etc...[*]Run "makepkg -l y -c n" and dump the finished package to /tmp[/list=1]
#!/bin/sh
CWD=`pwd`
PKG="$CWD/package-firefox"
rm -rf $PKG
VERSION=1.0.4
ARCH=i686
BUILD=1ron
mkdir -p $PKG/usr/lib $PKG/usr/bin
cd $PKG/usr/lib
tar xzfv $CWD/firefox-$VERSION.tar.gz
cd $PKG/usr/bin
ln -s ../lib/firefox/firefox ./firefox
mkdir -p $PKG/usr/share/pixmaps
cp $CWD/Firefox.png $PKG/usr/share/pixmaps/Firefox.png
chown -R root:root $PKG
chown root.bin $PKG/usr/lib/firefox/firefox-bin
mkdir -p $PKG/usr/share/applications
#create firefox.desktop
cat << _EOF_ > $PKG/usr/share/applications/firefox.desktop
[Desktop Entry]
Type=Application
Encoding=UTF-8
Name=Firefox
GenericName=
Comment=
Icon=/usr/share/pixmaps/Firefox.png
TryExec=firefox
Exec=firefox
Terminal=0
Categories=GNOME;KDE;GTK;Application;Network;
_EOF_
mkdir -p $PKG/install
#create slack-desc
cat << _EOF_ > $PKG/install/slack-desc
# HOW TO EDIT THIS FILE:
# The "handy ruler" below makes it easier to edit a package description. Line
# up the first '|' above the ':' following the base package name, and the '|' on
# the right side marks the last column you can put a character in. You must make
# exactly 11 lines for the formatting to be correct. It's also customary to
# leave one space after the ':'.
|-----handy-ruler------------------------------------------------------|
firefox: firefox (Mozilla Firefox Web browser)
firefox:
firefox: This project is a redesign of the Mozilla browser component written
firefox: using the XUL user interface language. Firefox empowers you to
firefox: browse faster, more safely and more efficiently than with any other
firefox: browser.
firefox:
firefox: Visit the Mozilla Firefox project online:
firefox: http://www.mozilla.org/projects/firefox/
firefox:
firefox:
_EOF_
cd $PKG
makepkg -l y -c n "$CWD"/firefox-$VERSION-$ARCH-$BUILD.tgz
#clean up
rm -r $PKG
#Optinal Install or Upgrade
cd $CWD
#installpkg firefox-$VERSION-$ARCH-$BUILD.tgz
#upgradepkg firefox-$VERSION-$ARCH-$BUILD.tgz
echo "Firefox Slackpackage Complete."
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.