Re: [Haskell-cafe] Re: Ubuntu and ghc

2008-06-05 Thread Claus Reinke
Well, that's true.  I guess what I'm really objecting to in Claus's message 
is the implication that we should always use a Haskell Installation 
Manager, even on systems with good built-in package management.


what was implied was that haskell installation manager (HIM) 
and native package managers (NPM) (where they exist) should 
collaborate, so that NPMs know how to extract dependencies 
from haskell packages, and HIM knows how to extract 
dependencies (haskell or otherwise) from NPMs.


for the NPM-calls-HIM direction, that could be dynamically
or, as in current practice, in a separate phase converting HIM
to NPM packages.

for the HIM-calls-NPM direction, that would simply present
a haskell view on the native software (ie, cabal install/list/..
negotiating with NPM). whereas, currently, if i understand
correctly, systems with NPM will have many haskell packages
under NPM control and some haskell packages under HIM
control and some haskell packages under no control whatsoever
(eg, installing tools or compilers leaves no record, necessitating
use of autoconf & co).

i'm not saying "reimplement and ignore NPMs", i'm saying
"NPMs and HIM should collaborate". if anything, that would
reduce the number of exceptions where haskell packages are 
installed without the NPM knowing about them. and i'd like

to see fewer cases where HIM forgets about what it or NPM have installed.

so, on systems with NPM, users have a choice of interface, 
but nothing bad will happen no matter whether they choose 
NPM directly or HIM as an interface to it. and haskell

book and tutorial authors only need to explain HIM, and
its commands will just work - independent of the variant 
or lack of NPM on the reader's system.


is that still objectionable?-)
claus

ps. it is a lot like using fmap, no matter what the Functor
   is, or using something like System.Process, no matter
   whether or not the OS supports that easily.

Yes, I agree we need good support for managing packages for the other 
scenarios: no system package manager, home-directory installs, no 
pre-prepared system package.  I just don't want whatever provision we make 
for these cases to replace the system package manager for global package 
installs on systems where that is well supported.


Indeed. I wholly agree.

Duncan

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: cabal and platform-independent haskell installation management (again) (Re: [Haskell-cafe] Re: Ubuntu and ghc)

2008-06-05 Thread Ketil Malde
"Claus Reinke" <[EMAIL PROTECTED]> writes:

> 1. there are no systems where "packages just work"!
>there are systems where a few people ensure that
>many people can live in such an illusion, though.

Exactly.  Integrating Cabal packages into the system package manager
is still non-trivial, and a package maintainer is necessary for this
to work.

Which is why it's rather utopian to hope that all of Hackage can be
found in even the most widely used distributions, since many of those
are way to narrow in scope for somebody to take on the work of
providing package management.  I bet some aren't even maintained, and
possibly don't work with current GHC or Cabal.

But I digress.

> - it isn't sufficient to worry about installation management,
>one has to worry about integration, lifetime and uninstall
>management as well. in short, maintain the dependency
>graphs over any of "install"/"upgrade"/"uninstall".

There is an important difference between Hackage and, say, Ubuntu, and
that is that the latter does releases.  If I use a particular Ubuntu
version, I get a particular GHC version, and a particular version of
some dozens of libraries and applications.  They are all compiled with
that GHC version, tested, and can to a reasonable degree, be expected
to work together.  Sometimes they don't, but the good news is that a
zillion other users are in the same boat (well, even for Haskell, it's
probably dozens, at least), and chances are the bug will be fixed.

If I upgrade to the next version of Ubuntu, I can reasonably expect
all packages to be updated to current versions, and some to be
replaced. 

In contrast, for my packages on Hackage, I'm reasonably
certain it worked on my particular system at the time I uploaded
it.  And dependencies are none too specific - the package might work
with different versions than I compiled with or not.

I think for Cabal to provide the convenience currently afforded by
system package managers, you'd need to do Hackage-wide releases, and
test everything together.  This is a lot of work, but not impossible,
it's what Gnome and KDE does, for instance.  It would probably make
things easier for system package maintainers, too.

Alternatives, like pessimistic dependencies: only exact versions in
cabal files, will probably make you end up with installing every
version of every  package, and still suffer dependency hell.
Exhaustive testing of all version combinations, which will
require a lot of computational resources, even if it could be done
automatically.

--

I generally install most libraries from the distribution's repository,
and let the system worry about updates etc.  I think it's also an
advantage if my programs avoid depending on stuff that's not in the
repo, since it's likely to be is less widely used and maintained.

I install manually the stuff I need the distribution doesn't provide,
and also when I want to look at the code, or just have the latest and
greatest.  I tend to get the darcs version, rather than the Hackage
one, though.  The downside is that I need to reinstall these when I do
a system upgrade, but it's rare enough that it doesn't bother me much,
and chances are that more libraries are provided with my distribution
for every release, so a cleanup is probably a good idea anyway.

Anyway, this works pretty well for me - if I'm living on an illusion,
it's at least a good one. :-)

-k
-- 
If I haven't seen further, it is by standing in the footprints of giants
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: cabal and platform-independent haskell installation management (again) (Re: [Haskell-cafe] Re: Ubuntu and ghc)

2008-06-04 Thread Darrin Thompson
On Wed, Jun 4, 2008 at 10:14 AM, Claus Reinke <[EMAIL PROTECTED]> wrote:
> - it isn't sufficient to worry about installation management,
>   one has to worry about integration, lifetime and uninstall
>   management as well. in short, maintain the dependency
>   graphs over any of "install"/"upgrade"/"uninstall".
>

It's sufficient to worry about the problem at hand. Everything you've
mentioned can be done incrementally once the depsolver is happy.

After that it's quite likely that the set of people who care about
lifetimes and integration stuff will intersect with the people who
want to work on said stuff.

--
Darrin
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: cabal and platform-independent haskell installation management (again) (Re: [Haskell-cafe] Re: Ubuntu and ghc)

2008-06-04 Thread Duncan Coutts

On Wed, 2008-06-04 at 15:14 +0100, Claus Reinke wrote:
> > I think that's fundamentally the wrong approach.  We shouldn't have to 
> > build a "Haskell installation manager".  Would you also want installation 
> > managers for Perl, Python, Ruby, C, C++, etc. each with their own different 
> > user interfaces and feature sets?  I think not - you want a single package 
> > manager for the whole system from which you can install/uninstall libraries 
> > for any language.
> > 
> > This is something that Windows gets completely wrong.  Why do I have twelve 
> > icons in my status bar all representing little programs that are running in 
> > the background checking for updates to their own bits of software?  Why on 
> > earth do I have a Printer Driver Update Manager?  And I'd be wondering the 
> > same thing about a "Haskell installation manager": installation and 
> > dependencies are not something specific to Haskell.
> 
> why then do we have ghc-pkg, or cabal? surely the native package
> managers should handle all that?
> 
> there are (at least) two dimensions of uniformity: across different
> kind of software on a single kind of system, and with a single kind 
> of software across different kinds of system. platform-specific
> package managers hide the software-specific notions of package
> dependency maintainence, haskell-specific package managers
> hide the platform-specific notions of package dependency 
> maintainence. 
> 
> there is no need for platform- and haskell-specific tools to be 
> entirely separate or in conflict with each other: where both exist, 
> one can be a view on the other (if you are on linux-of-the-day, 
> you can use its package manage, independent of whether your
> packages are haskell or lisp; and if you are using haskell, you
> should be able to use its package manager, independent of
> whether you are on unix-variant-of-today or on 
> unix-variant-of-yesterday).
> 
> there seems to be a lot of confusion here, some of us not 
> understanding the issues because we happen to be using
> systems where "everything just works", others among us
> not understanding the issues because we happen to be
> using systems where "such things would never work anyway",
> and yet others insisting on "i'll do it my way, so i know what
> works" (and then, of course, there are those who are
> actively working on improving the situation who will see
> my criticism as constructive, i hope!-).
> 
> 1. there are no systems where "packages just work"!
> there are systems where a few people ensure that
> many people can live in such an illusion, though.

Yes indeed! :-)

> 2. systems with native package manager software still
> need help from haskell-specific toolchains (unless
> you want the human package managers on those
> systems to code all haskell-specific dependencies
> by hand).

Yes. As an illustration: gentoo has an "haskell-cabal.eclass" that
interfaces between ebuilds and cabal as the build manager and there is a
tool to generate ebuilds that use the haskell-cabal.eclass from .cabal
descriptions (so we get correct deps automatically).

> 3. systems without native package managers (or perhaps
> i should say: systems on which users with unix background
> traditionally avoid getting acquainted with the details and 
> usage of whatever might pass as installation management 
> on those systems) are still in *very* wide-spread use, 
> and if haskell users on those systems are left out in the
> rain, haskell developers will not be able to support those
> systems. this limits the user and application base of haskell
> on those systems, making haskell less relevant than it could be.

Eg Windows, OSX, Solaris.

> 4. haskell enables programming at a very high level of 
> abstraction, with fairly good support for mostly platform
> independent code. but that code needs to be installed, 
> and integrated with dependencies and dependents, and 
> the integrated haskell installations needs to be maintained.
> and that should "just work", even if the developer is on
> (1;2) and the user is on (3), or vice versa, or if developers
> and users are on different flavours of (1;2) or (3).
> 
> with these clarifications out of the way, my interpretation 
> of cabal was that it set out to provide two things
> 
> (A) a uniform platform-independent interface to such a 
> haskell package installation manager.
> (B) a uniform platform-independent toolchain to support
> such a haskell package installation manager.

I guess so.

> on systems in the (1;2) class, human package managers 
> would use (B) to integrate haskell packages into the native
> package management software, so users might never even
> encounter cabal.

As in my example with the gentoo haskell packages above.

>  even so, (A) might offer a haskell-specific
> view on the general platform package management (when 
> you want to see the haskell gui libs rather than all 

Re: [Haskell-cafe] Re: Ubuntu and ghc

2008-06-04 Thread Duncan Coutts

On Wed, 2008-06-04 at 15:25 +0200, Achim Schneider wrote:

> Well, you have a point but still don't have one. Many of gentoo's
> haskell .ebuilds are seriously outdated, eg. wxhaskell still depends on
> ghc 6.4. See "Damnit, we need a CPAN"
> 
> The haskell overlay features about 240 packages from alex to yi,
> hackage currently lists 596 packages.

You may be interested to know I just tried to install 564 packages from
hackage using cabal-install (others excluded due to missing or
inconsistent dependencies). Of those, 156 failed to install (direct
failure or because they depended on another package that failed). I now
have 157 programs installed in ~/.cabal/bin and ghc-pkg take two and a
half seconds to tell me that I have 454 libraries installed (some were
installed previously via portage).

Duncan

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


cabal and platform-independent haskell installation management (again) (Re: [Haskell-cafe] Re: Ubuntu and ghc)

2008-06-04 Thread Claus Reinke
I think that's fundamentally the wrong approach.  We shouldn't have to 
build a "Haskell installation manager".  Would you also want installation 
managers for Perl, Python, Ruby, C, C++, etc. each with their own different 
user interfaces and feature sets?  I think not - you want a single package 
manager for the whole system from which you can install/uninstall libraries 
for any language.


This is something that Windows gets completely wrong.  Why do I have twelve 
icons in my status bar all representing little programs that are running in 
the background checking for updates to their own bits of software?  Why on 
earth do I have a Printer Driver Update Manager?  And I'd be wondering the 
same thing about a "Haskell installation manager": installation and 
dependencies are not something specific to Haskell.


why then do we have ghc-pkg, or cabal? surely the native package
managers should handle all that?

there are (at least) two dimensions of uniformity: across different
kind of software on a single kind of system, and with a single kind 
of software across different kinds of system. platform-specific

package managers hide the software-specific notions of package
dependency maintainence, haskell-specific package managers
hide the platform-specific notions of package dependency 
maintainence. 

there is no need for platform- and haskell-specific tools to be 
entirely separate or in conflict with each other: where both exist, 
one can be a view on the other (if you are on linux-of-the-day, 
you can use its package manage, independent of whether your

packages are haskell or lisp; and if you are using haskell, you
should be able to use its package manager, independent of
whether you are on unix-variant-of-today or on 
unix-variant-of-yesterday).


there seems to be a lot of confusion here, some of us not 
understanding the issues because we happen to be using

systems where "everything just works", others among us
not understanding the issues because we happen to be
using systems where "such things would never work anyway",
and yet others insisting on "i'll do it my way, so i know what
works" (and then, of course, there are those who are
actively working on improving the situation who will see
my criticism as constructive, i hope!-).

1. there are no systems where "packages just work"!
   there are systems where a few people ensure that
   many people can live in such an illusion, though.

2. systems with native package manager software still
   need help from haskell-specific toolchains (unless
   you want the human package managers on those
   systems to code all haskell-specific dependencies
   by hand).

3. systems without native package managers (or perhaps
   i should say: systems on which users with unix background
   traditionally avoid getting acquainted with the details and 
   usage of whatever might pass as installation management 
   on those systems) are still in *very* wide-spread use, 
   and if haskell users on those systems are left out in the

   rain, haskell developers will not be able to support those
   systems. this limits the user and application base of haskell
   on those systems, making haskell less relevant than it could be.

4. haskell enables programming at a very high level of 
   abstraction, with fairly good support for mostly platform
   independent code. but that code needs to be installed, 
   and integrated with dependencies and dependents, and 
   the integrated haskell installations needs to be maintained.

   and that should "just work", even if the developer is on
   (1;2) and the user is on (3), or vice versa, or if developers
   and users are on different flavours of (1;2) or (3).

with these clarifications out of the way, my interpretation 
of cabal was that it set out to provide two things


(A) a uniform platform-independent interface to such a 
   haskell package installation manager.

(B) a uniform platform-independent toolchain to support
   such a haskell package installation manager.

on systems in the (1;2) class, human package managers 
would use (B) to integrate haskell packages into the native

package management software, so users might never even
encounter cabal. even so, (A) might offer a haskell-specific
view on the general platform package management (when 
you want to see the haskell gui libs rather than all gui libs).


on systems in the (3) class, users and developers would
interface with (A/B) directly, for lack of a better alternative.

and developers/users in the (4) class would simply use
(A/B), without having to check whether they are "real"
or just a view on the platform-specific software. it is this
cross platform view of software development that i'm
most interested in (i'm one of those who use bash, vim,
opera, and haskell, no matter whether i'm on windows,
solaris, or whatever, and the cross-platform availability
of those tools has saved me many a headache;-).

returning to my earlier message, it seems that my 
concerns were mai

Re: [Haskell-cafe] Re: Ubuntu and ghc

2008-06-04 Thread Ross Paterson
On Wed, Jun 04, 2008 at 02:22:07PM +0100, Duncan Coutts wrote:
> As I see it we need both. We need to make it easy to translate cabal
> packages into distro packages. We do have tools to do that at the moment
> for Gentoo, Debian and Fedora. I'm sure they could be improved.
> 
> However we cannot expect all distros (esp Windows) to have all packages
> that are on hackage at all times. That's where it makes sense to have a
> tool like cabal-install as a secondary package manager. There's also the
> fact that most distro package managers do not handle unprivileged
> per-user installations very well.

cabal-install probably needs extra features to work in this way.
If you ask it to install a package and its prerequisites, each of
those packages will either be
(1) already installed,
(2) absent but available from the native package manager,
(3) available from hackage.
In the second case you'd probably want to break out of cabal-install to
install the pre-packaged ones before building the new ones.
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Re: Ubuntu and ghc

2008-06-04 Thread Duncan Coutts

On Wed, 2008-06-04 at 11:33 +0100, Simon Marlow wrote:
> Claus Reinke wrote:
> 
> > - i don't want to have to remove anything explicitly, becausethat 
> > would mean bypassing the haskell installation managers
> > - i would want to see a single haskell installation manager
> >for each system,
> 
> I think that's fundamentally the wrong approach.  We shouldn't have to 
> build a "Haskell installation manager".  Would you also want installation 
> managers for Perl, Python, Ruby, C, C++, etc. each with their own different 
> user interfaces and feature sets?  I think not - you want a single package 
> manager for the whole system from which you can install/uninstall libraries 
> for any language.

As I see it we need both. We need to make it easy to translate cabal
packages into distro packages. We do have tools to do that at the moment
for Gentoo, Debian and Fedora. I'm sure they could be improved.

However we cannot expect all distros (esp Windows) to have all packages
that are on hackage at all times. That's where it makes sense to have a
tool like cabal-install as a secondary package manager. There's also the
fact that most distro package managers do not handle unprivileged
per-user installations very well.

A further issue is that the dependencies that Haskell packages have are
pretty complex and more so than can actually be expressed in some distro
package systems. In particular Gentoo portage. Binary distros are better
off in that respect since the deps of binary haskell packages are
considerably simpler.

Duncan

___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


RE: [Haskell-cafe] Re: Ubuntu and ghc

2008-06-04 Thread Re, Joseph (IT)
Not sure about it's current state, but a friend was working on this
until he graduated recently: http://www.acm.uiuc.edu/projects/Wipt

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Ketil Malde

> Aren't there any usable third-party package managers for windoze?

The most usable one I've seen is Steam from Valve, IIRC.  It'd be cool
if Haskell packages were provided this way.

-k


NOTICE: If received in error, please destroy and notify sender. Sender does not 
intend to waive confidentiality or privilege. Use of this email is prohibited 
when received in error.
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe


Re: [Haskell-cafe] Re: Ubuntu and ghc

2008-06-04 Thread Duncan Coutts

On Wed, 2008-06-04 at 14:54 +0200, Ketil Malde wrote:

> > You have a point, though, and I wouldn't mind at all cabal-install
> > being integrated into portage,
> 
> I'm not too familiar with portage, but I think a better solution is to
> provide tools to automatically generate packages for the various
> systems. 

Yeah, we've got one for gentoo/portage called hackport. That's why we
have so many packages in the haskell overlay. We didn't do them all
manually :-)

> How would you specify dependencies on non-haskell components in a
> portable way?

Unfortunately the same packages get named differently on different
package systems, eg "zlib", "libzlib", "libzlib-dev" etc. It's probably
possible to use reasonably standard names and map to the distro-names.
Doing that reliably is not going to be easy though.

Duncan



___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe



Re: [Haskell-cafe] Re: Ubuntu and ghc

2008-06-04 Thread Ketil Malde
Achim Schneider <[EMAIL PROTECTED]> writes:

Caveat: I have only a vague grasp on what exactly is being criticized
here - using a modern Linux distribution, tons of packages are
available, and almost all issues Claus point out seem to be taken care
of - at least as far as I can see.

> Well, then there are developers who don't want to do .ebuilds, .rpms
> for 20 distributions, .debs for 20 distributions, .cabs... Meaning that
> if you have a project with 5 developers using 3 1/2 distributions, you
> will have a hard time installing.

I think you should either require your developers to use the system
that is provided to them, or be able and willing to maintain their own
system.  Most large Linux distributions seem to come with lots of
Haskell-related stuff nowadays - 139 packages on my Ubuntu install
(divide by something close to 3, as most library stuff comes in -dev,
-doc and -prof variants).

> You have a point, though, and I wouldn't mind at all cabal-install
> being integrated into portage,

I'm not too familiar with portage, but I think a better solution is to
provide tools to automatically generate packages for the various
systems.  How would you specify dependencies on non-haskell components
in a portable way?

> Aren't there any usable third-party package managers for windoze?

The most usable one I've seen is Steam from Valve, IIRC.  It'd be cool
if Haskell packages were provided this way.

> Maybe gentoo should start to do binary releases, too, superseding
> debian and any other distribution.

Yeah, that'll happen. :-)

-k
-- 
If I haven't seen further, it is by standing in the footprints of giants
___
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe