57 lines
2.8 KiB
Diff
57 lines
2.8 KiB
Diff
|
## fixed bugs:
|
||
|
## - http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=404563
|
||
|
## - http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=404555
|
||
|
diff -ruN dfsbuild.orig/dfsbuild-0.99.2/Bootloader/Grub.hs dfsbuild/dfsbuild-0.99.2/Bootloader/Grub.hs
|
||
|
--- dfsbuild.orig/dfsbuild-0.99.2/Bootloader/Grub.hs 2006-04-20 00:10:11.000000000 +0200
|
||
|
+++ dfsbuild/dfsbuild-0.99.2/Bootloader/Grub.hs 2007-01-02 00:56:45.000000000 +0100
|
||
|
@@ -40,8 +40,11 @@
|
||
|
|
||
|
grub_generic env =
|
||
|
do createDirectory (targetdir env ++ "/boot/grub") 0o755
|
||
|
- grubfiles <- glob "/lib/grub/*/*"
|
||
|
- safeSystem "cp" $ ["-rv"] ++ grubfiles ++ [targetdir env ++ "/boot/grub/"]
|
||
|
+ -- since etch (Debian 4.0) grub files are located in /usr/lib instead of /lib
|
||
|
+ grubfiles_pre_etch <- glob "/lib/grub/*/*"
|
||
|
+ grubfiles_since_etch <- glob "/usr/lib/grub/*/*"
|
||
|
+ safeSystem "cp" $ ["-rv"] ++ grubfiles_pre_etch ++ grubfiles_since_etch ++
|
||
|
+ [targetdir env ++ "/boot/grub/"]
|
||
|
menuText <- grubMenu env
|
||
|
writeFile (targetdir env ++ "/boot/grub/menu.lst") menuText
|
||
|
|
||
|
diff -ru dfsbuild.orig/dfsbuild-0.99.2/Actions/Mirror.hs dfsbuild/dfsbuild-0.99.2/Actions/Mirror.hs
|
||
|
--- dfsbuild.orig/dfsbuild-0.99.2/Actions/Mirror.hs 2006-04-20 00:10:11.000000000 +0200
|
||
|
+++ dfsbuild/dfsbuild-0.99.2/Actions/Mirror.hs 2007-01-01 22:09:26.000000000 +0100
|
||
|
@@ -33,7 +33,7 @@
|
||
|
archargs ++ debugargs ++ ["-d", suite, targetdir env, mirror]
|
||
|
-- Next, copy them into the mirror.
|
||
|
codename <- getCodeName
|
||
|
- (targetdir env ++ "/var/cache/bootstrap/Release")
|
||
|
+ (targetdir env ++ "/var/cache/bootstrap/")
|
||
|
dm $ "Codename for this is " ++ codename
|
||
|
mapM_ (\x -> handle (\_ -> return ()) (createDirectory x 0o755))
|
||
|
[mirrordir, mirrordir ++ "/conf"]
|
||
|
diff -ru dfsbuild.orig/dfsbuild-0.99.2/Utils.hs dfsbuild/dfsbuild-0.99.2/Utils.hs
|
||
|
--- dfsbuild.orig/dfsbuild-0.99.2/Utils.hs 2006-04-20 00:10:11.000000000 +0200
|
||
|
+++ dfsbuild/dfsbuild-0.99.2/Utils.hs 2007-01-01 22:40:34.000000000 +0100
|
||
|
@@ -16,6 +16,7 @@
|
||
|
import MissingH.ConfigParser
|
||
|
import MissingH.Cmd
|
||
|
import System.IO.Unsafe
|
||
|
+import System.IO.Error
|
||
|
import Text.Regex
|
||
|
import MissingH.Path.FilePath
|
||
|
import System.Directory(doesFileExist)
|
||
|
@@ -72,7 +73,11 @@
|
||
|
|
||
|
getCodeName :: FilePath -> IO String
|
||
|
getCodeName fp =
|
||
|
- do c <- readFile fp
|
||
|
+ do c_old <- System.IO.Error.catch (readFile (fp ++ "Release"))
|
||
|
+ (\e -> if System.IO.Error.isDoesNotExistError e then return "" else ioError e)
|
||
|
+ c_new <- System.IO.Error.catch (readFile (fp ++ "_dists_._Release"))
|
||
|
+ (\e -> if System.IO.Error.isDoesNotExistError e then return "" else ioError e)
|
||
|
+ c <- if length(c_old) > 0 then return c_old else return c_new
|
||
|
let cr = mkRegex "Codename: ([a-z]+)"
|
||
|
case matchRegex cr c of
|
||
|
Just [cn] -> return cn
|