From 0ab048b6557ea0a337b96f5d0558694a237dfab8 Mon Sep 17 00:00:00 2001 From: Eric Andersen Date: Thu, 13 Nov 2003 10:19:01 +0000 Subject: Update the debian packaging for use in a standalone uClibc system, rather than being a subordinate lib under a glibc based system. -Erik --- debian/fixlinks | 81 --------------------------------------------------------- 1 file changed, 81 deletions(-) delete mode 100755 debian/fixlinks (limited to 'debian/fixlinks') diff --git a/debian/fixlinks b/debian/fixlinks deleted file mode 100755 index 110a5e313..000000000 --- a/debian/fixlinks +++ /dev/null @@ -1,81 +0,0 @@ -#!/usr/bin/perl -w -# vi: set ts=4: - - -@LINKS=`find . -type l|LC_ALL=C xargs ls -l`; - -#print @LINKS; - -#$debug = 1; - -while($_ = shift @LINKS){ - chomp; - my ($perm,$nlinks,$owner,$group,$size,$month,$day,$year,$file) = - split(' ', $_, 9); - my $link; - - if($perm =~ m/^l/){ - ($relfile, $link) = split(' -> ', $file); - } - - # chop off leading . in $file - $file = $relfile; - $file =~ s/^\.//; - - if($perm =~ m/^l/){ - my @pathcomponents = split('/', $file); - my @linkcomponents = split('/', $link); - - if($link =~ m/^\//){ - @newcomponents = @linkcomponents; - }else{ - @newcomponents = @pathcomponents; - - # chop off filename - pop(@newcomponents); - - while($comp = shift @linkcomponents){ - $debug && print "path: ",join(':',@newcomponents)," -- $comp -- ", join(':',@linkcomponents),"\n"; - - if($comp eq ""){ - # ignore - }elsif($comp eq ".."){ - pop(@newcomponents); - }else{ - push @newcomponents,$comp; - } - } - } - - if($newcomponents[0] eq ""){ - shift(@newcomponents); - } - if($pathcomponents[0] eq ""){ - shift(@pathcomponents); - } - - #print "from ",join('/',@pathcomponents),"\n"; - #print "to ",join('/',@newcomponents),"\n"; - - if($newcomponents[0] eq $pathcomponents[0]){ - $debug && print $newcomponents[0],", ",$pathcomponents[0]; - $debug && print "should be relative\n"; - while($newcomponents[0] eq $pathcomponents[0]){ - shift(@newcomponents); - shift(@pathcomponents); - } - while(@pathcomponents > 1){ - shift(@pathcomponents); - unshift(@newcomponents,".."); - } - }else{ - $debug && print "should be absolute\n"; - unshift(@newcomponents,""); - } - $newlink=join('/',@newcomponents); - print "ln -sf $newlink $relfile\n"; - unlink($relfile); - symlink($newlink,$relfile); - } -} - -- cgit v1.2.3