diff options
-rw-r--r-- | Setup.hs | 17 | ||||
-rw-r--r-- | debian/changelog | 1 | ||||
-rw-r--r-- | git-annex-shell.hs | 13 | ||||
-rw-r--r-- | git-annex.cabal | 4 |
4 files changed, 17 insertions, 18 deletions
@@ -1,12 +1,27 @@ {- cabal setup file -} import Distribution.Simple +import Distribution.Simple.LocalBuildInfo +import Distribution.Simple.Setup import System.Cmd +import System.FilePath import qualified Build.Configure as Configure -main = defaultMainWithHooks simpleUserHooks { preConf = configure } +main = defaultMainWithHooks simpleUserHooks + { preConf = configure + , instHook = install + } configure _ _ = do Configure.run Configure.tests return (Nothing, []) + +install pkg_descr lbi userhooks flags = do + r <- (instHook simpleUserHooks) pkg_descr lbi userhooks flags + _ <- rawSystem "ln" ["-sf", "git-annex", + bindir installDirs </> "git-annex-shell"] + return r + where + installDirs = absoluteInstallDirs pkg_descr lbi $ + fromFlag (copyDest defaultCopyFlags) diff --git a/debian/changelog b/debian/changelog index abc3ae512..73b4f31b0 100644 --- a/debian/changelog +++ b/debian/changelog @@ -8,6 +8,7 @@ git-annex (3.20120407) UNRELEASED; urgency=low Damerau-Levenshtein edit distance, just as git does. This adds a build dependency on the haskell edit-distance library. * Renamed diskfree.c to avoid OSX case insensativity bug. + * cabal now installs git-annex-shell as a symlink to git-annex. -- Joey Hess <joeyh@debian.org> Sun, 08 Apr 2012 12:23:42 -0400 diff --git a/git-annex-shell.hs b/git-annex-shell.hs deleted file mode 100644 index 08c1f9664..000000000 --- a/git-annex-shell.hs +++ /dev/null @@ -1,13 +0,0 @@ -{- git-annex-shell main program - - - - Copyright 2012 Joey Hess <joey@kitenet.net> - - - - Licensed under the GNU GPL version 3 or higher. - -} - -import System.Environment - -import GitAnnexShell - -main :: IO () -main = run =<< getArgs diff --git a/git-annex.cabal b/git-annex.cabal index df4001189..6b1ebb42e 100644 --- a/git-annex.cabal +++ b/git-annex.cabal @@ -36,10 +36,6 @@ Executable git-annex Other-Modules: Utility.Touch C-Sources: Utility/libdiskfree.c -Executable git-annex-shell - Main-Is: git-annex-shell.hs - C-Sources: Utility/libdiskfree.c - Test-Suite test Type: exitcode-stdio-1.0 Main-Is: test.hs |