diff options
author | Andrew Cady <d@jerkface.net> | 2019-06-25 23:14:08 -0400 |
---|---|---|
committer | Andrew Cady <d@jerkface.net> | 2019-06-25 23:14:08 -0400 |
commit | 30efc81705bb74a89f1e29c23d4a074d033ebe48 (patch) | |
tree | 73ccd4c38bf4aedec3e8913428861fb63a9c7581 | |
parent | 03a5ac7237a1ea0a6eb492958567aaf4a984c43d (diff) |
call dpkg only once for many debs
-rw-r--r-- | fsmgr.hs | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -56,9 +56,9 @@ buildRoot config@DiskImageConfig{..} finalOut = do | |||
56 | -- "Required" even if no packages are specified. When there is a parent, | 56 | -- "Required" even if no packages are specified. When there is a parent, |
57 | -- assume that this has already happened. | 57 | -- assume that this has already happened. |
58 | cmd_ "selfstrap --skip-update" (("--unpack" `consWhen` unpackOnly) ["-t", mountpoint]) packageNames | 58 | cmd_ "selfstrap --skip-update" (("--unpack" `consWhen` unpackOnly) ["-t", mountpoint]) packageNames |
59 | forM_ debs $ \pkg -> do cmd_ (AddEnv "DEBIAN_FRONTEND" "noninteractive") | 59 | when (not $ null debs) $ do |
60 | ["dpkg"] [if unpackOnly then "--unpack" else "--install"] | 60 | cmd_ (AddEnv "DEBIAN_FRONTEND" "noninteractive") |
61 | ["--root", mountpoint, pkg] | 61 | ["dpkg"] [if unpackOnly then "--unpack" else "--install"] debs |
62 | {- 2.5. install apt package cache -} | 62 | {- 2.5. install apt package cache -} |
63 | -- TODO | 63 | -- TODO |
64 | {- 3. binaries -} | 64 | {- 3. binaries -} |