(please CC me on replies, I'm not subscribed to the list)

Hi list,

Some developers here were requesting an update to coffeescript 1.9.1, I
went looking for a packaged version and found out that it has already
been merged in your team's git repo. I tried building this, but it
doesn't quite work as is. Attached below are two patches that allow the
package to build successfully.

>From 34c630f6c06f2a9b55950dc1ff3b101625244239 Mon Sep 17 00:00:00 2001
From: Arto Jantunen <vi...@debian.org>
Date: Tue, 10 Mar 2015 13:24:06 +0200
Subject: [PATCH 1/2] Switch build-dep from libjs-underscore to node-underscore

---
 debian/control | 2 +-
 debian/rules   | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/debian/control b/debian/control
index 6e68060..dd98b71 100644
--- a/debian/control
+++ b/debian/control
@@ -10,7 +10,7 @@ Build-Depends: cdbs (>= 0.4.106~),
  dh-buildinfo,
  nodejs (>= 0.6.19~dfsg1-3~),
  node-uglify (>= 2.2),
- libjs-underscore,
+ node-underscore,
  help2man
 Standards-Version: 3.9.6
 Vcs-Git: git://git.debian.org/collab-maint/coffeescript.git
diff --git a/debian/rules b/debian/rules
index ee0aba3..ed5554a 100755
--- a/debian/rules
+++ b/debian/rules
@@ -50,7 +50,7 @@ DEB_UPSTREAM_CRUFT_COPY = lib extras
 # TODO: add build:parser when jison is available in Debian
 # TODO: add build:ultraviolet when ruby-uv is in Debian
 # TODO: compile docs when docco is in Debian
-CDBS_BUILD_DEPENDS += , node-uglify (>= 2.2), libjs-underscore
+CDBS_BUILD_DEPENDS += , node-uglify (>= 2.2), node-underscore
 # Provide "cake" as "cake.coffeescript" to peacefully coexist with cakephp
 cake = cake.coffeescript
 build/$(pkg):: debian/stamp-build
-- 
2.1.4

>From 6fd899510f2a23c8efe04c924971aa7bcd99d2a3 Mon Sep 17 00:00:00 2001
From: Arto Jantunen <vi...@debian.org>
Date: Tue, 10 Mar 2015 13:24:58 +0200
Subject: [PATCH 2/2] Remove extras/jsl.conf from examples, it no longer exists

---
 debian/rules | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/debian/rules b/debian/rules
index ed5554a..38cf9a4 100755
--- a/debian/rules
+++ b/debian/rules
@@ -41,7 +41,7 @@ CDBS_SUGGESTS_$(pkg) = libjs-$(pkg), coffeescript-doc
 CDBS_SUGGESTS_libjs-$(pkg) = coffeescript
 CDBS_PROVIDES_coffeescript = node-coffeescript
 
-DEB_INSTALL_EXAMPLES_$(pkg) += examples/* extras/jsl.conf
+DEB_INSTALL_EXAMPLES_$(pkg) += examples/*
 
 # put aside upstream-shipped autogenerated files during build
 DEB_UPSTREAM_CRUFT_COPY = lib extras
-- 
2.1.4

Sadly even with these applied the package doesn't work, failing with the
following traceback:

/usr/bin/coffee 

module.js:340
    throw err;
          ^
Error: Cannot find module '../../bin/coffee'
  at Function.Module._resolveFilename (module.js:338:15)
  at Function.require.resolve (module.js:384:19)
  at Object.<anonymous> 
(/usr/lib/coffee-script/lib/coffee-script/register.js:52:22)
  at Object.<anonymous> 
(/usr/lib/coffee-script/lib/coffee-script/register.js:66:4)
  at Module._compile (module.js:456:26)
  at Object.Module._extensions..js (module.js:474:10)
  at Module.load (module.js:356:32)
  at Function.Module._load (module.js:312:12)
  at Module.require (module.js:364:17)
  at require (module.js:380:17)
  at Object.exports.register 
(/usr/lib/coffee-script/lib/coffee-script/coffee-script.js:201:12)
  at Object.module.exports.start 
(/usr/lib/coffee-script/lib/coffee-script/repl.js:173:20)
  at Object.exports.run 
(/usr/lib/coffee-script/lib/coffee-script/command.js:79:32)
  at Object.<anonymous> (/usr/bin/coffee:3:59)
  at Module._compile (module.js:456:26)
  at Object.Module._extensions..js (module.js:474:10)
  at Module.load (module.js:356:32)
  at Function.Module._load (module.js:312:12)
  at Function.Module.runMain (module.js:497:10)
  at startup (node.js:119:16)
  at node.js:906:3

Apparently something goes wrong with the search path when looking for
the modules, but my understanding of the node module system is somewhat
limited. I'd greatly appreciate any help with solving this.

-- 
Arto Jantunen
_______________________________________________
Pkg-javascript-devel mailing list
Pkg-javascript-devel@lists.alioth.debian.org
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/pkg-javascript-devel

Reply via email to