This may belong on SuperUser, but assuming you mean "6.5.6 or later"...
Ensure that a sources entry for Squeeze (Testing) exists in /etc/apt/sources.list
:
deb-src http://http.us.debian.org/debian squeeze main contrib non-free
Run apt-get update
(as root)
Run apt-get build-dep imagemagick
(as root, this installs the build-dependencies)
Change to a directory you'll be using for building.
For the next part you can be a regular user.
Run apt-get source imagemagick
(should automatically pick up the version from Testing, currently 6.6.0)
This will download and unpack the latest source package. CD into the directory created that contains the unpacked source (imagemagick-6.6.0.4/
as of this writing).
Run fakeroot debian/rules binary
and if all goes well, cd ..
In that directory will be a set of imagemagick debs that have only build-dependencies from Lenny (i.e. you just backported imagemagick for your environment).
As root again, run dpkg -i *.deb
.
Enjoy your new packages, but remember to check for security releases periodically and rebuild as needed, as you are now outside of Debian's security release framework. You may want to consider subscribing to the debian-security-announce mailing list.
There is a better solution than m-a: dkms
It actually makes it easier to distribute external kernel modules and automatically compiles them for newer kernel-versions (think installing a new package of linux-headers).
Best Answer
The
.pkg
file is for OSX. There are some repositories that have binaries for Debian, but it is probably easiest to download and compile the code. NodeJS is updated very frequently - so most repositories have very outdated versions. You will need some development tools (compiler, etc.) to be able to build the source.You can either download the source from the Node.JS site or pull it from github. The advantage of the latter is ease of maintenance.
NodeJS:
If you wish, you can install node to a directory other than the default, by adding --prefix /path/to/install/directory to your configure line, below. (Only use one of the following, not both)
From GitHub:
From source - tarball:
NPM:
NPM is already included with recent versions of node. Verify that it is installed with npm -v. If a version is displayed, there is no need to do the step below. If the 'easy install' doesn't work for you, you can also download the code and make install.