---------- Forwarded message ---------- From: David Fox <[email protected]> Date: Thu, Jul 23, 2009 at 9:58 AM Subject: Re: Patch for haskell-devscripts to install executables into the corresponding debian package To: Joachim Breitner <[email protected]>
On Thu, Jul 23, 2009 at 9:24 AM, Joachim Breitner <[email protected]>wrote: > Hi, > > Am Donnerstag, den 23.07.2009, 08:56 -0700 schrieb David Fox: > > Packages like happy and hsx have an Executable: section in their cabal > > file which specifies the name of a binary file generated by the > > package. The attached patch to the hlibrary.mk file in > > haskell-devscripts causes it to move the executable file into the > > debian package with the same name. > > Thanks for pushing this, it might be useful. What package do you plan > this for? I only use it for the trhsx executable produced by the hsx package, and in our debianization of happy. There are already a few packages that do this in debian/rules directly > (xmonad, cpphs, hscolour, maybe others), can you test if your > haskell-devscripts breaks them? Then we would have to coordinate an > upload. It doesn't break hscolour, but that may be because the executable is called HsColour and the package is called hscolour. I'll check it out for the other packages. > > > Also, I have trouble understanding some parts of the patch: > > Where is the common-binary-fixup-arch target called? Or is it a cdbs > standard? Yes, this is a standard cdbs target. > > > What is the difference between > + cp -ax dist-ghc6/build/$${EXEC}/$${EXEC} > debian/$${DEBNAME}/usr/bin/$${EXEC}; \ > and > + install -m 755 dist-ghc6/build/$${EXEC}/$${EXEC} > debian/$${DEBNAME}/usr/bin/$${EXEC}; \ Good question! I wrote this code a long time ago and haven't looked at it since. It looks like the file may be a symlink, and this code converts it into a regular file if there is no library package. Maybe someone out there knows more about it than I. I also do not understand your comment to that target. Could you explain > it a bit more? First I will have to study the situation a bit more. > > > Note that there might be packages that install more than one executable, > but that should all go in one package, or some binaries should go to the > -dev package. Then the name based automatism does not work. Maybe it’d > be more useful to have the maintainer, in debian/rules specify a > variable > > CABAL_EXECUTABLES_FOR_packagename = exectuable1 executable2 > > and you rely on that in hlibrary.mk? This might be a good thing, though I also like the simple way it works now.
