How do you think these Ruby libraries got written?
This is the crucial point. Take it a step further and ask yourself why? There are 10x as many potential library writers for Ruby/Python etc because it's 10x easier to get up to speed in those languages.
If you want to put Clojure in the spotlight don't use it to build redundant, half-assed solutions to problems that are already solved. Use it to solve a new problem. Companies like Runa and BackType and Flightcaster are setting the right example here.
The point I was trying to make: someone out there was the first to use Ruby for a web app, and went out of her way to write a library to do something that web app needed to do. This functionality was already present in PHP and Perl, so there was no reason for them to build those libraries, right?
Someone has to get the basics in place. Trying to do a web 3.0 startup that may or may not succeed, using clojure, will have absolutely no impact on getting people to use clojure for web development.
"There are 10x as many potential library writers for Ruby/Python etc because it's 10x easier to get up to speed in those languages."
Why? Clojure is smaller, simpler and more consistent than either Python or Ruby.
Why? Clojure is smaller, simpler and more consistent than either Python or Ruby.
Forth is even simpler than Clojure. A language is not necessarily easy to learn just because it has a small, simple, orthogonal core. Understanding how bricks are made doesn't automatically make it easier to build a house. It's the difficulty of the macro-concepts that makes the most difference and most people find imperative programming and mutable state and infix syntax easier to handle than declarative programming and immutability and prefix syntax. Lisp has been more powerful than the competition for most of its history but it's never been popular.
"It's the difficulty of the macro-concepts that makes the most difference and most people find imperative programming and mutable state and infix syntax easier to handle than declarative programming and immutability and prefix syntax."
If by "empirical" you mean rigorous, double-blind style studies then obviously there aren't any just as there aren't really any for any serious programming language design questions.
The overwhelming (and it really is overwhelming) market preference is for imperative, infix languages with rich syntax. The extraordinary claim that this is purely circumstantial is the one that requires extraordinary proof.
No one who has taught functional programming to students has complained of higher failure rates. University students, high school students, middle school students, disadvantaged inner-city middle school students, elementary school, pre-elementary school (what do you think Logo is?).
In America, there is also overwhelming market preference for junk food. It doesn't mean junk food is better for you.
I don't think there's really much of an analogy between programming languages and food.
So what's your explanation then? If functional languages are no more difficult to learn and are more powerful why are they not used? Why have Python and Ruby flourished while Lisp and ML remain academic obscurities?
I still say the burden of proof is on the FP advocates. If you want to claim that everybody is doing it wrong you should have a pretty strong case.
"I don't think there's really much of an analogy between programming languages and food."
Programming languages are cultural, not technical, artifacts. For reasons why one language is used by more programmers at a given point in time than another you need to turn to sociology. Lisp has some clearly superior technical ideas, which is why it has continued to be used and expanded for the last 50 years, and why all the other languages you mention (Python, Ruby, ML) drew ideas there. On the other hand, a language like Perl (and as Python and Ruby will eventually be) is briefly popular, but has no compelling technical features or metaprogramming facilities for people to continue to use and expand it when another shiny new language comes along.
Programming languages are cultural, not technical, artifacts.
Sociology is a factor but that's wildly overstating the case. The fact that people prefer to borrow from Lisp rather that adopt it is telling. Many programmers are aware enough of Lisp to take inspiration from it but choose not to use the language itself.
There's a subtext of arrogance in the claims FP and Lisp advocates make about the popularity of various programming languages. In my experience most of those people don't actually write much code. I gave up on the Common Lisp community years ago after realizing that it was full of people that would rather sit around discussing how things should be than actually building something.
A language like Perl ... has no compelling technical features or metaprogramming facilities for people to continue to use and expand it when another shiny new language comes along.
See the CPAN and especially modules such as PPI, Moose, and Devel::Declare.
And that still hasn't stopped the Perl 5 community from feelings of inferiority (see http://blogs.perl.org/users/ovid/2010/03/perl-5-is-dying-a-f... for example), and more importantly it hasn't stopped Perl 6 from being built. Which is a shame, because I would much rather have seen something like Perl on Rails, or in any case work going towards building on all the stuff already there in CPAN instead of duplicating all that work in PHP and then Python and then Ruby and then maybe even Perl 6 sometime this decade.
Why does Perl 5 need a Rails? Despite the existence of Rails, Perl 5 is still more widely used than Ruby. (Perl 5 and Ruby 1 came out around the same time.)
If you thought that was a joke, you're still missing the point.
I suffer no illusion that their sales numbers have any correlation to the popularity or efficacy of a technology. Their Ruby book sales crashed in 2007, for example.
Who is writing new projects in Perl 5?
I know of many, many new projects written in Perl 5. So far this year I've worked on three and have another later in the year.
If you want to put Clojure in the spotlight don't use it to build redundant, half-assed solutions to problems that are already solved. Use it to solve a new problem. Companies like Runa and BackType and Flightcaster are setting the right example here.