* [PATCH] [v2] added recipe for nodejs
@ 2010-08-22 3:28 AJ ONeal
2010-08-23 23:22 ` AJ ONeal
2010-08-24 1:18 ` Jason Kridner
0 siblings, 2 replies; 7+ messages in thread
From: AJ ONeal @ 2010-08-22 3:28 UTC (permalink / raw)
To: openembedded-devel
---
recipes/nodejs/files/libev-cross-cc.patch | 18 ++++++++++++
recipes/nodejs/files/node-cross-cc.patch | 14 ++++++++++
.../node-dont-include-hosts-usr-include.patch | 22 +++++++++++++++
recipes/nodejs/nodejs_0.2.0.bb | 28 ++++++++++++++++++++
4 files changed, 82 insertions(+), 0 deletions(-)
create mode 100644 recipes/nodejs/files/libev-cross-cc.patch
create mode 100644 recipes/nodejs/files/node-cross-cc.patch
create mode 100644 recipes/nodejs/files/node-dont-include-hosts-usr-include.patch
create mode 100644 recipes/nodejs/nodejs_0.2.0.bb
diff --git a/recipes/nodejs/files/libev-cross-cc.patch b/recipes/nodejs/files/libev-cross-cc.patch
new file mode 100644
index 0000000..446015b
--- /dev/null
+++ b/recipes/nodejs/files/libev-cross-cc.patch
@@ -0,0 +1,18 @@
+diff --git node-v0.2.0/deps/libev/wscript.orig node-v0.2.0/deps/libev/wscript
+index 19e7bb2..f0a3d3b 100644
+--- node-v0.2.0/deps/libev/wscript.orig
++++ node-v0.2.0/deps/libev/wscript
+@@ -52,7 +52,12 @@ def configure(conf):
+ return 0;
+ }
+ """
+- conf.check_cc(fragment=code, define_name="HAVE_CLOCK_SYSCALL", execute=True,
++ # TODO determine this dynamically
++ CROSS = True
++ execute = True
++ if CROSS:
++ execute = False
++ conf.check_cc(fragment=code, define_name="HAVE_CLOCK_SYSCALL", execute=execute,
+ msg="Checking for SYS_clock_gettime")
+
+ have_librt = conf.check(lib='rt', uselib_store='RT')
diff --git a/recipes/nodejs/files/node-cross-cc.patch b/recipes/nodejs/files/node-cross-cc.patch
new file mode 100644
index 0000000..48a6226
--- /dev/null
+++ b/recipes/nodejs/files/node-cross-cc.patch
@@ -0,0 +1,14 @@
+diff --git node-v0.2.0/wscript.orig node-v0.2.0/wscript
+index df9ef53..a55d464 100644
+--- node-v0.2.0/wscript.orig
++++ node-v0.2.0/wscript
+@@ -326,6 +326,9 @@ def v8_cmd(bld, variant):
+ arch = ""
+ if bld.env['DEST_CPU'] == 'x86_64':
+ arch = "arch=x64"
++ # XXX Better support cross-compilation
++ else:
++ arch = "arch=" + bld.env['DEST_CPU']
+
+ if variant == "default":
+ mode = "release"
diff --git a/recipes/nodejs/files/node-dont-include-hosts-usr-include.patch b/recipes/nodejs/files/node-dont-include-hosts-usr-include.patch
new file mode 100644
index 0000000..edbf7c4
--- /dev/null
+++ b/recipes/nodejs/files/node-dont-include-hosts-usr-include.patch
@@ -0,0 +1,22 @@
+diff --git node-v0.2.0/wscript.orig node-v0.2.0/wscript
+index 3c5ebc5..905bd58 100644
+--- node-v0.2.0/wscript.orig
++++ node-v0.2.0/wscript
+@@ -162,11 +162,12 @@ def configure(conf):
+ if Options.options.efence:
+ conf.check(lib='efence', libpath=['/usr/lib', '/usr/local/lib'], uselib_store='EFENCE')
+
+- if not conf.check(lib="execinfo", includes=['/usr/include', '/usr/local/include'], libpath=['/usr/lib', '/usr/local/lib'], uselib_store="EXECINFO"):
+- # Note on Darwin/OS X: This will fail, but will still be used as the
+- # execinfo stuff are part of the standard library.
+- if sys.platform.startswith("freebsd"):
+- conf.fatal("Install the libexecinfo port from /usr/ports/devel/libexecinfo.")
++ # OpenEmbedded doesn't like us checking here
++ #if not conf.check(lib="execinfo", includes=['/usr/include', '/usr/local/include'], libpath=['/usr/lib', '/usr/local/lib'], uselib_store="EXECINFO"):
++ # # Note on Darwin/OS X: This will fail, but will still be used as the
++ # # execinfo stuff are part of the standard library.
++ # if sys.platform.startswith("freebsd"):
++ # conf.fatal("Install the libexecinfo port from /usr/ports/devel/libexecinfo.")
+
+ if not Options.options.without_ssl:
+ if conf.check_cfg(package='openssl',
diff --git a/recipes/nodejs/nodejs_0.2.0.bb b/recipes/nodejs/nodejs_0.2.0.bb
new file mode 100644
index 0000000..83bfa2e
--- /dev/null
+++ b/recipes/nodejs/nodejs_0.2.0.bb
@@ -0,0 +1,28 @@
+DESCRIPTION = "nodeJS Evented I/O for V8 JavaScript"
+HOMEPAGE = "http://nodejs.org"
+LICENSE = "MIT"
+DEPENDS = "openssl"
+SRC_URI = " \
+ http://nodejs.org/dist/node-v${PV}.tar.gz \
+ file://node-cross-cc.patch \
+ file://libev-cross-cc.patch \
+ file://node-dont-include-hosts-usr-include.patch \
+"
+#file://libev-arm-cross.patch \
+SRC_URI[md5sum] = "99a6dacc44b3f9c6ec376ccb446dd0b8"
+SRC_URI[sha256sum] = "3d3eff9287c9917af4044f3cef99ae5b17946710a71e83039de4fcb4b0a26631"
+S = "${WORKDIR}/node-v${PV}"
+do_configure () {
+ ./configure --prefix=${D} --without-snapshot
+}
+do_compile () {
+ make
+}
+do_install () {
+ #oe_runmake install # doesn't install to correct location
+
+ # This works
+ install -d ${D}${bindir}/
+ install -m 0755 ${S}/node ${D}${bindir}/
+}
+FILES_${PN} = "${bindir}/node"
--
1.6.0.4
^ permalink raw reply related [flat|nested] 7+ messages in thread
* Re: [PATCH] [v2] added recipe for nodejs
2010-08-22 3:28 [PATCH] [v2] added recipe for nodejs AJ ONeal
@ 2010-08-23 23:22 ` AJ ONeal
2010-08-23 23:57 ` Paul Menzel
2010-08-24 1:18 ` Jason Kridner
1 sibling, 1 reply; 7+ messages in thread
From: AJ ONeal @ 2010-08-23 23:22 UTC (permalink / raw)
To: openembedded-devel
bump
AJ ONeal
On Sat, Aug 21, 2010 at 9:28 PM, AJ ONeal <coolaj86@gmail.com> wrote:
> ---
> recipes/nodejs/files/libev-cross-cc.patch | 18 ++++++++++++
> recipes/nodejs/files/node-cross-cc.patch | 14 ++++++++++
> .../node-dont-include-hosts-usr-include.patch | 22 +++++++++++++++
> recipes/nodejs/nodejs_0.2.0.bb | 28
> ++++++++++++++++++++
> 4 files changed, 82 insertions(+), 0 deletions(-)
> create mode 100644 recipes/nodejs/files/libev-cross-cc.patch
> create mode 100644 recipes/nodejs/files/node-cross-cc.patch
> create mode 100644
> recipes/nodejs/files/node-dont-include-hosts-usr-include.patch
> create mode 100644 recipes/nodejs/nodejs_0.2.0.bb
>
> diff --git a/recipes/nodejs/files/libev-cross-cc.patch
> b/recipes/nodejs/files/libev-cross-cc.patch
> new file mode 100644
> index 0000000..446015b
> --- /dev/null
> +++ b/recipes/nodejs/files/libev-cross-cc.patch
> @@ -0,0 +1,18 @@
> +diff --git node-v0.2.0/deps/libev/wscript.orig
> node-v0.2.0/deps/libev/wscript
> +index 19e7bb2..f0a3d3b 100644
> +--- node-v0.2.0/deps/libev/wscript.orig
> ++++ node-v0.2.0/deps/libev/wscript
> +@@ -52,7 +52,12 @@ def configure(conf):
> + return 0;
> + }
> + """
> +- conf.check_cc(fragment=code, define_name="HAVE_CLOCK_SYSCALL",
> execute=True,
> ++ # TODO determine this dynamically
> ++ CROSS = True
> ++ execute = True
> ++ if CROSS:
> ++ execute = False
> ++ conf.check_cc(fragment=code, define_name="HAVE_CLOCK_SYSCALL",
> execute=execute,
> + msg="Checking for SYS_clock_gettime")
> +
> + have_librt = conf.check(lib='rt', uselib_store='RT')
> diff --git a/recipes/nodejs/files/node-cross-cc.patch
> b/recipes/nodejs/files/node-cross-cc.patch
> new file mode 100644
> index 0000000..48a6226
> --- /dev/null
> +++ b/recipes/nodejs/files/node-cross-cc.patch
> @@ -0,0 +1,14 @@
> +diff --git node-v0.2.0/wscript.orig node-v0.2.0/wscript
> +index df9ef53..a55d464 100644
> +--- node-v0.2.0/wscript.orig
> ++++ node-v0.2.0/wscript
> +@@ -326,6 +326,9 @@ def v8_cmd(bld, variant):
> + arch = ""
> + if bld.env['DEST_CPU'] == 'x86_64':
> + arch = "arch=x64"
> ++ # XXX Better support cross-compilation
> ++ else:
> ++ arch = "arch=" + bld.env['DEST_CPU']
> +
> + if variant == "default":
> + mode = "release"
> diff --git a/recipes/nodejs/files/node-dont-include-hosts-usr-include.patch
> b/recipes/nodejs/files/node-dont-include-hosts-usr-include.patch
> new file mode 100644
> index 0000000..edbf7c4
> --- /dev/null
> +++ b/recipes/nodejs/files/node-dont-include-hosts-usr-include.patch
> @@ -0,0 +1,22 @@
> +diff --git node-v0.2.0/wscript.orig node-v0.2.0/wscript
> +index 3c5ebc5..905bd58 100644
> +--- node-v0.2.0/wscript.orig
> ++++ node-v0.2.0/wscript
> +@@ -162,11 +162,12 @@ def configure(conf):
> + if Options.options.efence:
> + conf.check(lib='efence', libpath=['/usr/lib', '/usr/local/lib'],
> uselib_store='EFENCE')
> +
> +- if not conf.check(lib="execinfo", includes=['/usr/include',
> '/usr/local/include'], libpath=['/usr/lib', '/usr/local/lib'],
> uselib_store="EXECINFO"):
> +- # Note on Darwin/OS X: This will fail, but will still be used as the
> +- # execinfo stuff are part of the standard library.
> +- if sys.platform.startswith("freebsd"):
> +- conf.fatal("Install the libexecinfo port from
> /usr/ports/devel/libexecinfo.")
> ++ # OpenEmbedded doesn't like us checking here
> ++ #if not conf.check(lib="execinfo", includes=['/usr/include',
> '/usr/local/include'], libpath=['/usr/lib', '/usr/local/lib'],
> uselib_store="EXECINFO"):
> ++ # # Note on Darwin/OS X: This will fail, but will still be used as the
> ++ # # execinfo stuff are part of the standard library.
> ++ # if sys.platform.startswith("freebsd"):
> ++ # conf.fatal("Install the libexecinfo port from
> /usr/ports/devel/libexecinfo.")
> +
> + if not Options.options.without_ssl:
> + if conf.check_cfg(package='openssl',
> diff --git a/recipes/nodejs/nodejs_0.2.0.bb b/recipes/nodejs/
> nodejs_0.2.0.bb
> new file mode 100644
> index 0000000..83bfa2e
> --- /dev/null
> +++ b/recipes/nodejs/nodejs_0.2.0.bb
> @@ -0,0 +1,28 @@
> +DESCRIPTION = "nodeJS Evented I/O for V8 JavaScript"
> +HOMEPAGE = "http://nodejs.org"
> +LICENSE = "MIT"
> +DEPENDS = "openssl"
> +SRC_URI = " \
> + http://nodejs.org/dist/node-v${PV}.tar.gz \
> + file://node-cross-cc.patch \
> + file://libev-cross-cc.patch \
> + file://node-dont-include-hosts-usr-include.patch \
> +"
> +#file://libev-arm-cross.patch \
> +SRC_URI[md5sum] = "99a6dacc44b3f9c6ec376ccb446dd0b8"
> +SRC_URI[sha256sum] =
> "3d3eff9287c9917af4044f3cef99ae5b17946710a71e83039de4fcb4b0a26631"
> +S = "${WORKDIR}/node-v${PV}"
> +do_configure () {
> + ./configure --prefix=${D} --without-snapshot
> +}
> +do_compile () {
> + make
> +}
> +do_install () {
> + #oe_runmake install # doesn't install to correct location
> +
> + # This works
> + install -d ${D}${bindir}/
> + install -m 0755 ${S}/node ${D}${bindir}/
> +}
> +FILES_${PN} = "${bindir}/node"
> --
> 1.6.0.4
>
>
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] [v2] added recipe for nodejs
2010-08-23 23:22 ` AJ ONeal
@ 2010-08-23 23:57 ` Paul Menzel
2010-08-27 4:04 ` Khem Raj
0 siblings, 1 reply; 7+ messages in thread
From: Paul Menzel @ 2010-08-23 23:57 UTC (permalink / raw)
To: openembedded-devel
[-- Attachment #1: Type: text/plain, Size: 6374 bytes --]
Dear AJ,
sorry I overlooked that message. I will reply to your other message
tomorrow.
Am Montag, den 23.08.2010, 17:22 -0600 schrieb AJ ONeal:
> bump
>
> AJ ONeal
>
> On Sat, Aug 21, 2010 at 9:28 PM, AJ ONeal <coolaj86@gmail.com> wrote:
>
> > ---
After this line a short summary of the changes compared to previous
iterations would be great. Git will ignore this when applying the patch
but it eases the work of the reviewers.
> > recipes/nodejs/files/libev-cross-cc.patch | 18 ++++++++++++
> > recipes/nodejs/files/node-cross-cc.patch | 14 ++++++++++
> > .../node-dont-include-hosts-usr-include.patch | 22 +++++++++++++++
> > recipes/nodejs/nodejs_0.2.0.bb | 28
> > ++++++++++++++++++++
> > 4 files changed, 82 insertions(+), 0 deletions(-)
> > create mode 100644 recipes/nodejs/files/libev-cross-cc.patch
> > create mode 100644 recipes/nodejs/files/node-cross-cc.patch
> > create mode 100644
> > recipes/nodejs/files/node-dont-include-hosts-usr-include.patch
> > create mode 100644 recipes/nodejs/nodejs_0.2.0.bb
> >
> > diff --git a/recipes/nodejs/files/libev-cross-cc.patch
> > b/recipes/nodejs/files/libev-cross-cc.patch
> > new file mode 100644
> > index 0000000..446015b
> > --- /dev/null
> > +++ b/recipes/nodejs/files/libev-cross-cc.patch
> > @@ -0,0 +1,18 @@
> > +diff --git node-v0.2.0/deps/libev/wscript.orig
> > node-v0.2.0/deps/libev/wscript
> > +index 19e7bb2..f0a3d3b 100644
> > +--- node-v0.2.0/deps/libev/wscript.orig
> > ++++ node-v0.2.0/deps/libev/wscript
> > +@@ -52,7 +52,12 @@ def configure(conf):
> > + return 0;
> > + }
> > + """
> > +- conf.check_cc(fragment=code, define_name="HAVE_CLOCK_SYSCALL",
> > execute=True,
> > ++ # TODO determine this dynamically
> > ++ CROSS = True
> > ++ execute = True
> > ++ if CROSS:
> > ++ execute = False
> > ++ conf.check_cc(fragment=code, define_name="HAVE_CLOCK_SYSCALL",
> > execute=execute,
> > + msg="Checking for SYS_clock_gettime")
> > +
> > + have_librt = conf.check(lib='rt', uselib_store='RT')
> > diff --git a/recipes/nodejs/files/node-cross-cc.patch
> > b/recipes/nodejs/files/node-cross-cc.patch
> > new file mode 100644
> > index 0000000..48a6226
> > --- /dev/null
> > +++ b/recipes/nodejs/files/node-cross-cc.patch
> > @@ -0,0 +1,14 @@
> > +diff --git node-v0.2.0/wscript.orig node-v0.2.0/wscript
> > +index df9ef53..a55d464 100644
> > +--- node-v0.2.0/wscript.orig
> > ++++ node-v0.2.0/wscript
> > +@@ -326,6 +326,9 @@ def v8_cmd(bld, variant):
> > + arch = ""
> > + if bld.env['DEST_CPU'] == 'x86_64':
> > + arch = "arch=x64"
> > ++ # XXX Better support cross-compilation
> > ++ else:
> > ++ arch = "arch=" + bld.env['DEST_CPU']
> > +
> > + if variant == "default":
> > + mode = "release"
> > diff --git a/recipes/nodejs/files/node-dont-include-hosts-usr-include.patch
> > b/recipes/nodejs/files/node-dont-include-hosts-usr-include.patch
> > new file mode 100644
> > index 0000000..edbf7c4
> > --- /dev/null
> > +++ b/recipes/nodejs/files/node-dont-include-hosts-usr-include.patch
> > @@ -0,0 +1,22 @@
> > +diff --git node-v0.2.0/wscript.orig node-v0.2.0/wscript
> > +index 3c5ebc5..905bd58 100644
> > +--- node-v0.2.0/wscript.orig
> > ++++ node-v0.2.0/wscript
> > +@@ -162,11 +162,12 @@ def configure(conf):
> > + if Options.options.efence:
> > + conf.check(lib='efence', libpath=['/usr/lib', '/usr/local/lib'],
> > uselib_store='EFENCE')
> > +
> > +- if not conf.check(lib="execinfo", includes=['/usr/include',
> > '/usr/local/include'], libpath=['/usr/lib', '/usr/local/lib'],
> > uselib_store="EXECINFO"):
> > +- # Note on Darwin/OS X: This will fail, but will still be used as the
> > +- # execinfo stuff are part of the standard library.
> > +- if sys.platform.startswith("freebsd"):
> > +- conf.fatal("Install the libexecinfo port from
> > /usr/ports/devel/libexecinfo.")
> > ++ # OpenEmbedded doesn't like us checking here
> > ++ #if not conf.check(lib="execinfo", includes=['/usr/include',
> > '/usr/local/include'], libpath=['/usr/lib', '/usr/local/lib'],
> > uselib_store="EXECINFO"):
> > ++ # # Note on Darwin/OS X: This will fail, but will still be used as the
> > ++ # # execinfo stuff are part of the standard library.
> > ++ # if sys.platform.startswith("freebsd"):
> > ++ # conf.fatal("Install the libexecinfo port from
> > /usr/ports/devel/libexecinfo.")
> > +
> > + if not Options.options.without_ssl:
> > + if conf.check_cfg(package='openssl',
Did you sent these patches upstream? Maybe document that in the patch
headers. There is also a page in the Wiki regarding this.
> > diff --git a/recipes/nodejs/nodejs_0.2.0.bb b/recipes/nodejs/
> > nodejs_0.2.0.bb
> > new file mode 100644
> > index 0000000..83bfa2e
> > --- /dev/null
> > +++ b/recipes/nodejs/nodejs_0.2.0.bb
> > @@ -0,0 +1,28 @@
> > +DESCRIPTION = "nodeJS Evented I/O for V8 JavaScript"
> > +HOMEPAGE = "http://nodejs.org"
> > +LICENSE = "MIT"
> > +DEPENDS = "openssl"
> > +SRC_URI = " \
> > + http://nodejs.org/dist/node-v${PV}.tar.gz \
> > + file://node-cross-cc.patch \
> > + file://libev-cross-cc.patch \
> > + file://node-dont-include-hosts-usr-include.patch \
> > +"
> > +#file://libev-arm-cross.patch \
Is that commented line needed?
> > +SRC_URI[md5sum] = "99a6dacc44b3f9c6ec376ccb446dd0b8"
> > +SRC_URI[sha256sum] =
> > "3d3eff9287c9917af4044f3cef99ae5b17946710a71e83039de4fcb4b0a26631"
> > +S = "${WORKDIR}/node-v${PV}"
> > +do_configure () {
> > + ./configure --prefix=${D} --without-snapshot
> > +}
Can you use `EXTRA_OECONF` (Do `git grep EXTRA_OECONF` in the repository
to get examples.)
I think you might need `inherit autotools`, but I am not sure.
> > +do_compile () {
> > + make
> > +}
Is that needed? What about Frans’ suggestion?
> > +do_install () {
> > + #oe_runmake install # doesn't install to correct location
> > +
> > + # This works
> > + install -d ${D}${bindir}/
> > + install -m 0755 ${S}/node ${D}${bindir}/
> > +}
> > +FILES_${PN} = "${bindir}/node"
Why is that needed?
I am a beginner, so I hope my comments are correct. If so please submit
a v3 and do not forget your Signed-off-by line.
Thanks,
Paul
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 205 bytes --]
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] [v2] added recipe for nodejs
2010-08-22 3:28 [PATCH] [v2] added recipe for nodejs AJ ONeal
2010-08-23 23:22 ` AJ ONeal
@ 2010-08-24 1:18 ` Jason Kridner
1 sibling, 0 replies; 7+ messages in thread
From: Jason Kridner @ 2010-08-24 1:18 UTC (permalink / raw)
To: openembedded-devel
On Sat, Aug 21, 2010 at 11:28 PM, AJ ONeal <coolaj86@gmail.com> wrote:
> ---
> recipes/nodejs/files/libev-cross-cc.patch | 18 ++++++++++++
> recipes/nodejs/files/node-cross-cc.patch | 14 ++++++++++
> .../node-dont-include-hosts-usr-include.patch | 22 +++++++++++++++
> recipes/nodejs/nodejs_0.2.0.bb | 28 ++++++++++++++++++++
> 4 files changed, 82 insertions(+), 0 deletions(-)
> create mode 100644 recipes/nodejs/files/libev-cross-cc.patch
> create mode 100644 recipes/nodejs/files/node-cross-cc.patch
> create mode 100644 recipes/nodejs/files/node-dont-include-hosts-usr-include.patch
> create mode 100644 recipes/nodejs/nodejs_0.2.0.bb
>
> diff --git a/recipes/nodejs/files/libev-cross-cc.patch b/recipes/nodejs/files/libev-cross-cc.patch
> new file mode 100644
> index 0000000..446015b
> --- /dev/null
> +++ b/recipes/nodejs/files/libev-cross-cc.patch
> @@ -0,0 +1,18 @@
> +diff --git node-v0.2.0/deps/libev/wscript.orig node-v0.2.0/deps/libev/wscript
> +index 19e7bb2..f0a3d3b 100644
> +--- node-v0.2.0/deps/libev/wscript.orig
> ++++ node-v0.2.0/deps/libev/wscript
> +@@ -52,7 +52,12 @@ def configure(conf):
> + return 0;
> + }
> + """
> +- conf.check_cc(fragment=code, define_name="HAVE_CLOCK_SYSCALL", execute=True,
> ++ # TODO determine this dynamically
> ++ CROSS = True
> ++ execute = True
> ++ if CROSS:
> ++ execute = False
> ++ conf.check_cc(fragment=code, define_name="HAVE_CLOCK_SYSCALL", execute=execute,
> + msg="Checking for SYS_clock_gettime")
> +
> + have_librt = conf.check(lib='rt', uselib_store='RT')
> diff --git a/recipes/nodejs/files/node-cross-cc.patch b/recipes/nodejs/files/node-cross-cc.patch
> new file mode 100644
> index 0000000..48a6226
> --- /dev/null
> +++ b/recipes/nodejs/files/node-cross-cc.patch
> @@ -0,0 +1,14 @@
> +diff --git node-v0.2.0/wscript.orig node-v0.2.0/wscript
> +index df9ef53..a55d464 100644
> +--- node-v0.2.0/wscript.orig
> ++++ node-v0.2.0/wscript
> +@@ -326,6 +326,9 @@ def v8_cmd(bld, variant):
> + arch = ""
> + if bld.env['DEST_CPU'] == 'x86_64':
> + arch = "arch=x64"
> ++ # XXX Better support cross-compilation
> ++ else:
> ++ arch = "arch=" + bld.env['DEST_CPU']
> +
> + if variant == "default":
> + mode = "release"
> diff --git a/recipes/nodejs/files/node-dont-include-hosts-usr-include.patch b/recipes/nodejs/files/node-dont-include-hosts-usr-include.patch
> new file mode 100644
> index 0000000..edbf7c4
> --- /dev/null
> +++ b/recipes/nodejs/files/node-dont-include-hosts-usr-include.patch
> @@ -0,0 +1,22 @@
> +diff --git node-v0.2.0/wscript.orig node-v0.2.0/wscript
> +index 3c5ebc5..905bd58 100644
> +--- node-v0.2.0/wscript.orig
> ++++ node-v0.2.0/wscript
> +@@ -162,11 +162,12 @@ def configure(conf):
> + if Options.options.efence:
> + conf.check(lib='efence', libpath=['/usr/lib', '/usr/local/lib'], uselib_store='EFENCE')
> +
> +- if not conf.check(lib="execinfo", includes=['/usr/include', '/usr/local/include'], libpath=['/usr/lib', '/usr/local/lib'], uselib_store="EXECINFO"):
> +- # Note on Darwin/OS X: This will fail, but will still be used as the
> +- # execinfo stuff are part of the standard library.
> +- if sys.platform.startswith("freebsd"):
> +- conf.fatal("Install the libexecinfo port from /usr/ports/devel/libexecinfo.")
> ++ # OpenEmbedded doesn't like us checking here
> ++ #if not conf.check(lib="execinfo", includes=['/usr/include', '/usr/local/include'], libpath=['/usr/lib', '/usr/local/lib'], uselib_store="EXECINFO"):
> ++ # # Note on Darwin/OS X: This will fail, but will still be used as the
> ++ # # execinfo stuff are part of the standard library.
> ++ # if sys.platform.startswith("freebsd"):
> ++ # conf.fatal("Install the libexecinfo port from /usr/ports/devel/libexecinfo.")
> +
> + if not Options.options.without_ssl:
> + if conf.check_cfg(package='openssl',
> diff --git a/recipes/nodejs/nodejs_0.2.0.bb b/recipes/nodejs/nodejs_0.2.0.bb
> new file mode 100644
> index 0000000..83bfa2e
> --- /dev/null
> +++ b/recipes/nodejs/nodejs_0.2.0.bb
> @@ -0,0 +1,28 @@
> +DESCRIPTION = "nodeJS Evented I/O for V8 JavaScript"
> +HOMEPAGE = "http://nodejs.org"
> +LICENSE = "MIT"
> +DEPENDS = "openssl"
> +SRC_URI = " \
> + http://nodejs.org/dist/node-v${PV}.tar.gz \
> + file://node-cross-cc.patch \
> + file://libev-cross-cc.patch \
> + file://node-dont-include-hosts-usr-include.patch \
> +"
> +#file://libev-arm-cross.patch \
> +SRC_URI[md5sum] = "99a6dacc44b3f9c6ec376ccb446dd0b8"
> +SRC_URI[sha256sum] = "3d3eff9287c9917af4044f3cef99ae5b17946710a71e83039de4fcb4b0a26631"
> +S = "${WORKDIR}/node-v${PV}"
> +do_configure () {
> + ./configure --prefix=${D} --without-snapshot
> +}
> +do_compile () {
> + make
> +}
> +do_install () {
> + #oe_runmake install # doesn't install to correct location
> +
> + # This works
> + install -d ${D}${bindir}/
> + install -m 0755 ${S}/node ${D}${bindir}/
> +}
> +FILES_${PN} = "${bindir}/node"
> --
> 1.6.0.4
I confirmed that this builds fine--haven't run-tested it yet. 'git
am' gave me some trailing whitespace warnings, but I can't otherwise
comment on the patch.
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] [v2] added recipe for nodejs
2010-08-23 23:57 ` Paul Menzel
@ 2010-08-27 4:04 ` Khem Raj
2010-08-27 5:54 ` AJ ONeal
0 siblings, 1 reply; 7+ messages in thread
From: Khem Raj @ 2010-08-27 4:04 UTC (permalink / raw)
To: openembedded-devel
On (24/08/10 01:57), Paul Menzel wrote:
> Dear AJ,
>
>
> sorry I overlooked that message. I will reply to your other message
> tomorrow.
>
>
> Am Montag, den 23.08.2010, 17:22 -0600 schrieb AJ ONeal:
> > bump
> >
> > AJ ONeal
> >
> > On Sat, Aug 21, 2010 at 9:28 PM, AJ ONeal <coolaj86@gmail.com> wrote:
> >
> > > ---
>
> After this line a short summary of the changes compared to previous
> iterations would be great. Git will ignore this when applying the patch
> but it eases the work of the reviewers.
>
> > > recipes/nodejs/files/libev-cross-cc.patch | 18 ++++++++++++
> > > recipes/nodejs/files/node-cross-cc.patch | 14 ++++++++++
> > > .../node-dont-include-hosts-usr-include.patch | 22 +++++++++++++++
> > > recipes/nodejs/nodejs_0.2.0.bb | 28
> > > ++++++++++++++++++++
> > > 4 files changed, 82 insertions(+), 0 deletions(-)
> > > create mode 100644 recipes/nodejs/files/libev-cross-cc.patch
> > > create mode 100644 recipes/nodejs/files/node-cross-cc.patch
> > > create mode 100644
> > > recipes/nodejs/files/node-dont-include-hosts-usr-include.patch
> > > create mode 100644 recipes/nodejs/nodejs_0.2.0.bb
> > >
> > > diff --git a/recipes/nodejs/files/libev-cross-cc.patch
> > > b/recipes/nodejs/files/libev-cross-cc.patch
> > > new file mode 100644
> > > index 0000000..446015b
> > > --- /dev/null
> > > +++ b/recipes/nodejs/files/libev-cross-cc.patch
> > > @@ -0,0 +1,18 @@
> > > +diff --git node-v0.2.0/deps/libev/wscript.orig
> > > node-v0.2.0/deps/libev/wscript
> > > +index 19e7bb2..f0a3d3b 100644
> > > +--- node-v0.2.0/deps/libev/wscript.orig
> > > ++++ node-v0.2.0/deps/libev/wscript
> > > +@@ -52,7 +52,12 @@ def configure(conf):
> > > + return 0;
> > > + }
> > > + """
> > > +- conf.check_cc(fragment=code, define_name="HAVE_CLOCK_SYSCALL",
> > > execute=True,
> > > ++ # TODO determine this dynamically
> > > ++ CROSS = True
> > > ++ execute = True
> > > ++ if CROSS:
> > > ++ execute = False
> > > ++ conf.check_cc(fragment=code, define_name="HAVE_CLOCK_SYSCALL",
> > > execute=execute,
> > > + msg="Checking for SYS_clock_gettime")
> > > +
> > > + have_librt = conf.check(lib='rt', uselib_store='RT')
> > > diff --git a/recipes/nodejs/files/node-cross-cc.patch
> > > b/recipes/nodejs/files/node-cross-cc.patch
> > > new file mode 100644
> > > index 0000000..48a6226
> > > --- /dev/null
> > > +++ b/recipes/nodejs/files/node-cross-cc.patch
> > > @@ -0,0 +1,14 @@
> > > +diff --git node-v0.2.0/wscript.orig node-v0.2.0/wscript
> > > +index df9ef53..a55d464 100644
> > > +--- node-v0.2.0/wscript.orig
> > > ++++ node-v0.2.0/wscript
> > > +@@ -326,6 +326,9 @@ def v8_cmd(bld, variant):
> > > + arch = ""
> > > + if bld.env['DEST_CPU'] == 'x86_64':
> > > + arch = "arch=x64"
> > > ++ # XXX Better support cross-compilation
> > > ++ else:
> > > ++ arch = "arch=" + bld.env['DEST_CPU']
> > > +
> > > + if variant == "default":
> > > + mode = "release"
> > > diff --git a/recipes/nodejs/files/node-dont-include-hosts-usr-include.patch
> > > b/recipes/nodejs/files/node-dont-include-hosts-usr-include.patch
> > > new file mode 100644
> > > index 0000000..edbf7c4
> > > --- /dev/null
> > > +++ b/recipes/nodejs/files/node-dont-include-hosts-usr-include.patch
> > > @@ -0,0 +1,22 @@
> > > +diff --git node-v0.2.0/wscript.orig node-v0.2.0/wscript
> > > +index 3c5ebc5..905bd58 100644
> > > +--- node-v0.2.0/wscript.orig
> > > ++++ node-v0.2.0/wscript
> > > +@@ -162,11 +162,12 @@ def configure(conf):
> > > + if Options.options.efence:
> > > + conf.check(lib='efence', libpath=['/usr/lib', '/usr/local/lib'],
> > > uselib_store='EFENCE')
> > > +
> > > +- if not conf.check(lib="execinfo", includes=['/usr/include',
> > > '/usr/local/include'], libpath=['/usr/lib', '/usr/local/lib'],
> > > uselib_store="EXECINFO"):
> > > +- # Note on Darwin/OS X: This will fail, but will still be used as the
> > > +- # execinfo stuff are part of the standard library.
> > > +- if sys.platform.startswith("freebsd"):
> > > +- conf.fatal("Install the libexecinfo port from
> > > /usr/ports/devel/libexecinfo.")
> > > ++ # OpenEmbedded doesn't like us checking here
> > > ++ #if not conf.check(lib="execinfo", includes=['/usr/include',
> > > '/usr/local/include'], libpath=['/usr/lib', '/usr/local/lib'],
> > > uselib_store="EXECINFO"):
> > > ++ # # Note on Darwin/OS X: This will fail, but will still be used as the
> > > ++ # # execinfo stuff are part of the standard library.
> > > ++ # if sys.platform.startswith("freebsd"):
> > > ++ # conf.fatal("Install the libexecinfo port from
> > > /usr/ports/devel/libexecinfo.")
> > > +
> > > + if not Options.options.without_ssl:
> > > + if conf.check_cfg(package='openssl',
>
> Did you sent these patches upstream? Maybe document that in the patch
> headers. There is also a page in the Wiki regarding this.
>
> > > diff --git a/recipes/nodejs/nodejs_0.2.0.bb b/recipes/nodejs/
> > > nodejs_0.2.0.bb
> > > new file mode 100644
> > > index 0000000..83bfa2e
> > > --- /dev/null
> > > +++ b/recipes/nodejs/nodejs_0.2.0.bb
> > > @@ -0,0 +1,28 @@
> > > +DESCRIPTION = "nodeJS Evented I/O for V8 JavaScript"
> > > +HOMEPAGE = "http://nodejs.org"
> > > +LICENSE = "MIT"
> > > +DEPENDS = "openssl"
> > > +SRC_URI = " \
> > > + http://nodejs.org/dist/node-v${PV}.tar.gz \
> > > + file://node-cross-cc.patch \
> > > + file://libev-cross-cc.patch \
> > > + file://node-dont-include-hosts-usr-include.patch \
> > > +"
> > > +#file://libev-arm-cross.patch \
>
> Is that commented line needed?
>
> > > +SRC_URI[md5sum] = "99a6dacc44b3f9c6ec376ccb446dd0b8"
> > > +SRC_URI[sha256sum] =
> > > "3d3eff9287c9917af4044f3cef99ae5b17946710a71e83039de4fcb4b0a26631"
> > > +S = "${WORKDIR}/node-v${PV}"
> > > +do_configure () {
> > > + ./configure --prefix=${D} --without-snapshot
> > > +}
>
> Can you use `EXTRA_OECONF` (Do `git grep EXTRA_OECONF` in the repository
> to get examples.)
its ok. Since its override the do_configure
>
> I think you might need `inherit autotools`, but I am not sure.
no this package does not use autotools it not needed.
>
> > > +do_compile () {
> > > + make
> > > +}
>
> Is that needed? What about Frans’ suggestion?
should use oe_runmake instea of bare make to exploit parallelism.
>
> > > +do_install () {
> > > + #oe_runmake install # doesn't install to correct location
> > > +
> > > + # This works
> > > + install -d ${D}${bindir}/
> > > + install -m 0755 ${S}/node ${D}${bindir}/
> > > +}
> > > +FILES_${PN} = "${bindir}/node"
>
> Why is that needed?
>
> I am a beginner, so I hope my comments are correct. If so please submit
> a v3 and do not forget your Signed-off-by line.
right.
>
>
> Thanks,
>
> Paul
> _______________________________________________
> Openembedded-devel mailing list
> Openembedded-devel@lists.openembedded.org
> http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-devel
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] [v2] added recipe for nodejs
2010-08-27 4:04 ` Khem Raj
@ 2010-08-27 5:54 ` AJ ONeal
2010-08-27 17:40 ` AJ ONeal
0 siblings, 1 reply; 7+ messages in thread
From: AJ ONeal @ 2010-08-27 5:54 UTC (permalink / raw)
To: openembedded-devel
I'll resubmit this weekend and put that patch tutorial on the wiki too.
AJ ONeal
On Thu, Aug 26, 2010 at 10:04 PM, Khem Raj <raj.khem@gmail.com> wrote:
> On (24/08/10 01:57), Paul Menzel wrote:
> > Dear AJ,
> >
> >
> > sorry I overlooked that message. I will reply to your other message
> > tomorrow.
> >
> >
> > Am Montag, den 23.08.2010, 17:22 -0600 schrieb AJ ONeal:
> > > bump
> > >
> > > AJ ONeal
> > >
> > > On Sat, Aug 21, 2010 at 9:28 PM, AJ ONeal <coolaj86@gmail.com> wrote:
> > >
> > > > ---
> >
> > After this line a short summary of the changes compared to previous
> > iterations would be great. Git will ignore this when applying the patch
> > but it eases the work of the reviewers.
> >
> > > > recipes/nodejs/files/libev-cross-cc.patch | 18
> ++++++++++++
> > > > recipes/nodejs/files/node-cross-cc.patch | 14 ++++++++++
> > > > .../node-dont-include-hosts-usr-include.patch | 22
> +++++++++++++++
> > > > recipes/nodejs/nodejs_0.2.0.bb | 28
> > > > ++++++++++++++++++++
> > > > 4 files changed, 82 insertions(+), 0 deletions(-)
> > > > create mode 100644 recipes/nodejs/files/libev-cross-cc.patch
> > > > create mode 100644 recipes/nodejs/files/node-cross-cc.patch
> > > > create mode 100644
> > > > recipes/nodejs/files/node-dont-include-hosts-usr-include.patch
> > > > create mode 100644 recipes/nodejs/nodejs_0.2.0.bb
> > > >
> > > > diff --git a/recipes/nodejs/files/libev-cross-cc.patch
> > > > b/recipes/nodejs/files/libev-cross-cc.patch
> > > > new file mode 100644
> > > > index 0000000..446015b
> > > > --- /dev/null
> > > > +++ b/recipes/nodejs/files/libev-cross-cc.patch
> > > > @@ -0,0 +1,18 @@
> > > > +diff --git node-v0.2.0/deps/libev/wscript.orig
> > > > node-v0.2.0/deps/libev/wscript
> > > > +index 19e7bb2..f0a3d3b 100644
> > > > +--- node-v0.2.0/deps/libev/wscript.orig
> > > > ++++ node-v0.2.0/deps/libev/wscript
> > > > +@@ -52,7 +52,12 @@ def configure(conf):
> > > > + return 0;
> > > > + }
> > > > + """
> > > > +- conf.check_cc(fragment=code, define_name="HAVE_CLOCK_SYSCALL",
> > > > execute=True,
> > > > ++ # TODO determine this dynamically
> > > > ++ CROSS = True
> > > > ++ execute = True
> > > > ++ if CROSS:
> > > > ++ execute = False
> > > > ++ conf.check_cc(fragment=code, define_name="HAVE_CLOCK_SYSCALL",
> > > > execute=execute,
> > > > + msg="Checking for SYS_clock_gettime")
> > > > +
> > > > + have_librt = conf.check(lib='rt', uselib_store='RT')
> > > > diff --git a/recipes/nodejs/files/node-cross-cc.patch
> > > > b/recipes/nodejs/files/node-cross-cc.patch
> > > > new file mode 100644
> > > > index 0000000..48a6226
> > > > --- /dev/null
> > > > +++ b/recipes/nodejs/files/node-cross-cc.patch
> > > > @@ -0,0 +1,14 @@
> > > > +diff --git node-v0.2.0/wscript.orig node-v0.2.0/wscript
> > > > +index df9ef53..a55d464 100644
> > > > +--- node-v0.2.0/wscript.orig
> > > > ++++ node-v0.2.0/wscript
> > > > +@@ -326,6 +326,9 @@ def v8_cmd(bld, variant):
> > > > + arch = ""
> > > > + if bld.env['DEST_CPU'] == 'x86_64':
> > > > + arch = "arch=x64"
> > > > ++ # XXX Better support cross-compilation
> > > > ++ else:
> > > > ++ arch = "arch=" + bld.env['DEST_CPU']
> > > > +
> > > > + if variant == "default":
> > > > + mode = "release"
> > > > diff --git
> a/recipes/nodejs/files/node-dont-include-hosts-usr-include.patch
> > > > b/recipes/nodejs/files/node-dont-include-hosts-usr-include.patch
> > > > new file mode 100644
> > > > index 0000000..edbf7c4
> > > > --- /dev/null
> > > > +++ b/recipes/nodejs/files/node-dont-include-hosts-usr-include.patch
> > > > @@ -0,0 +1,22 @@
> > > > +diff --git node-v0.2.0/wscript.orig node-v0.2.0/wscript
> > > > +index 3c5ebc5..905bd58 100644
> > > > +--- node-v0.2.0/wscript.orig
> > > > ++++ node-v0.2.0/wscript
> > > > +@@ -162,11 +162,12 @@ def configure(conf):
> > > > + if Options.options.efence:
> > > > + conf.check(lib='efence', libpath=['/usr/lib',
> '/usr/local/lib'],
> > > > uselib_store='EFENCE')
> > > > +
> > > > +- if not conf.check(lib="execinfo", includes=['/usr/include',
> > > > '/usr/local/include'], libpath=['/usr/lib', '/usr/local/lib'],
> > > > uselib_store="EXECINFO"):
> > > > +- # Note on Darwin/OS X: This will fail, but will still be used
> as the
> > > > +- # execinfo stuff are part of the standard library.
> > > > +- if sys.platform.startswith("freebsd"):
> > > > +- conf.fatal("Install the libexecinfo port from
> > > > /usr/ports/devel/libexecinfo.")
> > > > ++ # OpenEmbedded doesn't like us checking here
> > > > ++ #if not conf.check(lib="execinfo", includes=['/usr/include',
> > > > '/usr/local/include'], libpath=['/usr/lib', '/usr/local/lib'],
> > > > uselib_store="EXECINFO"):
> > > > ++ # # Note on Darwin/OS X: This will fail, but will still be used
> as the
> > > > ++ # # execinfo stuff are part of the standard library.
> > > > ++ # if sys.platform.startswith("freebsd"):
> > > > ++ # conf.fatal("Install the libexecinfo port from
> > > > /usr/ports/devel/libexecinfo.")
> > > > +
> > > > + if not Options.options.without_ssl:
> > > > + if conf.check_cfg(package='openssl',
> >
> > Did you sent these patches upstream? Maybe document that in the patch
> > headers. There is also a page in the Wiki regarding this.
> >
> > > > diff --git a/recipes/nodejs/nodejs_0.2.0.bb b/recipes/nodejs/
> > > > nodejs_0.2.0.bb
> > > > new file mode 100644
> > > > index 0000000..83bfa2e
> > > > --- /dev/null
> > > > +++ b/recipes/nodejs/nodejs_0.2.0.bb
> > > > @@ -0,0 +1,28 @@
> > > > +DESCRIPTION = "nodeJS Evented I/O for V8 JavaScript"
> > > > +HOMEPAGE = "http://nodejs.org"
> > > > +LICENSE = "MIT"
> > > > +DEPENDS = "openssl"
> > > > +SRC_URI = " \
> > > > + http://nodejs.org/dist/node-v${PV}.tar.gz \
> > > > + file://node-cross-cc.patch \
> > > > + file://libev-cross-cc.patch \
> > > > + file://node-dont-include-hosts-usr-include.patch \
> > > > +"
> > > > +#file://libev-arm-cross.patch \
> >
> > Is that commented line needed?
> >
> > > > +SRC_URI[md5sum] = "99a6dacc44b3f9c6ec376ccb446dd0b8"
> > > > +SRC_URI[sha256sum] =
> > > > "3d3eff9287c9917af4044f3cef99ae5b17946710a71e83039de4fcb4b0a26631"
> > > > +S = "${WORKDIR}/node-v${PV}"
> > > > +do_configure () {
> > > > + ./configure --prefix=${D} --without-snapshot
> > > > +}
> >
> > Can you use `EXTRA_OECONF` (Do `git grep EXTRA_OECONF` in the repository
> > to get examples.)
>
> its ok. Since its override the do_configure
>
> >
> > I think you might need `inherit autotools`, but I am not sure.
>
>
> no this package does not use autotools it not needed.
>
> >
> > > > +do_compile () {
> > > > + make
> > > > +}
> >
> > Is that needed? What about Frans’ suggestion?
>
> should use oe_runmake instea of bare make to exploit parallelism.
>
> >
> > > > +do_install () {
> > > > + #oe_runmake install # doesn't install to correct location
> > > > +
> > > > + # This works
> > > > + install -d ${D}${bindir}/
> > > > + install -m 0755 ${S}/node ${D}${bindir}/
> > > > +}
> > > > +FILES_${PN} = "${bindir}/node"
> >
> > Why is that needed?
> >
> > I am a beginner, so I hope my comments are correct. If so please submit
> > a v3 and do not forget your Signed-off-by line.
>
> right.
> >
> >
> > Thanks,
> >
> > Paul
>
>
>
> > _______________________________________________
> > Openembedded-devel mailing list
> > Openembedded-devel@lists.openembedded.org
> > http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-devel
>
>
> _______________________________________________
> Openembedded-devel mailing list
> Openembedded-devel@lists.openembedded.org
> http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-devel
>
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] [v2] added recipe for nodejs
2010-08-27 5:54 ` AJ ONeal
@ 2010-08-27 17:40 ` AJ ONeal
0 siblings, 0 replies; 7+ messages in thread
From: AJ ONeal @ 2010-08-27 17:40 UTC (permalink / raw)
To: openembedded-devel
Upstream is making some changes so that my patches probably won't be
necessary.
I'm going to wait a week or two and I'll resubmit once node-v0.2.1 comes out
which will most likely include the changes.
AJ ONeal
On Thu, Aug 26, 2010 at 11:54 PM, AJ ONeal <coolaj86@gmail.com> wrote:
> I'll resubmit this weekend and put that patch tutorial on the wiki too.
>
> AJ ONeal
>
>
>
> On Thu, Aug 26, 2010 at 10:04 PM, Khem Raj <raj.khem@gmail.com> wrote:
>
>> On (24/08/10 01:57), Paul Menzel wrote:
>> > Dear AJ,
>> >
>> >
>> > sorry I overlooked that message. I will reply to your other message
>> > tomorrow.
>> >
>> >
>> > Am Montag, den 23.08.2010, 17:22 -0600 schrieb AJ ONeal:
>> > > bump
>> > >
>> > > AJ ONeal
>> > >
>> > > On Sat, Aug 21, 2010 at 9:28 PM, AJ ONeal <coolaj86@gmail.com> wrote:
>> > >
>> > > > ---
>> >
>> > After this line a short summary of the changes compared to previous
>> > iterations would be great. Git will ignore this when applying the patch
>> > but it eases the work of the reviewers.
>> >
>> > > > recipes/nodejs/files/libev-cross-cc.patch | 18
>> ++++++++++++
>> > > > recipes/nodejs/files/node-cross-cc.patch | 14
>> ++++++++++
>> > > > .../node-dont-include-hosts-usr-include.patch | 22
>> +++++++++++++++
>> > > > recipes/nodejs/nodejs_0.2.0.bb | 28
>> > > > ++++++++++++++++++++
>> > > > 4 files changed, 82 insertions(+), 0 deletions(-)
>> > > > create mode 100644 recipes/nodejs/files/libev-cross-cc.patch
>> > > > create mode 100644 recipes/nodejs/files/node-cross-cc.patch
>> > > > create mode 100644
>> > > > recipes/nodejs/files/node-dont-include-hosts-usr-include.patch
>> > > > create mode 100644 recipes/nodejs/nodejs_0.2.0.bb
>> > > >
>> > > > diff --git a/recipes/nodejs/files/libev-cross-cc.patch
>> > > > b/recipes/nodejs/files/libev-cross-cc.patch
>> > > > new file mode 100644
>> > > > index 0000000..446015b
>> > > > --- /dev/null
>> > > > +++ b/recipes/nodejs/files/libev-cross-cc.patch
>> > > > @@ -0,0 +1,18 @@
>> > > > +diff --git node-v0.2.0/deps/libev/wscript.orig
>> > > > node-v0.2.0/deps/libev/wscript
>> > > > +index 19e7bb2..f0a3d3b 100644
>> > > > +--- node-v0.2.0/deps/libev/wscript.orig
>> > > > ++++ node-v0.2.0/deps/libev/wscript
>> > > > +@@ -52,7 +52,12 @@ def configure(conf):
>> > > > + return 0;
>> > > > + }
>> > > > + """
>> > > > +- conf.check_cc(fragment=code, define_name="HAVE_CLOCK_SYSCALL",
>> > > > execute=True,
>> > > > ++ # TODO determine this dynamically
>> > > > ++ CROSS = True
>> > > > ++ execute = True
>> > > > ++ if CROSS:
>> > > > ++ execute = False
>> > > > ++ conf.check_cc(fragment=code, define_name="HAVE_CLOCK_SYSCALL",
>> > > > execute=execute,
>> > > > + msg="Checking for SYS_clock_gettime")
>> > > > +
>> > > > + have_librt = conf.check(lib='rt', uselib_store='RT')
>> > > > diff --git a/recipes/nodejs/files/node-cross-cc.patch
>> > > > b/recipes/nodejs/files/node-cross-cc.patch
>> > > > new file mode 100644
>> > > > index 0000000..48a6226
>> > > > --- /dev/null
>> > > > +++ b/recipes/nodejs/files/node-cross-cc.patch
>> > > > @@ -0,0 +1,14 @@
>> > > > +diff --git node-v0.2.0/wscript.orig node-v0.2.0/wscript
>> > > > +index df9ef53..a55d464 100644
>> > > > +--- node-v0.2.0/wscript.orig
>> > > > ++++ node-v0.2.0/wscript
>> > > > +@@ -326,6 +326,9 @@ def v8_cmd(bld, variant):
>> > > > + arch = ""
>> > > > + if bld.env['DEST_CPU'] == 'x86_64':
>> > > > + arch = "arch=x64"
>> > > > ++ # XXX Better support cross-compilation
>> > > > ++ else:
>> > > > ++ arch = "arch=" + bld.env['DEST_CPU']
>> > > > +
>> > > > + if variant == "default":
>> > > > + mode = "release"
>> > > > diff --git
>> a/recipes/nodejs/files/node-dont-include-hosts-usr-include.patch
>> > > > b/recipes/nodejs/files/node-dont-include-hosts-usr-include.patch
>> > > > new file mode 100644
>> > > > index 0000000..edbf7c4
>> > > > --- /dev/null
>> > > > +++ b/recipes/nodejs/files/node-dont-include-hosts-usr-include.patch
>> > > > @@ -0,0 +1,22 @@
>> > > > +diff --git node-v0.2.0/wscript.orig node-v0.2.0/wscript
>> > > > +index 3c5ebc5..905bd58 100644
>> > > > +--- node-v0.2.0/wscript.orig
>> > > > ++++ node-v0.2.0/wscript
>> > > > +@@ -162,11 +162,12 @@ def configure(conf):
>> > > > + if Options.options.efence:
>> > > > + conf.check(lib='efence', libpath=['/usr/lib',
>> '/usr/local/lib'],
>> > > > uselib_store='EFENCE')
>> > > > +
>> > > > +- if not conf.check(lib="execinfo", includes=['/usr/include',
>> > > > '/usr/local/include'], libpath=['/usr/lib', '/usr/local/lib'],
>> > > > uselib_store="EXECINFO"):
>> > > > +- # Note on Darwin/OS X: This will fail, but will still be used
>> as the
>> > > > +- # execinfo stuff are part of the standard library.
>> > > > +- if sys.platform.startswith("freebsd"):
>> > > > +- conf.fatal("Install the libexecinfo port from
>> > > > /usr/ports/devel/libexecinfo.")
>> > > > ++ # OpenEmbedded doesn't like us checking here
>> > > > ++ #if not conf.check(lib="execinfo", includes=['/usr/include',
>> > > > '/usr/local/include'], libpath=['/usr/lib', '/usr/local/lib'],
>> > > > uselib_store="EXECINFO"):
>> > > > ++ # # Note on Darwin/OS X: This will fail, but will still be used
>> as the
>> > > > ++ # # execinfo stuff are part of the standard library.
>> > > > ++ # if sys.platform.startswith("freebsd"):
>> > > > ++ # conf.fatal("Install the libexecinfo port from
>> > > > /usr/ports/devel/libexecinfo.")
>> > > > +
>> > > > + if not Options.options.without_ssl:
>> > > > + if conf.check_cfg(package='openssl',
>> >
>> > Did you sent these patches upstream? Maybe document that in the patch
>> > headers. There is also a page in the Wiki regarding this.
>> >
>> > > > diff --git a/recipes/nodejs/nodejs_0.2.0.bb b/recipes/nodejs/
>> > > > nodejs_0.2.0.bb
>> > > > new file mode 100644
>> > > > index 0000000..83bfa2e
>> > > > --- /dev/null
>> > > > +++ b/recipes/nodejs/nodejs_0.2.0.bb
>> > > > @@ -0,0 +1,28 @@
>> > > > +DESCRIPTION = "nodeJS Evented I/O for V8 JavaScript"
>> > > > +HOMEPAGE = "http://nodejs.org"
>> > > > +LICENSE = "MIT"
>> > > > +DEPENDS = "openssl"
>> > > > +SRC_URI = " \
>> > > > + http://nodejs.org/dist/node-v${PV}.tar.gz<http://nodejs.org/dist/node-v$%7BPV%7D.tar.gz>\
>> > > > + file://node-cross-cc.patch \
>> > > > + file://libev-cross-cc.patch \
>> > > > + file://node-dont-include-hosts-usr-include.patch \
>> > > > +"
>> > > > +#file://libev-arm-cross.patch \
>> >
>> > Is that commented line needed?
>> >
>> > > > +SRC_URI[md5sum] = "99a6dacc44b3f9c6ec376ccb446dd0b8"
>> > > > +SRC_URI[sha256sum] =
>> > > > "3d3eff9287c9917af4044f3cef99ae5b17946710a71e83039de4fcb4b0a26631"
>> > > > +S = "${WORKDIR}/node-v${PV}"
>> > > > +do_configure () {
>> > > > + ./configure --prefix=${D} --without-snapshot
>> > > > +}
>> >
>> > Can you use `EXTRA_OECONF` (Do `git grep EXTRA_OECONF` in the repository
>> > to get examples.)
>>
>> its ok. Since its override the do_configure
>>
>> >
>> > I think you might need `inherit autotools`, but I am not sure.
>>
>>
>> no this package does not use autotools it not needed.
>>
>> >
>> > > > +do_compile () {
>> > > > + make
>> > > > +}
>> >
>> > Is that needed? What about Frans’ suggestion?
>>
>> should use oe_runmake instea of bare make to exploit parallelism.
>>
>> >
>> > > > +do_install () {
>> > > > + #oe_runmake install # doesn't install to correct location
>> > > > +
>> > > > + # This works
>> > > > + install -d ${D}${bindir}/
>> > > > + install -m 0755 ${S}/node ${D}${bindir}/
>> > > > +}
>> > > > +FILES_${PN} = "${bindir}/node"
>> >
>> > Why is that needed?
>> >
>> > I am a beginner, so I hope my comments are correct. If so please submit
>> > a v3 and do not forget your Signed-off-by line.
>>
>> right.
>> >
>> >
>> > Thanks,
>> >
>> > Paul
>>
>>
>>
>> > _______________________________________________
>> > Openembedded-devel mailing list
>> > Openembedded-devel@lists.openembedded.org
>> > http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-devel
>>
>>
>> _______________________________________________
>> Openembedded-devel mailing list
>> Openembedded-devel@lists.openembedded.org
>> http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-devel
>>
>
>
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2010-08-27 17:41 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-08-22 3:28 [PATCH] [v2] added recipe for nodejs AJ ONeal
2010-08-23 23:22 ` AJ ONeal
2010-08-23 23:57 ` Paul Menzel
2010-08-27 4:04 ` Khem Raj
2010-08-27 5:54 ` AJ ONeal
2010-08-27 17:40 ` AJ ONeal
2010-08-24 1:18 ` Jason Kridner
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.