Merge lp:~marcustomlinson/unity-js-scopes/build-fixes into lp:unity-js-scopes

Proposed by Marcus Tomlinson
Status: Merged
Merged at revision: 12
Proposed branch: lp:~marcustomlinson/unity-js-scopes/build-fixes
Merge into: lp:unity-js-scopes
Diff against target: 96 lines (+13/-17)
4 files modified
.bzrignore (+3/-0)
CMakeLists.txt (+5/-8)
src/bindings/CMakeLists.txt (+1/-3)
src/launcher/CMakeLists.txt (+4/-6)
To merge this branch: bzr merge lp:~marcustomlinson/unity-js-scopes/build-fixes
Reviewer Review Type Date Requested Status
WebApps Pending
Review via email: mp+263015@code.launchpad.net

Commit message

* Add .bzrignore.
* Depend on iojs and v8 from deps/ rather than system installed versions.
* Fixed install by making ADDON_BINARY_FILES relative to CMAKE_CURRENT_BINARY_DIR.
* Fixed "Error: No such module: contextify" iojs runtime error by using "--whole-archive" when linking iojs.
* Fixed iojs link order.

Description of the change

* Add .bzrignore.
* Depend on iojs and v8 from deps/ rather than system installed versions.
* Fixed install by making ADDON_BINARY_FILES relative to CMAKE_CURRENT_BINARY_DIR.
* Fixed "Error: No such module: contextify" iojs runtime error by using "--whole-archive" when linking iojs.
* Fixed iojs link order.

To post a comment you must log in.
Revision history for this message
Marcus Tomlinson (marcustomlinson) wrote :

Hey Alex, I had trouble getting things building and running on my machine. I had to make these changes to get it going.

First issue I had was unity-js-scopes-launcher not recognising the scope.ini argument from the ScopeRunner entry in the example. Then I got "Error: No such module: contextify" when node::Start() was hit.

These changes fixed the above issues I was having, but now I'm still having an issue getting the scope running via unity-scope-tool. I'm calling "unity-scope-tool './examples/simple/simple.ini'", but the scope seems to just hang on startup. Running "unity-js-scopes-launcher './examples/simple/simple.ini'", just gives me the node terminal (">"). I looks like the simple.js script is either not even running, or is failing and no error message is being shown.

Sorry for rambling, I hope I'm making sense here.

I'm not proposing that these changes are all sane :p Please have a look through them and let me know if I'm doing anything stupid / if you have any better solutions.

11. By Marcus Tomlinson

Whoops, link order fixed

Revision history for this message
Marcus Tomlinson (marcustomlinson) wrote :

Hmmm, seems I may have jumped the gun here. Sorry. I see that the "simple" scope is calling some functions that don't actually exist in the bindings.

Is this project still WIP? Or do you have some other uncommitted changes hanging around?

Let me know if I can help.

12. By Marcus Tomlinson

Merged trunk

13. By Marcus Tomlinson

Revert launcher changes

Revision history for this message
Marcus Tomlinson (marcustomlinson) wrote :

Alex, could you please have a look at this. The aim here is to have unity-ja-scopes link against the iojs and v8 from deps/ rather than searching for system installed versions.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== added file '.bzrignore'
2--- .bzrignore 1970-01-01 00:00:00 +0000
3+++ .bzrignore 2015-07-09 06:54:48 +0000
4@@ -0,0 +1,3 @@
5+./deps/io.js
6+./deps/v8-cpp
7+./CMakeLists.txt.user
8
9=== modified file 'CMakeLists.txt'
10--- CMakeLists.txt 2015-06-19 20:38:02 +0000
11+++ CMakeLists.txt 2015-07-09 06:54:48 +0000
12@@ -37,18 +37,15 @@
13 message(FATAL_ERROR "Retriving deps failed")
14 endif()
15
16-set(CMAKE_MODULE_PATH
17- ${CMAKE_MODULE_PATH}
18- ${CMAKE_CURRENT_SOURCE_DIR}/deps/v8-cpp/cmake
19- )
20-
21-find_package(Node REQUIRED)
22-
23 include_directories(
24- ${NODE_INCLUDE_DIRS}
25+ ${CMAKE_CURRENT_SOURCE_DIR}/deps/io.js/deps/v8/include
26+ ${CMAKE_CURRENT_SOURCE_DIR}/deps/io.js/src
27 ${CMAKE_CURRENT_SOURCE_DIR}/deps/v8-cpp/src
28 ${CMAKE_CURRENT_SOURCE_DIR}/src
29 )
30+link_directories(
31+ ${CMAKE_CURRENT_SOURCE_DIR}/deps/io.js/out/Release
32+ )
33
34 add_custom_target(
35 deps
36
37=== modified file 'src/bindings/CMakeLists.txt'
38--- src/bindings/CMakeLists.txt 2015-06-23 19:47:08 +0000
39+++ src/bindings/CMakeLists.txt 2015-07-09 06:54:48 +0000
40@@ -36,7 +36,6 @@
41 )
42
43 link_directories(
44- ${NODE_DEPS_LIB_DIRS}
45 ${SCOPE_LIB_DIRS}
46 )
47
48@@ -64,7 +63,6 @@
49 )
50
51 include_directories(
52- "${CMAKE_SOURCE_DIR}/include"
53 ${Boost_INCLUDE_DIRS}
54 ${SCOPE_INCLUDE_DIRS}
55 )
56@@ -90,7 +88,7 @@
57 )
58
59 set(ADDON_BINARY_FILES
60- ${SCOPE_NODEJS_ADDON_BIN_NAME}.node
61+ ${CMAKE_CURRENT_BINARY_DIR}/${SCOPE_NODEJS_ADDON_BIN_NAME}.node
62 )
63
64 install(DIRECTORY .
65
66=== modified file 'src/launcher/CMakeLists.txt'
67--- src/launcher/CMakeLists.txt 2015-06-19 20:38:02 +0000
68+++ src/launcher/CMakeLists.txt 2015-07-09 06:54:48 +0000
69@@ -35,9 +35,7 @@
70 )
71
72 link_directories(
73- ${NODE_DEPS_LIB_DIRS}
74 ${Boost_LIB_DIRS}
75- ${CMAKE_CURRENT_SOURCE_DIR}/../../deps/io.js/out/Release
76 )
77
78 set(EXECUTABLE_NAME unity-js-scopes-launcher)
79@@ -61,13 +59,13 @@
80 target_link_libraries(
81 ${EXECUTABLE_NAME}
82
83+ -Wl,--whole-archive iojs -Wl,--no-whole-archive
84+ uv
85 cares
86- http_parser
87- iojs
88 openssl
89- uv
90 zlib
91-
92+ http_parser
93+
94 v8_base
95 v8_libbase
96 v8_libplatform

Subscribers

People subscribed via source and target branches

to all changes: