puppylinux-woof-CE / woof-CE

woof - the Puppy builder
GNU General Public License v2.0
396 stars 282 forks source link

Some symlinks broken with transition to git #3

Closed 01micko closed 10 years ago

01micko commented 10 years ago

The run >> tmp symlink is broken in the skeleton. Will probably have to go through and see if there are more. How do we handle this?

mavrothal commented 10 years ago

The run >> tmp symlink is broken in the skeleton. Will probably have to go through and see if there are more. How do we handle this?

I do not know if there is any special woof code to handle the run symlink but just ln -sf /tmp run should be fine. no?

01micko commented 10 years ago

Yeah, I'd make it absolute though, like

cd / ln -sf tmp run cd -

So one for merge2out?

Ha.. we need a mailing list by the look of it eh? As they follow...

Mick

On Thu, Nov 14, 2013 at 9:40 PM, mavrothal notifications@github.com wrote:

The run >> tmp symlink is broken in the skeleton. Will probably have to go through and see if there are more. How do we handle this?

I do not know if there is any special woof code to handle the run symlink but just ln -sf /tmp run should be fine. no?

— Reply to this email directly or view it on GitHubhttps://github.com/puppylinux-woof-CE/woof-CE/issues/3#issuecomment-28477477 .

mavrothal commented 10 years ago

Yeah, I'd make it absolute though, like

cd / ln -sf  tmp run cd -

So one for merge2out?

Why in merge2out? As far as I understand links as generated regardless if they are valid or invalid at the moment of linking. As long as the target is there they will link. If you "ln -sf /tmp run" in woof-code/rootfs-skeleton will be lined to your running system's /tmp while there and in the puppy /tmp when build

Ha.. we need a mailing list by the look of it eh? As they follow... 

Yes, will also reduce "noise" ;-) Cheers

Mick

On Thu, Nov 14, 2013 at 9:40 PM, mavrothal notifications@github.com wrote:

The run >> tmp symlink is broken in the skeleton. Will probably have to go through and see if there are more. How do we handle this?

I do not know if there is any special woof code to handle the run symlink but just ln -sf /tmp run should be fine. no?

— Reply to this email directly or view it on GitHubhttps://github.com/puppylinux-woof-CE/woof-CE/issues/3#issuecomment-28477477

.

— Reply to this email directly or view it on GitHub.

dimkr commented 10 years ago

Git handles symlinks, so we can add them to the skeleton.

01micko commented 10 years ago

I fixed it in my local tree and pushed. Closing

01micko commented 10 years ago

Also fixed the broken symlinks in /usr/bin pointing to X11R7

01micko commented 10 years ago

Damn.. there's find . -type l -name '*' >/tmp/symlinks;wc -l /tmp/symlinks 372 /tmp/symlinks

372 affected symlinks! They'll all have to be fixed before we can get back to square 1

01micko commented 10 years ago

I created a 'testing' branch and pushed the fixed symlinks to it. I'll do a sanity check (build) and if it's ok merge with master.

01micko commented 10 years ago

Merged testing to master. Closing.

KarlGodt commented 10 years ago

just to say that ln -sf on directories is not a good idea - it often put links into the new folder .

ln -sf works good on files but not on folders .

With directories you would need to remove the directory first .

mkdir /tmp/TEST cd /tmp/TEST mkdir run tmp ls -1 * run:

tmp: ln -sf tmp run ls -1 * run: tmp

tmp:

01micko commented 10 years ago

Yes, looks like that's what happened Karl. I had already fixed the directory symlinks because they were obvious and committed the change. I then discovered all the other broken links so did a "find" for symlinks and redirected to a list. I then ran a 'while read line' loop on the list fixing all the symlinks, and of course the dir ones existed and what you describe occurred. It doesn't affect a build though, because woof does a check for invalid symlinks in 3builddistro and deletes them.