~ubuntu-branches/ubuntu/precise/nodejs/precise

« back to all changes in this revision

Viewing changes to debian/patches/node_addon-paths-and-ev_multiplicity.patch

  • Committer: Bazaar Package Importer
  • Author(s): Jérémy Lal
  • Date: 2010-08-20 11:49:04 UTC
  • mfrom: (7.1.6 sid)
  • Revision ID: james.westby@ubuntu.com-20100820114904-lz22w6fkth7yh179
Tags: 0.2.0-1
New upstream release

Show diffs side-by-side

added added

removed removed

Lines of Context:
8
8
 
9
9
--- a/tools/wafadmin/Tools/node_addon.py
10
10
+++ b/tools/wafadmin/Tools/node_addon.py
11
 
@@ -8,7 +8,7 @@
12
 
 @feature('node_addon')
13
 
 @before('apply_bundle')
14
 
 def init_node_addon(self):
15
 
-       self.default_install_path = '${PREFIX_NODE}/lib/node/libraries'
16
 
+       self.default_install_path = '${PREFIX_NODE}/lib/nodejs'
17
 
        self.uselib = self.to_list(getattr(self, 'uselib', ''))
18
 
        if not 'NODE' in self.uselib: self.uselib.append('NODE')
19
 
        self.env['MACBUNDLE'] = True
20
 
@@ -22,23 +22,21 @@
21
 
 
22
 
 def detect(conf):
23
 
   join = os.path.join
24
 
-  abspath = os.path.abspath
25
 
-  wafadmin = abspath(join(os.path.dirname(__file__), '..'))
26
 
-  libnode = abspath(join(wafadmin, '..'))
27
 
-  lib = abspath(join(libnode, '..'))
28
 
-  prefix = abspath(join(lib, '..'))
29
 
+  prefix = '/usr'
30
 
+  lib = join(prefix, 'lib')
31
 
 
32
 
   conf.env['PREFIX_NODE'] = prefix
 
11
@@ -28,9 +28,8 @@
 
12
   lib = join(prefix, 'lib')
 
13
 
33
14
   conf.env['LIBPATH_NODE'] = lib
34
 
-  conf.env['CPPPATH_NODE'] = join(prefix, 'include/node')
35
 
+  conf.env['CPPPATH_NODE'] = join(prefix, 'include/nodejs')
 
15
-  conf.env['CPPPATH_NODE'] = join(prefix, 'include', 'node')
 
16
+  conf.env['CPPPATH_NODE'] = join(prefix, 'include', 'nodejs')
36
17
   conf.env['CPPFLAGS_NODE'] = '-D_GNU_SOURCE'
37
18
-  conf.env['CPPFLAGS_NODE'] = '-DEV_MULTIPLICITY=0'
38
19
 
39
20
   # with symbols
40
21
   conf.env.append_value('CCFLAGS', ['-g'])
41
 
   conf.env.append_value('CXXFLAGS', ['-g'])
42
 
-
43
 
-  found = os.path.exists(join(prefix, "bin/node"))
44
 
+  # this changes the install path of cxx task_gen
45
 
+  conf.env['LIBDIR'] = join(prefix, 'lib/nodejs')
46
 
+  
47
 
+  found = os.path.exists(join(prefix, "bin/nodejs"))
 
22
@@ -43,7 +42,7 @@
 
23
   found = os.path.exists(conf.env['NODE_PATH'])
 
24
   conf.check_message('node path', '', found, conf.env['NODE_PATH'])
 
25
 
 
26
-  found = os.path.exists(join(prefix, 'bin', 'node'))
 
27
+  found = os.path.exists(join(prefix, 'bin', 'nodejs'))
48
28
   conf.check_message('node prefix', '', found, prefix)
49
29
 
50
 
   ## On Mac OSX we need to use mac bundles
 
30
   ## On Cygwin we need to link to the generated symbol definitions
 
31
@@ -57,7 +56,7 @@
 
32
     nodePath = None
 
33
     if not os.environ.has_key('NODE_PATH'):
 
34
         if not os.environ.has_key('HOME'):
 
35
-            nodePath = join(get_prefix(), 'lib', 'node')
 
36
+            nodePath = join(get_prefix(), 'lib', 'nodejs')
 
37
         else:
 
38
             nodePath = join(os.environ['HOME'], '.node_libraries')
 
39
     else:
 
40
@@ -70,4 +69,4 @@
 
41
         prefix = os.path.abspath(os.path.join(os.path.dirname(__file__), '..', '..', '..', '..'))
 
42
     else:
 
43
         prefix = os.environ['PREFIX_NODE']
 
44
-    return prefix
 
45
\ No newline at end of file
 
46
+    return prefix