In article <[EMAIL PROTECTED]>,
 Corrin Lakeland <[EMAIL PROTECTED]> wrote:

> However, running fink without root really isn't that hard.

Yeah, I wrote a FAQ about that over a year ago. Of course you have an 
updated hack.

---------------- Begin Forwarded Message ----------------
Date:        2001-10-18 21:08
From:        Ashley Yakeley, [EMAIL PROTECTED]
To:          Fink-Developers List, [EMAIL PROTECTED]
Subject:     [Fink-devel] Running Fink Non-Root FAQ

Running Fink Non-Root FAQ

1. What's that?
By hacking fink, you can get it to build packages non-root. You then 
install packages as root (or non-root, see #5).

2. Why might I want to do that?
Well, build scripts are long and complicated, and sometimes bad stuff 
can sneak in. I've discovered a number of bugs doing this, mostly 
scripts that install directly into the fink directory (%p), rather than 
the destination directory (%i). More specific reasons include:
a. you want to make sure your fink package doesn't do bad things at 
build time
b. you want to keep tight control of your system and don't trust build 
scripts not to do stuff like put files in the wrong place, muck about 
with NetInfo, etc.

3. Why might I want to not do that?
a. Some packages won't build, perhaps because they do a 'chown'. Mysql, 
for instance.
b. All your files will be installed owned by the building user, rather 
than root. This means the building user inappropriately has the right to 
fiddle with the files.
c. If you install packages as root, you can't auto-install dependent 
packages when building non-root.
d. It's a hack, it's not officially supported.

4. How do I do it?
Edit the main fink script, e.g.
$ pico `which fink`

Find these two lines:

# are we root?
if ($> != 0) {

Edit the second line like this:

# are we root?
if (0) {

That's it! Fink will now run non-root, but should also work exactly the 
same when running root. You might want to create a special user just for 
building.

5. Can I set up my fink directory so I can also install non-root?
Probably, but packages that do stuff such as edit the NetInfo database 
will have to be installed as root.

6. How do I rebuild a package without reinstalling it?
Do 'fink rebuild' non-root and ignore the error when it tries to 
reinstall it.

7. How might this situation be improved in the future?
If fink can run under fakeroot, it should be able to do everything it 
needs to do without being able to do anything it shouldn't do (more or 
less). Unfortunately, fakeroot has not yet been ported to Darwin. I 
tried a while ago, but ran up against differing semaphore models. But if 
you know about that sort of thing, you should have a go...

-- 
Ashley Yakeley, Seattle WA


_______________________________________________
Fink-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/fink-devel


----------------- End Forwarded Message -----------------

-- 
Ashley Yakeley, Seattle WA



-------------------------------------------------------
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
_______________________________________________
Fink-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/fink-devel

Reply via email to