]> git.pld-linux.org Git - packages/nodejs.git/blame - nodejs-shared.patch
noarch doc subpackage
[packages/nodejs.git] / nodejs-shared.patch
CommitLineData
9dc0bdad
A
1--- node-v0.10.3-o/Makefile 2013-04-03 11:30:57.000000000 -0600
2+++ node-v0.10.3/Makefile 2013-04-03 19:30:22.000000000 -0600
3@@ -54,11 +54,13 @@
1ed21df5
A
4 config.gypi: configure
5 $(PYTHON) ./configure
be06d6d0
AS
6
7-install: all
8- $(PYTHON) tools/install.py $@ $(DESTDIR)
9+install: all justinstall
10+
11+justinstall:
12+ $(PYTHON) tools/install.py install $(DESTDIR) $(LIBDIR)
13
14 uninstall:
15- $(PYTHON) tools/install.py $@ $(DESTDIR)
16+ $(PYTHON) tools/install.py $@ $(DESTDIR) $(LIBDIR)
17
18 clean:
19 -rm -rf out/Makefile node node_g out/$(BUILDTYPE)/node blog.html email.md
dc60a63b
ER
20--- node-v0.10.3/common.gypi~ 2013-04-03 20:30:57.000000000 +0300
21+++ node-v0.10.3/common.gypi 2013-04-08 15:50:00.327121152 +0300
22@@ -8,6 +8,8 @@
23 'component%': 'static_library', # NB. these names match with what V8 expects
24 'msvs_multi_core_compile': '0', # we do enable multicore compiles, but not using the V8 way
25 'gcc_version%': 'unknown',
26+ # For a shared library build, results in "libnode.so.<(soname_version)".
27+ 'soname_version%': '',
28 'clang%': 0,
29 'python%': 'python',
30
9dc0bdad
A
31--- node-v0.10.3-o/node.gyp 2013-04-03 11:30:57.000000000 -0600
32+++ node-v0.10.3/node.gyp 2013-04-03 19:30:22.000000000 -0600
1ed21df5 33@@ -67,17 +67,35 @@
be06d6d0
AS
34 'type': 'executable',
35
36 'dependencies': [
1ed21df5
A
37- 'node_js2c#host',
38+ 'libnode'
39 ],
40
41- 'include_dirs': [
42- 'src',
43- 'tools/msvs/genfiles',
44- 'deps/uv/src/ares',
45- '<(SHARED_INTERMEDIATE_DIR)' # for node_natives.h
46+ 'conditions': [
47+ [ 'node_shared_libuv=="false"', {
48+ 'dependencies': [ 'deps/uv/uv.gyp:libuv' ],
49+ }],
50 ],
51
52 'sources': [
be06d6d0
AS
53+ 'src/node_main.cc',
54+ # node.gyp is added to the project by default.
55+ 'common.gypi',
56+ ],
57+
58+ 'defines': [
59+ 'NODE_WANT_INTERNALS=1',
60+ 'ARCH="<(target_arch)"',
61+ 'PLATFORM="<(OS)"',
62+ ],
63+ },
64+ {
65+ 'target_name': 'libnode',
66+ 'type': 'shared_library',
dc60a63b
ER
67+ 'product_extension': 'so.<(soname_version)',
68+ 'soname_version': '<(soname_version)',
1ed21df5 69+ 'cflags': ['-fPIC'],
be06d6d0 70+
1ed21df5
A
71+ 'sources': [
72 'src/fs_event_wrap.cc',
73 'src/cares_wrap.cc',
74 'src/handle_wrap.cc',
75@@ -88,7 +106,6 @@
be06d6d0
AS
76 'src/node_file.cc',
77 'src/node_http_parser.cc',
78 'src/node_javascript.cc',
79- 'src/node_main.cc',
80 'src/node_os.cc',
81 'src/node_script.cc',
82 'src/node_stat_watcher.cc',
1ed21df5
A
83@@ -137,6 +154,17 @@
84 'common.gypi',
85 ],
86
87+ 'include_dirs': [
88+ 'src',
89+ 'tools/msvs/genfiles',
90+ 'deps/uv/src/ares',
91+ '<(SHARED_INTERMEDIATE_DIR)' # for node_natives.h
92+ ],
93+
94+ 'dependencies': [
95+ 'node_js2c#host',
96+ ],
97+
98 'defines': [
99 'NODE_WANT_INTERNALS=1',
100 'ARCH="<(target_arch)"',
9dc0bdad
A
101--- node-v0.10.3-o/tools/install.py 2013-04-03 11:30:57.000000000 -0600
102+++ node-v0.10.3/tools/install.py 2013-04-03 19:31:32.000000000 -0600
9dc0bdad 103@@ -119,7 +119,9 @@
be06d6d0
AS
104 assert(0) # unhandled action type
105
106 def files(action):
107+ global lib_dir
be06d6d0 108 action(['out/Release/node'], 'bin/node')
f9cee3b6 109+ action(['out/Release/lib.target/libnode.so.10'], lib_dir + '/libnode.so.10.3.0')
be06d6d0
AS
110
111 # install unconditionally, checking if the platform supports dtrace doesn't
112 # work when cross-compiling and besides, there's at least one linux flavor
9dc0bdad 113@@ -134,7 +136,7 @@
be06d6d0
AS
114 if 'true' == variables.get('node_install_npm'): npm_files(action)
115
116 def run(args):
117- global dst_dir, node_prefix, target_defaults, variables
118+ global dst_dir, node_prefix, target_defaults, variables, lib_dir
119
120 # chdir to the project's top-level directory
121 os.chdir(abspath(os.path.dirname(__file__), '..'))
9dc0bdad 122@@ -147,6 +149,9 @@
be06d6d0
AS
123 dst_dir = node_prefix = variables.get('node_prefix') or '/usr/local'
124 if len(args) > 2: dst_dir = abspath(args[2] + '/' + dst_dir)
be06d6d0 125
1ed21df5
A
126+ lib_dir = 'lib'
127+ if len(args) > 3: lib_dir = args[3]
128+
be06d6d0
AS
129 cmd = args[1] if len(args) > 1 else 'install'
130 if cmd == 'install': return files(install)
1ed21df5 131 if cmd == 'uninstall': return files(uninstall)
This page took 0.068392 seconds and 4 git commands to generate.