5 $filename or die "no filename";
7 $directory = $filename;
8 $directory =~ s/.tar.gz$//g;
11 mkdir("$directory/tmp/");
13 chdir("$directory/tmp/") or die;
14 system("tar -zxvf ../../$filename") and die;
15 system("find . -type f -exec mv {} .. \\;") and die;
17 system("find . -type d -exec rmdir {} \\; 2> /dev/null");
19 $c = 'find . \( -name "*.cc" -or -name "*.h" -or -name "*.c" \) -exec cp {} {}.orig \;';
23 system("patch < ../xpdf-changes.patch 2>&1 | grep -i failed");
26 system("ln -s $directory xpdf");
36 if test "x\$VERSION" = "x";then
37 select V in stable latest;do VERSION="\$V";break;done
39 if test "x\$VERSION" = "xstable";then
40 echo "Switching to stable version"
43 elif test "x\$VERSION" = "xlatest";then
44 echo "Switching to latest version"
51 system("chmod a+x switch");