spidermonkey185: New package.
PATCH 1/2 spidermonkey185: New package.
This is the old 1.8.5 branch of spidermonkey, used in Firefox 4. It is rather unmaintained, but some software still depend on it.
---
There are many ugly things in here, I would like your advice/opinion on whether this package can be upstreamable.
This commit is based on the 'next' branch.
package/Config.in | 1 + .../0001-fix-arm-compiler-flags.patch | 340 ++ .../0002-regenerate-configure.patch | 5397 ++++++++++++++++++++ package/spidermonkey185/Config.in | 15 + package/spidermonkey185/spidermonkey185.hash | 2 + package/spidermonkey185/spidermonkey185.mk | 51 + 6 files changed, 5806 insertions(+) create mode 100644 package/spidermonkey185/0001-fix-arm-compiler-flags.patch create mode 100644 package/spidermonkey185/0002-regenerate-configure.patch create mode 100644 package/spidermonkey185/Config.in create mode 100644 package/spidermonkey185/spidermonkey185.hash create mode 100644 package/spidermonkey185/spidermonkey185.mk
package/Config.in +1 -0
@@ -762,6 +762,7 @@ menu "External python modules" endmenu endif source "package/ruby/Config.in" + source "package/spidermonkey185/Config.in" source "package/tcl/Config.in" if BR2_PACKAGE_TCL menu "Tcl libraries/modules"
package/spidermonkey185/0001-fix-arm-compiler-flags.patch new file +340 -0
340 lines not on this page · raw message
package/spidermonkey185/0002-regenerate-configure.patch new file +5397 -0
2,653 lines not on this page · raw message
package/spidermonkey185/Config.in new file +15 -0
Lines of this file are not shown. View the raw message.
package/spidermonkey185/spidermonkey185.hash new file +2 -0
Lines of this file are not shown. View the raw message.
package/spidermonkey185/spidermonkey185.mk new file +51 -0
51 lines not on this page · raw message
The rest of this diff is not shown. View the raw message.
Signature · 1 line
2.8.1
Part of the diff is not shown here. View the raw message.
PATCH 2/2 couchdb: New package.
--- package/Config.in | 1 + package/couchdb/0001-remove-unsafe-paths.patch | 41 ++++++++++++++++++++ package/couchdb/Config.in | 22 +++++++++++ package/couchdb/S96prepare-couchdb | 5 +++ package/couchdb/couchdb.hash | 7 ++++ package/couchdb/couchdb.mk | 52 ++++++++++++++++++++++++++ 6 files changed, 128 insertions(+) create mode 100644 package/couchdb/0001-remove-unsafe-paths.patch create mode 100644 package/couchdb/Config.in create mode 100644 package/couchdb/S96prepare-couchdb create mode 100644 package/couchdb/couchdb.hash create mode 100644 package/couchdb/couchdb.mk
package/Config.in +1 -0
@@ -861,6 +861,7 @@ endmenu menu "Database" source "package/berkeleydb/Config.in" + source "package/couchdb/Config.in" source "package/cppdb/Config.in" source "package/gdbm/Config.in" source "package/kompexsqlite/Config.in"
package/couchdb/0001-remove-unsafe-paths.patch new file +41 -0
41 lines not on this page · raw message
package/couchdb/Config.in new file +22 -0
@@ -0,0 +1,22 @@ +comment "CouchDB need a toolchain with C++, wchar, threads, dynamic libs." + depends on !BR2_BINFMT_FLAT + depends on BR2_USE_MMU + depends on BR2_PACKAGE_LIBATOMIC_OPS_ARCH_SUPPORTS + depends on !BR2_TOOLCHAIN_HAS_THREADS || \ + BR2_STATIC_LIBS || !BR2_INSTALL_LIBSTDCPP || !BR2_USE_WCHAR + +config BR2_PACKAGE_COUCHDB + bool "couchdb" + depends on BR2_TOOLCHAIN_HAS_THREADS # icu + depends on !BR2_BINFMT_FLAT # icu + depends on BR2_USE_MMU # erlang, spidermonkey185 + depends on !BR2_STATIC_LIBS # erlang + depends on BR2_PACKAGE_LIBATOMIC_OPS_ARCH_SUPPORTS # erlang + depends on BR2_INSTALL_LIBSTDCPP # icu, spidermonkey185 + depends on BR2_USE_WCHAR # icu + + select BR2_PACKAGE_ERLANG + select BR2_PACKAGE_ICU + select BR2_PACKAGE_OPENSSL + select BR2_PACKAGE_SPIDERMONKEY185 + select BR2_PACKAGE_LIBCURL
package/couchdb/S96prepare-couchdb new file +5 -0
@@ -0,0 +1,5 @@ +#!/bin/sh +case "$1" in + start) + install -d -o couchdb /var/log/couchdb;; +esac
package/couchdb/couchdb.hash new file +7 -0
@@ -0,0 +1,7 @@ +# From https://archive.apache.org/dist/couchdb/source/1.6.1/apache-couchdb-1.6.1.tar.gz.{md5,sha} +sha1 6275f3818579d7b307052e9735c42a8a64313229 apache-couchdb-1.6.1.tar.gz +md5 01a2c8ab4fcde457529428993901a060 apache-couchdb-1.6.1.tar.gz + +# Locally generated after checking PGP signature +sha256 5a601b173733ce3ed31b654805c793aa907131cd70b06d03825f169aa48c8627 apache-couchdb-1.6.1.tar.gz +
package/couchdb/couchdb.mk new file +52 -0
52 lines not on this page · raw message
Signature · 1 line
2.8.1
PATCH 2/2 couchdb: New package.
Quoted 1 line · Nicolas Cavallari
Signed-off-by Nicolas Cavallari <[email protected]>
My first reaction was: can't we use a more recent version from git instead of
an almost-two-years-old release, but that won't be easy because of all the submodules.
Just small comments all over.
Quoted 14 lines
--- package/Config.in | 1 + package/couchdb/0001-remove-unsafe-paths.patch | 41 ++++++++++++++++++++ package/couchdb/Config.in | 22 +++++++++++ package/couchdb/S96prepare-couchdb | 5 +++ package/couchdb/couchdb.hash | 7 ++++ package/couchdb/couchdb.mk | 52 ++++++++++++++++++++++++++ 6 files changed, 128 insertions(+) create mode 100644 package/couchdb/0001-remove-unsafe-paths.patch create mode 100644 package/couchdb/Config.in create mode 100644 package/couchdb/S96prepare-couchdb create mode 100644 package/couchdb/couchdb.hash create mode 100644 package/couchdb/couchdb.mk
[snip]
Quoted 12 lines
package/couchdb/Config.in new file +6
-0@@ -0,0 +1,22 @@ +comment "CouchDB need a toolchain with C++, wchar, threads, dynamic libs." + depends on !BR2_BINFMT_FLAT + depends on BR2_USE_MMU + depends on BR2_PACKAGE_LIBATOMIC_OPS_ARCH_SUPPORTS + depends on !BR2_TOOLCHAIN_HAS_THREADS || \ + BR2_STATIC_LIBS || !BR2_INSTALL_LIBSTDCPP || !BR2_USE_WCHAR
package/couchdb/Config.in line 16
Quoted 10 lines
package/couchdb/Config.in new file +10
-0+ +config BR2_PACKAGE_COUCHDB + bool "couchdb" + depends on BR2_TOOLCHAIN_HAS_THREADS # icu + depends on !BR2_BINFMT_FLAT # icu + depends on BR2_USE_MMU # erlang, spidermonkey185 + depends on !BR2_STATIC_LIBS # erlang + depends on BR2_PACKAGE_LIBATOMIC_OPS_ARCH_SUPPORTS # erlang + depends on BR2_INSTALL_LIBSTDCPP # icu, spidermonkey185 + depends on BR2_USE_WCHAR # icu
Could you order the dependencies with arch deps first, and then toolchain deps?
So it's consistent with the comment deps.
Quoted 12 lines
package/couchdb/Config.in new file +6
-0+ + select BR2_PACKAGE_ERLANG + select BR2_PACKAGE_ICU + select BR2_PACKAGE_OPENSSL + select BR2_PACKAGE_SPIDERMONKEY185 + select BR2_PACKAGE_LIBCURLpackage/couchdb/S96prepare-couchdb new file +0
-0
package/couchdb/S96prepare-couchdb line 4
Quoted 4 lines
package/couchdb/S96prepare-couchdb new file +4
-0@@ -0,0 +1,5 @@ +#!/bin/sh +case "$1" in + start) + install -d -o couchdb /var/log/couchdb;;
I like this solution for creating the log directory!
Should group be set to couchdb as well?
Quoted 7 lines
package/couchdb/S96prepare-couchdb new file +1
-0+esacpackage/couchdb/couchdb.hash new file +0
-0
package/couchdb/couchdb.hash line 7
Quoted 7 lines
package/couchdb/couchdb.hash new file +7
-0@@ -0,0 +1,7 @@ +# From https://archive.apache.org/dist/couchdb/source/1.6.1/apache-couchdb-1.6.1.tar.gz.{md5,sha} +sha1 6275f3818579d7b307052e9735c42a8a64313229 apache-couchdb-1.6.1.tar.gz +md5 01a2c8ab4fcde457529428993901a060 apache-couchdb-1.6.1.tar.gz + +# Locally generated after checking PGP signature +sha256 5a601b173733ce3ed31b654805c793aa907131cd70b06d03825f169aa48c8627 apache-couchdb-1.6.1.tar.gz +
Redundant empty line.
Quoted 12 lines
package/couchdb/couchdb.mk new file +6
-0@@ -0,0 +1,52 @@ +################################################################################ +# +# CouchDB +# +################################################################################ +
package/couchdb/couchdb.mk line 16
Quoted 10 lines
package/couchdb/couchdb.mk new file +10
-0+COUCHDB_VERSION = 1.6.1 +COUCHDB_SITE = \ + http://archive.apache.org/dist/couchdb/source/${COUCHDB_VERSION} +COUCHDB_SOURCE = apache-couchdb-${COUCHDB_VERSION}.tar.gz + +COUCHDB_LICENSE = Apache-2.0 +COUCHDB_LICENSE_FILES = LICENSE + +COUCHDB_DEPENDENCIES = host-autoconf-archive host-pkgconf \ + openssl icu libcurl spidermonkey185 erlang host-pkgconf
You got host-pkgconf twice. Sort them alphabetically to avoid that.
Quoted 4 lines
package/couchdb/couchdb.mk new file +4
-0+ +# configure.ac is patched. +COUCHDB_AUTORECONF = YES +COUCHDB_AUTORECONF_OPTS = -I $(HOST_DIR)/usr/share/autoconf-archive
package/couchdb/couchdb.mk line 30
Quoted 10 lines
package/couchdb/couchdb.mk new file +10
-0+ +COUCHDB_CONF_ENV = \ + CURL_CONFIG=$(STAGING_DIR)/usr/bin/curl-config \ + ICU_CONFIG=$(STAGING_DIR)/usr/bin/icu-config +COUCHDB_CONF_OPTS = --disable-init + +# CouchDB's build system mixes the erl for the host and the erl for the +# target. +define COUCHDB_FIX_ERL_PATH + sed -i -re 's*$(HOST_DIR)**' \
We usually use , and sometimes %, not *.
package/couchdb/couchdb.mk line 39
Quoted 9 lines
package/couchdb/couchdb.mk new file +9
-0+ $(TARGET_DIR)/usr/bin/couchdb \ + $(TARGET_DIR)/usr/bin/couch-config +endef +COUCHDB_POST_INSTALL_TARGET_HOOKS += COUCHDB_FIX_ERL_PATH + +define COUCHDB_INSTALL_INIT_SYSV +install -m 755 -D $(@D)/etc/init/couchdb $(TARGET_DIR)/etc/init.d/S97couchdb +install -m 755 package/couchdb/S96prepare-couchdb $(TARGET_DIR)/etc/init.d/ +install -m 755 -D $(@D)/etc/default/couchdb $(TARGET_DIR)/etc/default/couchdb
Stuff inside "define" is indented with a tab.
package/couchdb/couchdb.mk line 43
Quoted 4 lines
package/couchdb/couchdb.mk new file +4
-0+endef + +define COUCHDB_USERS +couchdb -1 couchdb -1 ! - /bin/sh - CouchDB Server
Same here.
package/couchdb/couchdb.mk line 48
Quoted 5 lines
package/couchdb/couchdb.mk new file +5
-0+endef + +define COUCHDB_PERMISSIONS +/etc/couchdb r 755 couchdb couchdb - - - - +/var/lib/couchdb d 750 couchdb couchdb - - - -
Same here.
Regards,
Arnout
Quoted 5 lines
package/couchdb/couchdb.mk new file +4
-0+endef + +$(eval $(autotools-package)) +
Signature · 6 lines
Arnout Vandecappelle arnout at mind be Senior Embedded Software Architect +32-16-286500 Essensium/Mind http://www.mind.be G.Geenslaan 9, 3001 Leuven, Belgium BE 872 984 063 RPR Leuven LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle GPG fingerprint: 7493 020B C7E3 8618 8DEC 222C 82EB F404 F9AC 0DDF
PATCH 2/2 couchdb: New package.
Hello,
Quoted 6 lines · Arnout Vandecappelle
Quoted 1 line · Nicolas Cavallari
Signed-off-by Nicolas Cavallari <[email protected]>My first reaction was: can't we use a more recent version from git instead of
an almost-two-years-old release, but that won't be easy because of all the submodules.
Does the latest git versions also need spidermonkey 1.8.5 ?
If not, then I think I'd prefer to add support to fetch submodules (we already have patches doing this, from Yann, and they are reasonable), and skip the addition of this unmaintained spidermonkey thing.
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons Embedded Linux, Kernel and Android engineering http://free-electrons.com
PATCH 2/2 couchdb: New package.
Quoted 11 lines · Thomas Petazzoni
Hello,
Quoted 6 lines · Arnout Vandecappelle
Quoted 1 line · Nicolas Cavallari
Signed-off-by Nicolas Cavallari <[email protected]>My first reaction was: can't we use a more recent version from git instead of
an almost-two-years-old release, but that won't be easy because of all the submodules.Does the latest git versions also need spidermonkey 1.8.5 ?
Yes, Unfortunately...
Quoted 3 lines
If not, then I think I'd prefer to add support to fetch submodules (we already have patches doing this, from Yann, and they are reasonable), and skip the addition of this unmaintained spidermonkey thing.
These are not git submodules, they are submodules as in "./configure git-clone them". Plus there are even more hardcoded /usr/include paths in their build system. It seems wiser to wait for a tarball.
PATCH 2/2 couchdb: New package.
Hello,
Quoted 7 lines · Nicolas Cavallari
Quoted 5 lines
Quoted 3 lines
My first reaction was: can't we use a more recent version from git instead of
an almost-two-years-old release, but that won't be easy because of all the submodules.Does the latest git versions also need spidermonkey 1.8.5 ?
Yes, Unfortunately...
Yerk.
Quoted 7 lines
Quoted 3 lines
If not, then I think I'd prefer to add support to fetch submodules (we already have patches doing this, from Yann, and they are reasonable), and skip the addition of this unmaintained spidermonkey thing.
These are not git submodules, they are submodules as in "./configure git-clone them". Plus there are even more hardcoded
/usr/includepaths in their build system. It seems wiser to wait for a tarball.
and yerk.
Do we want to package couchdb ? :-)
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons Embedded Linux, Kernel and Android engineering http://free-electrons.com
PATCH 2/2 couchdb: New package.
Am Fri, 20 May 2016 16:29:29 +0200 schrieb Thomas Petazzoni:
Quoted 1 line
Do we want to package couchdb ? :-)
Hi,
I use couchdb regularly to download wikipedia using
https://github.com/itkach/mwscrape
https://github.com/itkach/mwscrape2slob
on my workstation. Being able in the future to do that on my buildroot- based server, which is online 24/7, would be nice to have ;)
Regards, Bernd
PATCH 2/2 couchdb: New package.
In reply to Thomas PetazzoniQuoted 1 line
Do we want to package couchdb ? :-)
In case you still do, here's an updated version of the patches.
Couchdb 2.0 is way to immature to attempt to package it now: --prefix does not work and is hardwired to '.', there is no "make install", it depends on unreleased libraries... So even with a self-built tarball, it's still not ready for being packaged.
I've somewhat test compiled spidermonkey on several architectures where debian's patches implied there would be problem and fixed them by taking patches from upstream. I also addressed the minor nits on Couchdb 1.6.1.
PATCH v2 1/2 spidermonkey185: New package.
This is the old 1.8.5 branch of spidermonkey, used in Firefox 4. It is rather unmaintained, but some software still depend on it, such as couchdb.
---
v1 -> v2:
* Moved package to Libraries/Other
* Tried to make the package reconfigurable, but stopped when the patch grew even larger than previous patches. Instead, simplified the patch to not force a specific arm version, to make the configure patch smaller.
* Added patches to fix DESTDIR being embedded in the symlink and remove the leftover nspr dependency.
* Added comment on why we define symbols for the host compiler.
* Added upstream patches to fix problems on various architectures, taking inspiration for the patches that Debian uses.
* Disabled the JIT on sparc64 because that does not compile.
* Added host-perl and host-python, because they are used to build.
* Changed license as per Arnout suggestion
package/Config.in | 1 + ...01-remove-unused-pkgconfg-nspr-dependency.patch | 18 + .../0002-make-shlib-synlink-relative.patch | 21 + .../spidermonkey185/0003-remove-forced-armv5.patch | 40 ++ .../0004-regenerate-configure.patch | 470 +++++++++++++++++++++ ...val_layout-on-64-bit-big-endian-platforms.patch | 90 ++++ ...tatic-assert-fix-strict-aliasing-warnings.patch | 93 ++++ ...heFlush-support-error-on-exotic-platforms.patch | 33 ++ package/spidermonkey185/Config.in | 14 + package/spidermonkey185/spidermonkey185.hash | 2 + package/spidermonkey185/spidermonkey185.mk | 33 ++ 11 files changed, 815 insertions(+) create mode 100644 package/spidermonkey185/0001-remove-unused-pkgconfg-nspr-dependency.patch create mode 100644 package/spidermonkey185/0002-make-shlib-synlink-relative.patch create mode 100644 package/spidermonkey185/0003-remove-forced-armv5.patch create mode 100644 package/spidermonkey185/0004-regenerate-configure.patch create mode 100644 package/spidermonkey185/0005-Fix-jsval_layout-on-64-bit-big-endian-platforms.patch create mode 100644 package/spidermonkey185/0006-Remove-bad-static-assert-fix-strict-aliasing-warnings.patch create mode 100644 package/spidermonkey185/0007-Avoid-missing-cacheFlush-support-error-on-exotic-platforms.patch create mode 100644 package/spidermonkey185/Config.in create mode 100644 package/spidermonkey185/spidermonkey185.hash create mode 100644 package/spidermonkey185/spidermonkey185.mk
package/Config.in +1 -0
@@ -1284,6 +1284,7 @@ endif source "package/protobuf-c/Config.in" source "package/qhull/Config.in" source "package/qlibc/Config.in" + source "package/spidermonkey185/Config.in" source "package/startup-notification/Config.in" source "package/tz/Config.in" source "package/tzdata/Config.in"
package/spidermonkey185/0001-remove-unused-pkgconfg-nspr-dependency.patch new file +18 -0
@@ -0,0 +1,18 @@ +From: Nicolas Cavallari <[email protected]> + +Remove the dependency on nspr. + +This dependency was removed when spidermonkey was extracted from the +mozilla code base. This is probably a left-over, since it is not used. + +Signed-off-by: Nicolas Cavallari <[email protected]> + +--- spidermonkey185-1.0.0/js/src/mozjs185.pc.in 2016-05-23 13:41:28.430466213 +0200 ++++ spidermonkey185-1.0.0/js/src/mozjs185.pc.in 2016-05-23 13:42:00.727558977 +0200 +@@ -5,6 +5,5 @@ + Name: SpiderMonkey 1.8.5 + Description: The Mozilla library for JavaScript 1.8.5 + Version: %MOZILLA_VERSION% +-Requires: nspr >= 4.7 + Libs: -L${libdir} -lmozjs185 + Cflags: -I${includedir}/js
package/spidermonkey185/0002-make-shlib-synlink-relative.patch new file +21 -0
@@ -0,0 +1,21 @@ +From: Nicolas Cavallari <[email protected]> + +Fix the creation of the shared library symbolic links. + +Do not create absolute symbolic links that references DESTDIR. + +Signed-off-by: Nicolas Cavallari <[email protected]> + +--- spidermonkey185-1.0.0/js/src/Makefile.in 2016-05-23 13:49:39.535010860 +0200 ++++ spidermonkey185-1.0.0/js/src/Makefile.in 2016-05-23 13:50:06.555917036 +0200 +@@ -888,8 +888,8 @@ + ifeq (,$(HOST_BIN_SUFFIX)) + mv -f $(SHLIB_ANY_VER) $(SHLIB_EXACT_VER) + @[ ! -h $(SHLIB_ABI_VER) ] || rm -f $(SHLIB_ABI_VER) +- ln -s $(SHLIB_EXACT_VER) $(SHLIB_ABI_VER) +- ln -s $(SHLIB_ABI_VER) $(SHLIB_ANY_VER) ++ ln -s $(notdir $(SHLIB_EXACT_VER)) $(SHLIB_ABI_VER) ++ ln -s $(notdir $(SHLIB_ABI_VER)) $(SHLIB_ANY_VER) + endif + endif + ifneq (,$(IMPORT_LIBRARY))
package/spidermonkey185/0003-remove-forced-armv5.patch new file +40 -0
@@ -0,0 +1,40 @@ +From: Nicolas Cavallari <[email protected]> + +Do not force an ARM variant. + +Buildroot already passes the correct CFLAGS. + +Signed-off-by: Nicolas Cavallari <[email protected]> + +--- spidermonkey185-1.0.0/js/src/configure.in 2016-05-23 17:10:59.166657848 +0200 ++++ spidermonkey185-1.0.0/js/src/configure.in 2016-05-23 17:11:21.987444482 +0200 +@@ -4654,12 +4654,6 @@ + dnl ======================================================== + MOZ_ARG_HEADER(Individual module options) + +-dnl Setup default CPU arch for arm target +-case "$target_cpu" in +- arm*) +- MOZ_ARM_ARCH=armv7 +- ;; +-esac + dnl ======================================================== + dnl = Enable building the Thumb2 instruction set + dnl ======================================================== +@@ -4714,16 +4708,6 @@ + AC_MSG_ERROR([--with-cpu-arch=armv7 is not supported for non-ARM CPU architectures]) + ;; + esac +-else +- case "$target_cpu" in +- arm*) +- if test "$GNU_CC"; then +- CFLAGS="$CFLAGS -march=armv5te -mthumb-interwork -msoft-float" +- CXXFLAGS="$CXXFLAGS -march=armv5te -mthumb-interwork -msoft-float" +- ASFLAGS="$ASFLAGS -march=armv5te -mthumb-interwork -msoft-float" +- fi +- ;; +- esac + fi + + AC_SUBST(MOZ_THUMB2)
package/spidermonkey185/0004-regenerate-configure.patch new file +470 -0
470 lines not on this page · raw message
package/spidermonkey185/0005-Fix-jsval_layout-on-64-bit-big-endian-platforms.patch new file +90 -0
90 lines not on this page · raw message
package/spidermonkey185/0006-Remove-bad-static-assert-fix-strict-aliasing-warnings.patch new file +93 -0
93 lines not on this page · raw message
package/spidermonkey185/0007-Avoid-missing-cacheFlush-support-error-on-exotic-platforms.patch new file +33 -0
@@ -0,0 +1,33 @@ + +# HG changeset patch +# User Mike Hommey <[email protected]> +# Date 1303461188 -7200 +# Node ID 59771590e9203d48ef8cbcd7eaf2f8ae45dbb1c1 +# Parent c4b82ec27d6d6e1c02ef0abb3b6e805bfdd092ec +Bug 638056 - Avoid "The cacheFlush support is missing on this platform" error on exotic platforms. r=cdleary + +[nicolas.cavallari at green-communications.fr: refresh patch] + +diff --git a/js/src/Makefile.in b/js/src/Makefile.in +--- a/js/src/Makefile.in ++++ b/js/src/Makefile.in +@@ -377,17 +377,17 @@ CPPSRCS += checks.cc \ + platform.cc \ + utils.cc \ + $(NONE) + + # + # END enclude sources for V8 dtoa + ############################################# + +-ifeq (,$(filter-out powerpc sparc,$(TARGET_CPU))) ++ifeq (,$(filter arm %86 x86_64,$(TARGET_CPU))) + + VPATH += $(srcdir)/assembler \ + $(srcdir)/assembler/wtf \ + $(srcdir)/yarr/pcre \ + $(NULL) + + CPPSRCS += pcre_compile.cpp \ + pcre_exec.cpp \ +
package/spidermonkey185/Config.in new file +14 -0
@@ -0,0 +1,14 @@ +config BR2_PACKAGE_SPIDERMONKEY185 + bool "spidermonkey (1.8.5)" + depends on BR2_USE_MMU # fork in executable tools. + depends on BR2_INSTALL_LIBSTDCPP + depends on BR2_TOOLCHAIN_HAS_THREADS + help + SpiderMonkey is Mozilla's JavaScript engine written in C/C++. It is + used in various Mozilla products, including Firefox. + + This is the old 1.8.5 branch, used in Firefox 4. + +comment "Spider monkey (1.8.5) need a toolchain with C++, threads" + depends on BR2_USE_MMU + depends on !BR2_INSTALL_LIBSTDCPP || !BR2_TOOLCHAIN_HAS_THREADS
package/spidermonkey185/spidermonkey185.hash new file +2 -0
@@ -0,0 +1,2 @@ +# Locally generated. +sha256 5d12f7e1f5b4a99436685d97b9b7b75f094d33580227aa998c406bbae6f2a687 js185-1.0.0.tar.gz
package/spidermonkey185/spidermonkey185.mk new file +33 -0
@@ -0,0 +1,33 @@ +################################################################################ +# +# Spidermonkey (1.8.5) +# +################################################################################ + +SPIDERMONKEY185_VERSION = 1.0.0 +SPIDERMONKEY185_SITE = http://ftp.mozilla.org/pub/js +SPIDERMONKEY185_SOURCE = js185-${SPIDERMONKEY185_VERSION}.tar.gz + +SPIDERMONKEY185_INSTALL_STAGING = YES + +SPIDERMONKEY185_DEPENDENCIES = host-python host-perl + +SPIDERMONKEY185_LICENSE = MPLv1.1 or GPLv2.0+ or LGPLv2.1+ + +SPIDERMONKEY185_SUBDIR = js/src + +# This define is used by jscpucfg.cpp which is normally used to runtime-detect +# the system endianess. +SPIDERMONKEY185_CONF_ENV = \ + HOST_CXXFLAGS="$(HOST_CXXFLAGS) -DFORCE_$(BR2_ENDIAN)_ENDIAN" + +# Mozilla mixes up target, host and build. See the comment in configure.in +# around line 360. Also, nanojit fails to build on sparc64 with +# #error "unknown nanojit architecture", so disable the JIT. +SPIDERMONKEY185_CONF_OPTS = \ + --target=$(GNU_TARGET_NAME) \ + --build=$(GNU_TARGET_NAME) \ + --host=$(GNU_HOST_NAME) \ + $(if $(BR2_sparc64),--disable-tracejit) + +$(eval $(autotools-package))
Signature · 1 line
2.8.1
PATCH v2 1/2 spidermonkey185: New package.
Hi Nicolas, all,
Thanks for your patch, I look forward to have spidermonkey, because we can then update polkit, which is a long standing issue for me. My comments are inline.
Some of your patches did not apply on the sources, I would recommend that you extract the sources, then move the directory somehere and do a 'git init' then 'git add . && git commit -m "init"' and work in that directory, when you are finished you can use 'git format-patch HEAD~n' and collect your patch in a mailbox format.
Don't forget to add your SoB to the patches.
I have marked your two patches as "Changes Requested", you only have to resend your patches when they are amended (of course you don't have to agree on all the comments, feel free to discuss).
package/spidermonkey185/0002-make-shlib-synlink-relative.patch
Quoted 82 lines · Nicolas Cavallari
This is the old 1.8.5 branch of spidermonkey, used in Firefox 4. It is rather unmaintained, but some software still depend on it, such as couchdb.
Signed-off-by Nicolas Cavallari <[email protected]>---
v1 -> v2:
* Moved package to Libraries/Other
* Tried to make the package reconfigurable, but stopped when the patch grew even larger than previous patches. Instead, simplified the patch to not force a specific arm version, to make the configure patch smaller.
* Added patches to fix DESTDIR being embedded in the symlink and remove the leftover nspr dependency.
* Added comment on why we define symbols for the host compiler.
* Added upstream patches to fix problems on various architectures, taking inspiration for the patches that Debian uses.
* Disabled the JIT on sparc64 because that does not compile.
* Added host-perl and host-python, because they are used to build.
* Changed license as per Arnout suggestionpackage/Config.in | 1 + ...01-remove-unused-pkgconfg-nspr-dependency.patch | 18 + .../0002-make-shlib-synlink-relative.patch | 21 + .../spidermonkey185/0003-remove-forced-armv5.patch | 40 ++ .../0004-regenerate-configure.patch | 470 +++++++++++++++++++++ ...val_layout-on-64-bit-big-endian-platforms.patch | 90 ++++ ...tatic-assert-fix-strict-aliasing-warnings.patch | 93 ++++ ...heFlush-support-error-on-exotic-platforms.patch | 33 ++ package/spidermonkey185/Config.in | 14 + package/spidermonkey185/spidermonkey185.hash | 2 + package/spidermonkey185/spidermonkey185.mk | 33 ++ 11 files changed, 815 insertions(+) create mode 100644 package/spidermonkey185/0001-remove-unused-pkgconfg-nspr-dependency.patch create mode 100644 package/spidermonkey185/0002-make-shlib-synlink-relative.patch create mode 100644 package/spidermonkey185/0003-remove-forced-armv5.patch create mode 100644 package/spidermonkey185/0004-regenerate-configure.patch create mode 100644 package/spidermonkey185/0005-Fix-jsval_layout-on-64-bit-big-endian-platforms.patch create mode 100644 package/spidermonkey185/0006-Remove-bad-static-assert-fix-strict-aliasing-warnings.patch create mode 100644 package/spidermonkey185/0007-Avoid-missing-cacheFlush-support-error-on-exotic-platforms.patch create mode 100644 package/spidermonkey185/Config.in create mode 100644 package/spidermonkey185/spidermonkey185.hash create mode 100644 package/spidermonkey185/spidermonkey185.mkpackage/Config.in +1
-0@@ -1284,6 +1284,7 @@ endif source "package/protobuf-c/Config.in" source "package/qhull/Config.in" source "package/qlibc/Config.in" + source "package/spidermonkey185/Config.in" source "package/startup-notification/Config.in" source "package/tz/Config.in" source "package/tzdata/Config.in"package/spidermonkey185/0001-remove-unused-pkgconfg-nspr-dependency.patch new file +18
-0@@ -0,0 +1,18 @@ +From: Nicolas Cavallari <[email protected]> + +Remove the dependency on nspr. + +This dependency was removed when spidermonkey was extracted from the +mozilla code base. This is probably a left-over, since it is not used. + +Signed-off-by: Nicolas Cavallari <[email protected]> + +--- spidermonkey185-1.0.0/js/src/mozjs185.pc.in 2016-05-23 13:41:28.430466213 +0200 ++++ spidermonkey185-1.0.0/js/src/mozjs185.pc.in 2016-05-23 13:42:00.727558977 +0200 +@@ -5,6 +5,5 @@ + Name: SpiderMonkey 1.8.5 + Description: The Mozilla library for JavaScript 1.8.5 + Version: %MOZILLA_VERSION% +-Requires: nspr >= 4.7 + Libs: -L${libdir} -lmozjs185 + Cflags: -I${includedir}/jspackage/spidermonkey185/0002-make-shlib-synlink-relative.patch new file +0
-0
When I quickly grepped through the source, you can still find:
js/jsd/jsd_xpc.h:47:#include "nspr.h"
Won't that cause trouble ? Since we have libnspr, why don't we add the dependencies and be done with it ?
Quoted 60 lines
package/spidermonkey185/0002-make-shlib-synlink-relative.patch new file +21
-0@@ -0,0 +1,21 @@ +From: Nicolas Cavallari <[email protected]> + +Fix the creation of the shared library symbolic links. + +Do not create absolute symbolic links that references DESTDIR. + +Signed-off-by: Nicolas Cavallari <[email protected]> + +--- spidermonkey185-1.0.0/js/src/Makefile.in 2016-05-23 13:49:39.535010860 +0200 ++++ spidermonkey185-1.0.0/js/src/Makefile.in 2016-05-23 13:50:06.555917036 +0200 +@@ -888,8 +888,8 @@ + ifeq (,$(HOST_BIN_SUFFIX)) + mv -f $(SHLIB_ANY_VER) $(SHLIB_EXACT_VER) + @[ ! -h $(SHLIB_ABI_VER) ] || rm -f $(SHLIB_ABI_VER) +- ln -s $(SHLIB_EXACT_VER) $(SHLIB_ABI_VER) +- ln -s $(SHLIB_ABI_VER) $(SHLIB_ANY_VER) ++ ln -s $(notdir $(SHLIB_EXACT_VER)) $(SHLIB_ABI_VER) ++ ln -s $(notdir $(SHLIB_ABI_VER)) $(SHLIB_ANY_VER) + endif + endif + ifneq (,$(IMPORT_LIBRARY))package/spidermonkey185/0003-remove-forced-armv5.patch new file +30
-0@@ -0,0 +1,40 @@ +From: Nicolas Cavallari <[email protected]> + +Do not force an ARM variant. + +Buildroot already passes the correct CFLAGS. + +Signed-off-by: Nicolas Cavallari <[email protected]> + +--- spidermonkey185-1.0.0/js/src/configure.in 2016-05-23 17:10:59.166657848 +0200 ++++ spidermonkey185-1.0.0/js/src/configure.in 2016-05-23 17:11:21.987444482 +0200 +@@ -4654,12 +4654,6 @@ + dnl ======================================================== + MOZ_ARG_HEADER(Individual module options) + +-dnl Setup default CPU arch for arm target +-case "$target_cpu" in +- arm*) +- MOZ_ARM_ARCH=armv7 +- ;; +-esac + dnl ======================================================== + dnl = Enable building the Thumb2 instruction set + dnl ======================================================== +@@ -4714,16 +4708,6 @@ + AC_MSG_ERROR([--with-cpu-arch=armv7 is not supported for non-ARM CPU architectures]) + ;; + esac +-else +- case "$target_cpu" in +- arm*)
package/spidermonkey185/0003-remove-forced-armv5.patch line 40
Quoted 10 lines
package/spidermonkey185/0003-remove-forced-armv5.patch new file +10
-0+- if test "$GNU_CC"; then +- CFLAGS="$CFLAGS -march=armv5te -mthumb-interwork -msoft-float" +- CXXFLAGS="$CXXFLAGS -march=armv5te -mthumb-interwork -msoft-float" +- ASFLAGS="$ASFLAGS -march=armv5te -mthumb-interwork -msoft-float" +- fi +- ;; +- esac + fi + + AC_SUBST(MOZ_THUMB2)
Can't you patch the configure straight away so we don't have the ugly patch that rewrite the configure script ?
Quoted 751 lines
package/spidermonkey185/0004-regenerate-configure.patch new file +470
-0@@ -0,0 +1,470 @@ +From: Nicolas Cavallari <[email protected]> + +Use the antique autoconf2.13 to regenerate the configure script. + +Signed-off-by: Nicolas Cavallari <[email protected]> + +--- spidermonkey185-1.0.0/js/src/configure 2016-05-25 11:26:19.392163540 +0200 ++++ spidermonkey185-1.0.0/js/src/configure 2016-05-25 11:26:28.704477125 +0200 +@@ -13264,11 +13264,6 @@ + + # Individual module options + +-case "$target_cpu" in +- arm*) +- MOZ_ARM_ARCH=armv7 +- ;; +-esac + # Check whether --enable-thumb2 or --disable-thumb2 was given. + if test "${enable_thumb2+set}" = set; then + enableval="$enable_thumb2" +@@ -13337,16 +13332,6 @@ + { echo "configure: error: --with-cpu-arch=armv7 is not supported for non-ARM CPU architectures" 1>&2; exit 1; } + ;; + esac +-else +- case "$target_cpu" in +- arm*) +- if test "$GNU_CC"; then +- CFLAGS="$CFLAGS -march=armv5te -mthumb-interwork -msoft-float" +- CXXFLAGS="$CXXFLAGS -march=armv5te -mthumb-interwork -msoft-float" +- ASFLAGS="$ASFLAGS -march=armv5te -mthumb-interwork -msoft-float" +- fi +- ;; +- esac + fi + + +@@ -13389,18 +13374,18 @@ + + if test -n "$MOZ_DEBUG"; then + echo $ac_n "checking for valid debug flags""... $ac_c" 1>&6 +-echo "configure:13393: checking for valid debug flags" >&5 ++echo "configure:13378: checking for valid debug flags" >&5 + _SAVE_CFLAGS=$CFLAGS + CFLAGS="$CFLAGS $MOZ_DEBUG_FLAGS" + cat > conftest.$ac_ext <<EOF +-#line 13397 "configure" ++#line 13382 "configure" + #include "confdefs.h" + #include <stdio.h> + int main() { + printf("Hello World\n"); + ; return 0; } + EOF +-if { (eval echo configure:13404: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then ++if { (eval echo configure:13389: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + _results=yes + else +@@ -13441,18 +13426,18 @@ + if test "$COMPILE_ENVIRONMENT"; then + if test -n "$MOZ_OPTIMIZE"; then + echo $ac_n "checking for valid optimization flags""... $ac_c" 1>&6 +-echo "configure:13445: checking for valid optimization flags" >&5 ++echo "configure:13430: checking for valid optimization flags" >&5 + _SAVE_CFLAGS=$CFLAGS + CFLAGS="$CFLAGS $MOZ_OPTIMIZE_FLAGS" + cat > conftest.$ac_ext <<EOF +-#line 13449 "configure" ++#line 13434 "configure" + #include "confdefs.h" + #include <stdio.h> + int main() { + printf("Hello World\n"); + ; return 0; } + EOF +-if { (eval echo configure:13456: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then ++if { (eval echo configure:13441: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + _results=yes + else +@@ -13581,7 +13566,7 @@ + fi + else + echo $ac_n "checking size of int *""... $ac_c" 1>&6 +-echo "configure:13585: checking size of int *" >&5 ++echo "configure:13570: checking size of int *" >&5 + if eval "test \"`echo '$''{'ac_cv_sizeof_int_p'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else +@@ -13589,9 +13574,10 @@ + ac_cv_sizeof_int_p=4 + else + cat > conftest.$ac_ext <<EOF +-#line 13593 "configure" ++#line 13578 "configure" + #include "confdefs.h" + #include <stdio.h> ++#include <sys/types.h> + main() + { + FILE *f=fopen("conftestval", "w"); +@@ -13600,7 +13586,7 @@ + exit(0); + } + EOF +-if { (eval echo configure:13604: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null ++if { (eval echo configure:13590: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null + then + ac_cv_sizeof_int_p=`cat conftestval` + else +@@ -13847,17 +13833,17 @@ + if test -n "$MOZ_VALGRIND"; then + ac_safe=`echo "valgrind/valgrind.h" | sed 'y%./+-%__p_%'` + echo $ac_n "checking for valgrind/valgrind.h""... $ac_c" 1>&6 +-echo "configure:13851: checking for valgrind/valgrind.h" >&5 ++echo "configure:13837: checking for valgrind/valgrind.h" >&5 + if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext <<EOF +-#line 13856 "configure" ++#line 13842 "configure" + #include "confdefs.h" + #include <valgrind/valgrind.h> + EOF + ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +-{ (eval echo configure:13861: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ++{ (eval echo configure:13847: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } + ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` + if test -z "$ac_err"; then + rm -rf conftest* +@@ -14012,7 +13998,7 @@ + # Extract the first word of "$ac_prog", so it can be a program name with args. + set dummy $ac_prog; ac_word=$2 + echo $ac_n "checking for $ac_word""... $ac_c" 1>&6 +-echo "configure:14016: checking for $ac_word" >&5 ++echo "configure:14002: checking for $ac_word" >&5 + if eval "test \"`echo '$''{'ac_cv_path_CCACHE'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else +@@ -14163,12 +14149,12 @@ + for ac_func in __cxa_demangle + do + echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +-echo "configure:14167: checking for $ac_func" >&5 ++echo "configure:14153: checking for $ac_func" >&5 + if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext <<EOF +-#line 14172 "configure" ++#line 14158 "configure" + #include "confdefs.h" + /* System header to define __stub macros and hopefully few prototypes, + which can conflict with char $ac_func(); below. */ +@@ -14194,7 +14180,7 @@ + + ; return 0; } + EOF +-if { (eval echo configure:14198: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ++if { (eval echo configure:14184: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_func_$ac_func=yes" + else +@@ -14242,17 +14228,17 @@ + if test "$HAVE_GCC3_ABI" -a -z "$SKIP_LIBRARY_CHECKS"; then + ac_safe=`echo "unwind.h" | sed 'y%./+-%__p_%'` + echo $ac_n "checking for unwind.h""... $ac_c" 1>&6 +-echo "configure:14246: checking for unwind.h" >&5 ++echo "configure:14232: checking for unwind.h" >&5 + if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext <<EOF +-#line 14251 "configure" ++#line 14237 "configure" + #include "confdefs.h" + #include <unwind.h> + EOF + ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out" +-{ (eval echo configure:14256: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } ++{ (eval echo configure:14242: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; } + ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"` + if test -z "$ac_err"; then + rm -rf conftest* +@@ -14271,12 +14257,12 @@ + for ac_func in _Unwind_Backtrace + do + echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +-echo "configure:14275: checking for $ac_func" >&5 ++echo "configure:14261: checking for $ac_func" >&5 + if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext <<EOF +-#line 14280 "configure" ++#line 14266 "configure" + #include "confdefs.h" + /* System header to define __stub macros and hopefully few prototypes, + which can conflict with char $ac_func(); below. */ +@@ -14299,7 +14285,7 @@ + + ; return 0; } + EOF +-if { (eval echo configure:14303: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ++if { (eval echo configure:14289: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_func_$ac_func=yes" + else +@@ -14348,7 +14334,7 @@ + # Compiler Options + + echo $ac_n "checking for gcc -pipe support""... $ac_c" 1>&6 +-echo "configure:14352: checking for gcc -pipe support" >&5 ++echo "configure:14338: checking for gcc -pipe support" >&5 + if test -n "$GNU_CC" -a -n "$GNU_CXX" -a -n "$GNU_AS"; then + echo '#include <stdio.h>' > dummy-hello.c + echo 'int main() { printf("Hello World\n"); exit(0); }' >> dummy-hello.c +@@ -14363,14 +14349,14 @@ + _SAVE_CFLAGS=$CFLAGS + CFLAGS="$CFLAGS -pipe" + cat > conftest.$ac_ext <<EOF +-#line 14367 "configure" ++#line 14353 "configure" + #include "confdefs.h" + #include <stdio.h> + int main() { + printf("Hello World\n"); + ; return 0; } + EOF +-if { (eval echo configure:14374: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then ++if { (eval echo configure:14360: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + _res_gcc_pipe="yes" + else +@@ -14415,16 +14401,16 @@ + CFLAGS="$CFLAGS -fprofile-generate -fprofile-correction" + + echo $ac_n "checking whether C compiler supports -fprofile-generate""... $ac_c" 1>&6 +-echo "configure:14419: checking whether C compiler supports -fprofile-generate" >&5 ++echo "configure:14405: checking whether C compiler supports -fprofile-generate" >&5 + cat > conftest.$ac_ext <<EOF +-#line 14421 "configure" ++#line 14407 "configure" + #include "confdefs.h" + + int main() { + return 0; + ; return 0; } + EOF +-if { (eval echo configure:14428: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then ++if { (eval echo configure:14414: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + PROFILE_GEN_CFLAGS="-fprofile-generate" + result="yes" +@@ -14488,16 +14474,16 @@ + _SAVE_CXXFLAGS=$CXXFLAGS + CXXFLAGS="$CXXFLAGS ${_WARNINGS_CXXFLAGS} ${_COMPILER_PREFIX}-pedantic ${_COMPILER_PREFIX}-Wno-long-long" + echo $ac_n "checking whether C++ compiler has -pedantic long long bug""... $ac_c" 1>&6 +-echo "configure:14492: checking whether C++ compiler has -pedantic long long bug" >&5 ++echo "configure:14478: checking whether C++ compiler has -pedantic long long bug" >&5 + cat > conftest.$ac_ext <<EOF +-#line 14494 "configure" ++#line 14480 "configure" + #include "confdefs.h" + $configure_static_assert_macros + int main() { + CONFIGURE_STATIC_ASSERT(sizeof(long long) == 8) + ; return 0; } + EOF +-if { (eval echo configure:14501: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then ++if { (eval echo configure:14487: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + result="no" + else +@@ -14522,12 +14508,12 @@ + fi + + echo $ac_n "checking for correct temporary object destruction order""... $ac_c" 1>&6 +-echo "configure:14526: checking for correct temporary object destruction order" >&5 ++echo "configure:14512: checking for correct temporary object destruction order" >&5 + if test "$cross_compiling" = yes; then + result="maybe" + else + cat > conftest.$ac_ext <<EOF +-#line 14531 "configure" ++#line 14517 "configure" + #include "confdefs.h" + #ifdef __cplusplus + extern "C" void exit(int); +@@ -14550,7 +14536,7 @@ + } + + EOF +-if { (eval echo configure:14554: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null ++if { (eval echo configure:14540: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null + then + result="yes" + else +@@ -14571,12 +14557,12 @@ + _SAVE_CXXFLAGS=$CXXFLAGS + CXXFLAGS="$CXXFLAGS ${_WARNINGS_CXXFLAGS}" + echo $ac_n "checking for correct overload resolution with const and templates""... $ac_c" 1>&6 +-echo "configure:14575: checking for correct overload resolution with const and templates" >&5 ++echo "configure:14561: checking for correct overload resolution with const and templates" >&5 + if eval "test \"`echo '$''{'ac_nscap_nonconst_opeq_bug'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext <<EOF +-#line 14580 "configure" ++#line 14566 "configure" + #include "confdefs.h" + + template <class T> +@@ -14606,7 +14592,7 @@ + + ; return 0; } + EOF +-if { (eval echo configure:14610: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then ++if { (eval echo configure:14596: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_nscap_nonconst_opeq_bug="no" + else +@@ -14629,19 +14615,19 @@ + fi + + echo $ac_n "checking for tm_zone tm_gmtoff in struct tm""... $ac_c" 1>&6 +-echo "configure:14633: checking for tm_zone tm_gmtoff in struct tm" >&5 ++echo "configure:14619: checking for tm_zone tm_gmtoff in struct tm" >&5 + if eval "test \"`echo '$''{'ac_cv_struct_tm_zone_tm_gmtoff'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext <<EOF +-#line 14638 "configure" ++#line 14624 "configure" + #include "confdefs.h" + #include <time.h> + int main() { + struct tm tm; tm.tm_zone = 0; tm.tm_gmtoff = 1; + ; return 0; } + EOF +-if { (eval echo configure:14645: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then ++if { (eval echo configure:14631: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + rm -rf conftest* + ac_cv_struct_tm_zone_tm_gmtoff="yes" + else +@@ -14855,7 +14841,7 @@ + if test -z "$SKIP_LIBRARY_CHECKS" -a -z "$NO_EDITLINE"; then + if test -n "$JS_WANT_READLINE"; then + echo $ac_n "checking for readline in -lreadline""... $ac_c" 1>&6 +-echo "configure:14859: checking for readline in -lreadline" >&5 ++echo "configure:14845: checking for readline in -lreadline" >&5 + ac_lib_var=`echo readline'_'readline | sed 'y%./+-%__p_%'` + if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 +@@ -14863,7 +14849,7 @@ + ac_save_LIBS="$LIBS" + LIBS="-lreadline $LIBS" + cat > conftest.$ac_ext <<EOF +-#line 14867 "configure" ++#line 14853 "configure" + #include "confdefs.h" + /* Override any gcc2 internal prototype to avoid an error. */ + /* We use char because int might match the return type of a gcc2 +@@ -14874,7 +14860,7 @@ + readline() + ; return 0; } + EOF +-if { (eval echo configure:14878: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ++if { (eval echo configure:14864: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_lib_$ac_lib_var=yes" + else +@@ -15123,9 +15109,9 @@ + fi + + echo $ac_n "checking for posix_fallocate""... $ac_c" 1>&6 +-echo "configure:15127: checking for posix_fallocate" >&5 ++echo "configure:15113: checking for posix_fallocate" >&5 + cat > conftest.$ac_ext <<EOF +-#line 15129 "configure" ++#line 15115 "configure" + #include "confdefs.h" + #define _XOPEN_SOURCE 600 + #include <fcntl.h> +@@ -15133,7 +15119,7 @@ + posix_fallocate(0, 0, 0); + ; return 0; } + EOF +-if { (eval echo configure:15137: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ++if { (eval echo configure:15123: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + ac_cv___posix_fallocate=true + else +@@ -15159,7 +15145,7 @@ + _SAVE_CFLAGS=$CFLAGS + CFLAGS="$CFLAGS $XCFLAGS" + cat > conftest.$ac_ext <<EOF +-#line 15163 "configure" ++#line 15149 "configure" + #include "confdefs.h" + + #include <stdio.h> +@@ -15177,7 +15163,7 @@ + + ; return 0; } + EOF +-if { (eval echo configure:15181: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then ++if { (eval echo configure:15167: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then + : + else + echo "configure: failed program was:" >&5 +@@ -15278,12 +15264,12 @@ + for ac_func in setlocale + do + echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +-echo "configure:15282: checking for $ac_func" >&5 ++echo "configure:15268: checking for $ac_func" >&5 + if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext <<EOF +-#line 15287 "configure" ++#line 15273 "configure" + #include "confdefs.h" + /* System header to define __stub macros and hopefully few prototypes, + which can conflict with char $ac_func(); below. */ +@@ -15306,7 +15292,7 @@ + + ; return 0; } + EOF +-if { (eval echo configure:15310: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ++if { (eval echo configure:15296: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_func_$ac_func=yes" + else +@@ -15333,12 +15319,12 @@ + for ac_func in localeconv + do + echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 +-echo "configure:15337: checking for $ac_func" >&5 ++echo "configure:15323: checking for $ac_func" >&5 + if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + cat > conftest.$ac_ext <<EOF +-#line 15342 "configure" ++#line 15328 "configure" + #include "confdefs.h" + /* System header to define __stub macros and hopefully few prototypes, + which can conflict with char $ac_func(); below. */ +@@ -15361,7 +15347,7 @@ + + ; return 0; } + EOF +-if { (eval echo configure:15365: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then ++if { (eval echo configure:15351: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then + rm -rf conftest* + eval "ac_cv_func_$ac_func=yes" + else +@@ -16291,7 +16277,7 @@ + fi + fi + +- cd $ac_popdir ++ cd "$ac_popdir" + done + fi +package/spidermonkey185/0005-Fix-jsval_layout-on-64-bit-big-endian-platforms.patch new file +90
-0@@ -0,0 +1,90 @@ + +# HG changeset patch +# User Luke Wagner <[email protected]> +# Date 1312494575 25200 +# Node ID 1d186a5f3a96e938a253726ac48ecaf00e80c712 +# Parent cd0106ceb8ce337636875ef7b1f0d143cb33b7a4 +Bug 674522 - Fix jsval_layout on 64-bit big-endian platforms (r=waldo) + +[nicolas.cavallari at green-communications.fr: refresh patch] + +diff --git a/js/src/jsval.h b/js/src/jsval.h +--- a/js/src/jsval.h ++++ b/js/src/jsval.h +@@ -301,17 +301,16 @@ typedef union jsval_layout + JSValueTag tag : 17; + } debugView; + #endif + struct { + union { + int32 i32; + uint32 u32; + JSWhyMagic why; +- jsuword word; + } payload; + } s; + double asDouble; + void *asPtr; + } jsval_layout; + # endif /* JS_BITS_PER_WORD */ + #else /* defined(IS_LITTLE_ENDIAN) */ + # if JS_BITS_PER_WORD == 32 +@@ -338,28 +337,31 @@ typedef union jsval_layout + typedef union jsval_layout + { + uint64 asBits; + struct { + JSValueTag tag : 17; + uint64 payload47 : 47; + } debugView; + struct { ++ uint32 padding; + union { + int32 i32; + uint32 u32; + JSWhyMagic why; + } payload; + } s; + double asDouble; + void *asPtr; + } jsval_layout; + # endif /* JS_BITS_PER_WORD */ + #endif /* defined(IS_LITTLE_ENDIAN) */ + ++JS_STATIC_ASSERT(sizeof(jsval_layout) == 8); ++ + #if JS_BITS_PER_WORD == 32 + + /* + * N.B. GCC, in some but not all cases, chooses to emit signed comparison of + * JSValueTag even though its underlying type has been forced to be uint32. + * Thus, all comparisons should explicitly cast operands to uint32. + */ + +diff --git a/js/src/jsvalue.h b/js/src/jsvalue.h +--- a/js/src/jsvalue.h ++++ b/js/src/jsvalue.h +@@ -724,17 +724,21 @@ class Value + } + + JS_ALWAYS_INLINE + void *toUnmarkedPtr() const { + return data.asPtr; + } + + const jsuword *payloadWord() const { +- return &data.s.payload.word; ++#if JS_BITS_PER_WORD == 32 ++ return reinterpret_cast<const jsuword *>(&data.s.payload.word); ++#elif JS_BITS_PER_WORD == 64 ++ return reinterpret_cast<const jsuword *>(&data.asBits); ++#endif + } + + private: + void staticAssertions() { + JS_STATIC_ASSERT(sizeof(JSValueType) == 1); + JS_STATIC_ASSERT(sizeof(JSValueTag) == 4); + JS_STATIC_ASSERT(sizeof(JSBool) == 4); + JS_STATIC_ASSERT(sizeof(JSWhyMagic) <= 4); +package/spidermonkey185/0006-Remove-bad-static-assert-fix-strict-aliasing-warnings.patch new file +93
-0@@ -0,0 +1,93 @@ + +# HG changeset patch +# User Luke Wagner <[email protected]> +# Date 1312825636 25200 +# Node ID 6f2c0dbb88d338df44a624041f8808c9de0a9a9b +# Parent e605ebcd59845fca46a52555eb1b18e70bb3a37d +Bug 674522 - Remove bad static assert; fix strict-aliasing warnings (rs=waldo) + +[nicolas.cavallari at green-communications.fr: refresh patch] + +diff --git a/js/src/jsval.h b/js/src/jsval.h +--- a/js/src/jsval.h ++++ b/js/src/jsval.h +@@ -305,16 +305,17 @@ typedef union jsval_layout + union { + int32 i32; + uint32 u32; + JSWhyMagic why; + } payload; + } s; + double asDouble; + void *asPtr; ++ jsuword asWord; + } jsval_layout; + # endif /* JS_BITS_PER_WORD */ + #else /* defined(IS_LITTLE_ENDIAN) */ + # if JS_BITS_PER_WORD == 32 + typedef union jsval_layout + { + uint64 asBits; + struct { +@@ -346,16 +347,17 @@ typedef union jsval_layout + union { + int32 i32; + uint32 u32; + JSWhyMagic why; + } payload; + } s; + double asDouble; + void *asPtr; ++ jsuword asWord; + } jsval_layout; + # endif /* JS_BITS_PER_WORD */ + #endif /* defined(IS_LITTLE_ENDIAN) */ + + JS_STATIC_ASSERT(sizeof(jsval_layout) == 8); + + #if JS_BITS_PER_WORD == 32 + +diff --git a/js/src/jsvalue.h b/js/src/jsvalue.h +--- a/js/src/jsvalue.h ++++ b/js/src/jsvalue.h +@@ -286,17 +286,16 @@ static JS_ALWAYS_INLINE JSValueTag + JSVAL_EXTRACT_NON_DOUBLE_TAG_IMPL(jsval_layout l) + { + uint64 tag = l.asBits >> JSVAL_TAG_SHIFT; + JS_ASSERT(tag > JSVAL_TAG_MAX_DOUBLE); + return (JSValueTag)tag; + } + + #ifdef __cplusplus +-JS_STATIC_ASSERT(offsetof(jsval_layout, s.payload) == 0); + JS_STATIC_ASSERT((JSVAL_TYPE_NONFUNOBJ & 0xF) == JSVAL_TYPE_OBJECT); + JS_STATIC_ASSERT((JSVAL_TYPE_FUNOBJ & 0xF) == JSVAL_TYPE_OBJECT); + #endif + + static JS_ALWAYS_INLINE jsval_layout + BOX_NON_DOUBLE_JSVAL(JSValueType type, uint64 *slot) + { + /* N.B. for 32-bit payloads, the high 32 bits of the slot are trash. */ +@@ -725,19 +724,19 @@ class Value + + JS_ALWAYS_INLINE + void *toUnmarkedPtr() const { + return data.asPtr; + } + + const jsuword *payloadWord() const { + #if JS_BITS_PER_WORD == 32 +- return reinterpret_cast<const jsuword *>(&data.s.payload.word); ++ return &data.s.payload.word; + #elif JS_BITS_PER_WORD == 64 +- return reinterpret_cast<const jsuword *>(&data.asBits); ++ return &data.asWord; + #endif + } + + private: + void staticAssertions() { + JS_STATIC_ASSERT(sizeof(JSValueType) == 1); + JS_STATIC_ASSERT(sizeof(JSValueTag) == 4); + JS_STATIC_ASSERT(sizeof(JSBool) == 4); +package/spidermonkey185/0007-Avoid-missing-cacheFlush-support-error-on-exotic-platforms.patch new file +33
-0@@ -0,0 +1,33 @@ + +# HG changeset patch +# User Mike Hommey <[email protected]> +# Date 1303461188 -7200 +# Node ID 59771590e9203d48ef8cbcd7eaf2f8ae45dbb1c1 +# Parent c4b82ec27d6d6e1c02ef0abb3b6e805bfdd092ec +Bug 638056 - Avoid "The cacheFlush support is missing on this platform" error on exotic platforms. r=cdleary + +[nicolas.cavallari at green-communications.fr: refresh patch] + +diff --git a/js/src/Makefile.in b/js/src/Makefile.in +--- a/js/src/Makefile.in ++++ b/js/src/Makefile.in +@@ -377,17 +377,17 @@ CPPSRCS += checks.cc \ + platform.cc \ + utils.cc \ + $(NONE) + + # + # END enclude sources for V8 dtoa + ############################################# + +-ifeq (,$(filter-out powerpc sparc,$(TARGET_CPU))) ++ifeq (,$(filter arm %86 x86_64,$(TARGET_CPU))) + + VPATH += $(srcdir)/assembler \ + $(srcdir)/assembler/wtf \ + $(srcdir)/yarr/pcre \ + $(NULL) + + CPPSRCS += pcre_compile.cpp \ + pcre_exec.cpp \ +package/spidermonkey185/Config.in new file +14
-0@@ -0,0 +1,14 @@ +config BR2_PACKAGE_SPIDERMONKEY185 + bool "spidermonkey (1.8.5)" + depends on BR2_USE_MMU # fork in executable tools. + depends on BR2_INSTALL_LIBSTDCPP + depends on BR2_TOOLCHAIN_HAS_THREADS + help + SpiderMonkey is Mozilla's JavaScript engine written in C/C++. It is + used in various Mozilla products, including Firefox. + + This is the old 1.8.5 branch, used in Firefox 4. + +comment "Spider monkey (1.8.5) need a toolchain with C++, threads" + depends on BR2_USE_MMU + depends on !BR2_INSTALL_LIBSTDCPP || !BR2_TOOLCHAIN_HAS_THREADSpackage/spidermonkey185/spidermonkey185.hash new file +2
-0@@ -0,0 +1,2 @@ +# Locally generated. +sha256 5d12f7e1f5b4a99436685d97b9b7b75f094d33580227aa998c406bbae6f2a687 js185-1.0.0.tar.gzpackage/spidermonkey185/spidermonkey185.mk new file +7
-0@@ -0,0 +1,33 @@ +################################################################################ +# +# Spidermonkey (1.8.5) +# +################################################################################ + +SPIDERMONKEY185_VERSION = 1.0.0
package/spidermonkey185/spidermonkey185.mk line 17
Quoted 10 lines
package/spidermonkey185/spidermonkey185.mk new file +10
-0+SPIDERMONKEY185_SITE = http://ftp.mozilla.org/pub/js +SPIDERMONKEY185_SOURCE = js185-${SPIDERMONKEY185_VERSION}.tar.gz + +SPIDERMONKEY185_INSTALL_STAGING = YES + +SPIDERMONKEY185_DEPENDENCIES = host-python host-perl + +SPIDERMONKEY185_LICENSE = MPLv1.1 or GPLv2.0+ or LGPLv2.1+ + +SPIDERMONKEY185_SUBDIR = js/src
Don't put empty lines between all these lines. I would put the SUBDIR option right below the SOURCE option.
Quoted 4 lines
package/spidermonkey185/spidermonkey185.mk new file +4
-0+ +# This define is used by jscpucfg.cpp which is normally used to runtime-detect +# the system endianess. +SPIDERMONKEY185_CONF_ENV = \
package/spidermonkey185/spidermonkey185.mk line 31
Quoted 10 lines
package/spidermonkey185/spidermonkey185.mk new file +10
-0+ HOST_CXXFLAGS="$(HOST_CXXFLAGS) -DFORCE_$(BR2_ENDIAN)_ENDIAN" + +# Mozilla mixes up target, host and build. See the comment in configure.in +# around line 360. Also, nanojit fails to build on sparc64 with +# #error "unknown nanojit architecture", so disable the JIT. +SPIDERMONKEY185_CONF_OPTS = \ + --target=$(GNU_TARGET_NAME) \ + --build=$(GNU_TARGET_NAME) \ + --host=$(GNU_HOST_NAME) \ + $(if $(BR2_sparc64),--disable-tracejit)
In your patch, there's two tab here so the indent is off.
Quoted 9 lines
package/spidermonkey185/spidermonkey185.mk new file +2
-1+ +$(eval $(autotools-package)) --2.8.1
_______________________________________________
buildroot mailing list
buildroot at busybox.net
http://lists.busybox.net/mailman/listinfo/buildroot
PATCH v2 1/2 spidermonkey185: New package.
Quoted 11 lines · Maxime Hadjinlian
Hi Nicolas, all,
Thanks for your patch, I look forward to have spidermonkey, because we can then update polkit, which is a long standing issue for me. My comments are inline.
Some of your patches did not apply on the sources, I would recommend that you extract the sources, then move the directory somehere and do a 'git init' then 'git add . && git commit -m "init"' and work in that directory, when you are finished you can use 'git format-patch HEAD~n' and collect your patch in a mailbox format.
It works for me. How/why does it fails for you ?
Quoted 1 line
Quoted 1 line
Quoted 1 line
spidermonkey185 1.0.0 Patching
Applying 0001-remove-unused-pkgconfg-nspr-dependency.patch using patch:
patching file js/src/mozjs185.pc.in
Applying 0002-make-shlib-synlink-relative.patch using patch:
patching file js/src/Makefile.in
Applying 0003-remove-forced-armv5.patch using patch:
patching file js/src/configure.in
Applying 0004-regenerate-configure.patch using patch:
patching file js/src/configure
Applying 0005-Fix-jsval_layout-on-64-bit-big-endian-platforms.patch using patch:
patching file js/src/jsval.h
patching file js/src/jsvalue.h
Applying 0006-Remove-bad-static-assert-fix-strict-aliasing-warnings.patch using patch:
patching file js/src/jsval.h
patching file js/src/jsvalue.h
Applying 0007-Avoid-missing-cacheFlush-support-error-on-exotic-platforms.patch using patch:
patching file js/src/Makefile.in
Quoted 1 line
Don't forget to add your SoB to the patches.
I added SoB lines to patches that I wrote. Should i add SoB to patches that i didn't write, but merely picked from upstream and backported/refreshed ?
Quoted 92 lines
I have marked your two patches as "Changes Requested", you only have to resend your patches when they are amended (of course you don't have to agree on all the comments, feel free to discuss).
package/spidermonkey185/0002-make-shlib-synlink-relative.patch
Quoted 82 lines · Nicolas Cavallari
This is the old 1.8.5 branch of spidermonkey, used in Firefox 4. It is rather unmaintained, but some software still depend on it, such as couchdb.
Signed-off-by Nicolas Cavallari <[email protected]>---
v1 -> v2:
* Moved package to Libraries/Other
* Tried to make the package reconfigurable, but stopped when the patch grew even larger than previous patches. Instead, simplified the patch to not force a specific arm version, to make the configure patch smaller.
* Added patches to fix DESTDIR being embedded in the symlink and remove the leftover nspr dependency.
* Added comment on why we define symbols for the host compiler.
* Added upstream patches to fix problems on various architectures, taking inspiration for the patches that Debian uses.
* Disabled the JIT on sparc64 because that does not compile.
* Added host-perl and host-python, because they are used to build.
* Changed license as per Arnout suggestionpackage/Config.in | 1 + ...01-remove-unused-pkgconfg-nspr-dependency.patch | 18 + .../0002-make-shlib-synlink-relative.patch | 21 + .../spidermonkey185/0003-remove-forced-armv5.patch | 40 ++ .../0004-regenerate-configure.patch | 470 +++++++++++++++++++++ ...val_layout-on-64-bit-big-endian-platforms.patch | 90 ++++ ...tatic-assert-fix-strict-aliasing-warnings.patch | 93 ++++ ...heFlush-support-error-on-exotic-platforms.patch | 33 ++ package/spidermonkey185/Config.in | 14 + package/spidermonkey185/spidermonkey185.hash | 2 + package/spidermonkey185/spidermonkey185.mk | 33 ++ 11 files changed, 815 insertions(+) create mode 100644 package/spidermonkey185/0001-remove-unused-pkgconfg-nspr-dependency.patch create mode 100644 package/spidermonkey185/0002-make-shlib-synlink-relative.patch create mode 100644 package/spidermonkey185/0003-remove-forced-armv5.patch create mode 100644 package/spidermonkey185/0004-regenerate-configure.patch create mode 100644 package/spidermonkey185/0005-Fix-jsval_layout-on-64-bit-big-endian-platforms.patch create mode 100644 package/spidermonkey185/0006-Remove-bad-static-assert-fix-strict-aliasing-warnings.patch create mode 100644 package/spidermonkey185/0007-Avoid-missing-cacheFlush-support-error-on-exotic-platforms.patch create mode 100644 package/spidermonkey185/Config.in create mode 100644 package/spidermonkey185/spidermonkey185.hash create mode 100644 package/spidermonkey185/spidermonkey185.mkpackage/Config.in +1
-0@@ -1284,6 +1284,7 @@ endif source "package/protobuf-c/Config.in" source "package/qhull/Config.in" source "package/qlibc/Config.in" + source "package/spidermonkey185/Config.in" source "package/startup-notification/Config.in" source "package/tz/Config.in" source "package/tzdata/Config.in"package/spidermonkey185/0001-remove-unused-pkgconfg-nspr-dependency.patch new file +18
-0@@ -0,0 +1,18 @@ +From: Nicolas Cavallari <[email protected]> + +Remove the dependency on nspr. + +This dependency was removed when spidermonkey was extracted from the +mozilla code base. This is probably a left-over, since it is not used. + +Signed-off-by: Nicolas Cavallari <[email protected]> + +--- spidermonkey185-1.0.0/js/src/mozjs185.pc.in 2016-05-23 13:41:28.430466213 +0200 ++++ spidermonkey185-1.0.0/js/src/mozjs185.pc.in 2016-05-23 13:42:00.727558977 +0200 +@@ -5,6 +5,5 @@ + Name: SpiderMonkey 1.8.5 + Description: The Mozilla library for JavaScript 1.8.5 + Version: %MOZILLA_VERSION% +-Requires: nspr >= 4.7 + Libs: -L${libdir} -lmozjs185 + Cflags: -I${includedir}/jspackage/spidermonkey185/0002-make-shlib-synlink-relative.patch new file +0
-0When I quickly grepped through the source, you can still find:
js/jsd/jsd_xpc.h:47:#include "nspr.h"
Quoted 2 lines
Won't that cause trouble ? Since we have libnspr, why don't we add the dependencies and be done with it ?
Anything outside of js/src is ignored. Specifically, js/jsd has no complete build system (there is Makefile.in, but no configure script), so it cannot cause any problem.
And why should we re-add libnspr when upstream did massive patches to get rid of it, even if they missed some places ?
Quoted 40 lines
Quoted 40 lines
package/spidermonkey185/0003-remove-forced-armv5.patch new file +34
-0@@ -0,0 +1,40 @@ +From: Nicolas Cavallari <[email protected]> + +Do not force an ARM variant. + +Buildroot already passes the correct CFLAGS. + +Signed-off-by: Nicolas Cavallari <[email protected]> + +--- spidermonkey185-1.0.0/js/src/configure.in 2016-05-23 17:10:59.166657848 +0200 ++++ spidermonkey185-1.0.0/js/src/configure.in 2016-05-23 17:11:21.987444482 +0200 +@@ -4654,12 +4654,6 @@ + dnl ======================================================== + MOZ_ARG_HEADER(Individual module options) + +-dnl Setup default CPU arch for arm target +-case "$target_cpu" in +- arm*) +- MOZ_ARM_ARCH=armv7 +- ;; +-esac + dnl ======================================================== + dnl = Enable building the Thumb2 instruction set + dnl ======================================================== +@@ -4714,16 +4708,6 @@ + AC_MSG_ERROR([--with-cpu-arch=armv7 is not supported for non-ARM CPU architectures]) + ;; + esac +-else +- case "$target_cpu" in +- arm*) +- if test "$GNU_CC"; then +- CFLAGS="$CFLAGS -march=armv5te -mthumb-interwork -msoft-float" +- CXXFLAGS="$CXXFLAGS -march=armv5te -mthumb-interwork -msoft-float" +- ASFLAGS="$ASFLAGS -march=armv5te -mthumb-interwork -msoft-float"
Quoted 8 lines
package/spidermonkey185/0003-remove-forced-armv5.patch line 40
Quoted 6 lines
package/spidermonkey185/0003-remove-forced-armv5.patch new file +6
-0+- fi +- ;; +- esac + fi + + AC_SUBST(MOZ_THUMB2)Can't you patch the configure straight away so we don't have the ugly patch that rewrite the configure script ?
I can. I considered that, but I though it was too ugly, especially having line numbers in error messages that do not match the script.
Quoted 18 lines
Quoted 18 lines
[...]
package/spidermonkey185/spidermonkey185.mk new file +11
-0@@ -0,0 +1,33 @@ +################################################################################ +# +# Spidermonkey (1.8.5) +# +################################################################################ + +SPIDERMONKEY185_VERSION = 1.0.0 +SPIDERMONKEY185_SITE = http://ftp.mozilla.org/pub/js +SPIDERMONKEY185_SOURCE = js185-${SPIDERMONKEY185_VERSION}.tar.gz + +SPIDERMONKEY185_INSTALL_STAGING = YES
Quoted 8 lines
package/spidermonkey185/spidermonkey185.mk line 17
Quoted 6 lines
package/spidermonkey185/spidermonkey185.mk new file +6
-0+ +SPIDERMONKEY185_DEPENDENCIES = host-python host-perl + +SPIDERMONKEY185_LICENSE = MPLv1.1 or GPLv2.0+ or LGPLv2.1+ + +SPIDERMONKEY185_SUBDIR = js/srcDon't put empty lines between all these lines. I would put the SUBDIR option right below the SOURCE option.
ok
Quoted 7 lines
Quoted 7 lines
package/spidermonkey185/spidermonkey185.mk new file +7
-0+ +# This define is used by jscpucfg.cpp which is normally used to runtime-detect +# the system endianess. +SPIDERMONKEY185_CONF_ENV = \ + HOST_CXXFLAGS="$(HOST_CXXFLAGS) -DFORCE_$(BR2_ENDIAN)_ENDIAN" + +# Mozilla mixes up target, host and build. See the comment in configure.in
Quoted 8 lines
package/spidermonkey185/spidermonkey185.mk line 31
Quoted 7 lines
package/spidermonkey185/spidermonkey185.mk new file +7
-0+# around line 360. Also, nanojit fails to build on sparc64 with +# #error "unknown nanojit architecture", so disable the JIT. +SPIDERMONKEY185_CONF_OPTS = \ + --target=$(GNU_TARGET_NAME) \ + --build=$(GNU_TARGET_NAME) \ + --host=$(GNU_HOST_NAME) \ + $(if $(BR2_sparc64),--disable-tracejit)In your patch, there's two tab here so the indent is off.
ok
PATCH v2 1/2 spidermonkey185: New package.
Hi Nicolas, all
Quoted 7 lines · Nicolas Cavallari
Quoted 6 lines · Maxime Hadjinlian
Hi Nicolas, all,
Thanks for your patch, I look forward to have spidermonkey, because we can then update polkit, which is a long standing issue for me. My comments are inline.
Quoted 7 lines
Quoted 5 lines
Some of your patches did not apply on the sources, I would recommend that you extract the sources, then move the directory somehere and do a 'git init' then 'git add . && git commit -m "init"' and work in that directory, when you are finished you can use 'git format-patch HEAD~n' and collect your patch in a mailbox format.
It works for me. How/why does it fails for you ?
There's two problem on my side.
First when I try to git-am your patch on top of the actual master I get this:
Applying patch #632988 using 'git am -s'
Description: [1/2,v2] spidermonkey185: New package.
Applying: spidermonkey185: New package. .git/rebase-apply/patch:93: space before tab in indent.
mv -f $(SHLIB_ANY_VER) $(SHLIB_EXACT_VER)
.git/rebase-apply/patch:94: space before tab in indent.
@[ ! -h $(SHLIB_ABI_VER) ] || rm -f $(SHLIB_ABI_VER)
.git/rebase-apply/patch:121: trailing whitespace.
.git/rebase-apply/patch:146: trailing whitespace.
.git/rebase-apply/patch:163: trailing whitespace.
error: patch failed: package/Config.in:1284
error: package/Config.in: patch does not apply
Patch failed at 0001 spidermonkey185: New package.
The copy of the patch that failed is found in: .git/rebase-apply/patch When you have resolved this problem, run "git am --continue". If you prefer to skip this patch, run "git am --skip" instead. To restore the original branch and stop patching, run "git am --abort".
So I have to use patch -p1 to apply it by hand, I removed my git configuration but to no avail.
The second part is Buildroot applying the patches in your patch but it appears to be something in my git config, probably because there's some line ending mixes between Windows/Linux or things like that. I am using git.core.apply.whitespace=fix, maybe that's not an important issue.
Quoted 32 lines
Quoted 2 lines
Quoted 2 lines
Quoted 2 lines
spidermonkey185 1.0.0 Patching
Applying 0001-remove-unused-pkgconfg-nspr-dependency.patch using patch:
patching file js/src/mozjs185.pc.inApplying 0002-make-shlib-synlink-relative.patch using patch:
patching file js/src/Makefile.inApplying 0003-remove-forced-armv5.patch using patch:
patching file js/src/configure.inApplying 0004-regenerate-configure.patch using patch:
patching file js/src/configureApplying 0005-Fix-jsval_layout-on-64-bit-big-endian-platforms.patch using patch:
patching filejs/src/jsval.h
patching filejs/src/jsvalue.hApplying 0006-Remove-bad-static-assert-fix-strict-aliasing-warnings.patch using patch:
patching filejs/src/jsval.h
patching filejs/src/jsvalue.hApplying 0007-Avoid-missing-cacheFlush-support-error-on-exotic-platforms.patch using patch:
patching file js/src/Makefile.in
Quoted 5 lines
Quoted 1 line
Don't forget to add your SoB to the patches.
I added SoB lines to patches that I wrote. Should i add SoB to patches that i didn't write, but merely picked from upstream and backported/refreshed ?
Yes because theses patches passed through you. A SoB is the traceability chain of a patch if you will.
Quoted 96 lines
Quoted 93 lines
I have marked your two patches as "Changes Requested", you only have to resend your patches when they are amended (of course you don't have to agree on all the comments, feel free to discuss).
package/spidermonkey185/0002-make-shlib-synlink-relative.patch
Quoted 82 lines · Nicolas Cavallari
This is the old 1.8.5 branch of spidermonkey, used in Firefox 4. It is rather unmaintained, but some software still depend on it, such as couchdb.
Signed-off-by Nicolas Cavallari <[email protected]>---
v1 -> v2:
* Moved package to Libraries/Other
* Tried to make the package reconfigurable, but stopped when the patch grew even larger than previous patches. Instead, simplified the patch to not force a specific arm version, to make the configure patch smaller.
* Added patches to fix DESTDIR being embedded in the symlink and remove the leftover nspr dependency.
* Added comment on why we define symbols for the host compiler.
* Added upstream patches to fix problems on various architectures, taking inspiration for the patches that Debian uses.
* Disabled the JIT on sparc64 because that does not compile.
* Added host-perl and host-python, because they are used to build.
* Changed license as per Arnout suggestionpackage/Config.in | 1 + ...01-remove-unused-pkgconfg-nspr-dependency.patch | 18 + .../0002-make-shlib-synlink-relative.patch | 21 + .../spidermonkey185/0003-remove-forced-armv5.patch | 40 ++ .../0004-regenerate-configure.patch | 470 +++++++++++++++++++++ ...val_layout-on-64-bit-big-endian-platforms.patch | 90 ++++ ...tatic-assert-fix-strict-aliasing-warnings.patch | 93 ++++ ...heFlush-support-error-on-exotic-platforms.patch | 33 ++ package/spidermonkey185/Config.in | 14 + package/spidermonkey185/spidermonkey185.hash | 2 + package/spidermonkey185/spidermonkey185.mk | 33 ++ 11 files changed, 815 insertions(+) create mode 100644 package/spidermonkey185/0001-remove-unused-pkgconfg-nspr-dependency.patch create mode 100644 package/spidermonkey185/0002-make-shlib-synlink-relative.patch create mode 100644 package/spidermonkey185/0003-remove-forced-armv5.patch create mode 100644 package/spidermonkey185/0004-regenerate-configure.patch create mode 100644 package/spidermonkey185/0005-Fix-jsval_layout-on-64-bit-big-endian-platforms.patch create mode 100644 package/spidermonkey185/0006-Remove-bad-static-assert-fix-strict-aliasing-warnings.patch create mode 100644 package/spidermonkey185/0007-Avoid-missing-cacheFlush-support-error-on-exotic-platforms.patch create mode 100644 package/spidermonkey185/Config.in create mode 100644 package/spidermonkey185/spidermonkey185.hash create mode 100644 package/spidermonkey185/spidermonkey185.mkpackage/Config.in +1
-0@@ -1284,6 +1284,7 @@ endif source "package/protobuf-c/Config.in" source "package/qhull/Config.in" source "package/qlibc/Config.in" + source "package/spidermonkey185/Config.in" source "package/startup-notification/Config.in" source "package/tz/Config.in" source "package/tzdata/Config.in"package/spidermonkey185/0001-remove-unused-pkgconfg-nspr-dependency.patch new file +18
-0@@ -0,0 +1,18 @@ +From: Nicolas Cavallari <[email protected]> + +Remove the dependency on nspr. + +This dependency was removed when spidermonkey was extracted from the +mozilla code base. This is probably a left-over, since it is not used. + +Signed-off-by: Nicolas Cavallari <[email protected]> + +--- spidermonkey185-1.0.0/js/src/mozjs185.pc.in 2016-05-23 13:41:28.430466213 +0200 ++++ spidermonkey185-1.0.0/js/src/mozjs185.pc.in 2016-05-23 13:42:00.727558977 +0200 +@@ -5,6 +5,5 @@ + Name: SpiderMonkey 1.8.5 + Description: The Mozilla library for JavaScript 1.8.5 + Version: %MOZILLA_VERSION% +-Requires: nspr >= 4.7 + Libs: -L${libdir} -lmozjs185 + Cflags: -I${includedir}/jspackage/spidermonkey185/0002-make-shlib-synlink-relative.patch new file +0
-0When I quickly grepped through the source, you can still find:
js/jsd/jsd_xpc.h:47:#include "nspr.h"Quoted 2 lines
Won't that cause trouble ? Since we have libnspr, why don't we add the dependencies and be done with it ?
Quoted 6 lines
Anything outside of js/src is ignored. Specifically, js/jsd has no complete build system (there is Makefile.in, but no configure script), so it cannot cause any problem.
And why should we re-add libnspr when upstream did massive patches to get rid of it, even if they missed some places ?
Ok, it's indeed a small patch and if the file in question is not even touched there's no harm.
There's no link to what does upstream as it's a deprecated version and it will never be updated anymore.
Quoted 50 lines
Quoted 41 lines
Quoted 41 lines
package/spidermonkey185/0003-remove-forced-armv5.patch new file +34
-0@@ -0,0 +1,40 @@ +From: Nicolas Cavallari <[email protected]> + +Do not force an ARM variant. + +Buildroot already passes the correct CFLAGS. + +Signed-off-by: Nicolas Cavallari <[email protected]> + +--- spidermonkey185-1.0.0/js/src/configure.in 2016-05-23 17:10:59.166657848 +0200 ++++ spidermonkey185-1.0.0/js/src/configure.in 2016-05-23 17:11:21.987444482 +0200 +@@ -4654,12 +4654,6 @@ + dnl ======================================================== + MOZ_ARG_HEADER(Individual module options) + +-dnl Setup default CPU arch for arm target +-case "$target_cpu" in +- arm*) +- MOZ_ARM_ARCH=armv7 +- ;; +-esac + dnl ======================================================== + dnl = Enable building the Thumb2 instruction set + dnl ======================================================== +@@ -4714,16 +4708,6 @@ + AC_MSG_ERROR([--with-cpu-arch=armv7 is not supported for non-ARM CPU architectures]) + ;; + esac +-else +- case "$target_cpu" in +- arm*) +- if test "$GNU_CC"; then +- CFLAGS="$CFLAGS -march=armv5te -mthumb-interwork -msoft-float" +- CXXFLAGS="$CXXFLAGS -march=armv5te -mthumb-interwork -msoft-float" +- ASFLAGS="$ASFLAGS -march=armv5te -mthumb-interwork -msoft-float"Quoted 8 lines
package/spidermonkey185/0003-remove-forced-armv5.patch line 40
Quoted 6 lines
package/spidermonkey185/0003-remove-forced-armv5.patch new file +6
-0+- fi +- ;; +- esac + fi + + AC_SUBST(MOZ_THUMB2)Can't you patch the configure straight away so we don't have the ugly patch that rewrite the configure script ?
Quoted 2 lines
I can. I considered that, but I though it was too ugly, especially having line numbers in error messages that do not match the script.
The less patch the better usually. And especially with the 'configure' one, because it's a huge patch. If you patch the 'configure' file directly, it's gonna be smaller, and since it's a deprecated version, it won't change through time so it's easier to maintain.
Quoted 47 lines
Quoted 19 lines
Quoted 19 lines
[...]
package/spidermonkey185/spidermonkey185.mk new file +11
-0@@ -0,0 +1,33 @@ +################################################################################ +# +# Spidermonkey (1.8.5) +# +################################################################################ + +SPIDERMONKEY185_VERSION = 1.0.0 +SPIDERMONKEY185_SITE = http://ftp.mozilla.org/pub/js +SPIDERMONKEY185_SOURCE = js185-${SPIDERMONKEY185_VERSION}.tar.gz + +SPIDERMONKEY185_INSTALL_STAGING = YESQuoted 8 lines
package/spidermonkey185/spidermonkey185.mk line 17
Quoted 6 lines
package/spidermonkey185/spidermonkey185.mk new file +6
-0+ +SPIDERMONKEY185_DEPENDENCIES = host-python host-perl + +SPIDERMONKEY185_LICENSE = MPLv1.1 or GPLv2.0+ or LGPLv2.1+ + +SPIDERMONKEY185_SUBDIR = js/srcDon't put empty lines between all these lines. I would put the SUBDIR option right below the SOURCE option.
ok
Quoted 7 lines
Quoted 7 lines
package/spidermonkey185/spidermonkey185.mk new file +7
-0+ +# This define is used by jscpucfg.cpp which is normally used to runtime-detect +# the system endianess. +SPIDERMONKEY185_CONF_ENV = \ + HOST_CXXFLAGS="$(HOST_CXXFLAGS) -DFORCE_$(BR2_ENDIAN)_ENDIAN" + +# Mozilla mixes up target, host and build. See the comment in configure.inQuoted 8 lines
package/spidermonkey185/spidermonkey185.mk line 31
Quoted 7 lines
package/spidermonkey185/spidermonkey185.mk new file +7
-0+# around line 360. Also, nanojit fails to build on sparc64 with +# #error "unknown nanojit architecture", so disable the JIT. +SPIDERMONKEY185_CONF_OPTS = \ + --target=$(GNU_TARGET_NAME) \ + --build=$(GNU_TARGET_NAME) \ + --host=$(GNU_HOST_NAME) \ + $(if $(BR2_sparc64),--disable-tracejit)In your patch, there's two tab here so the indent is off.
ok
PATCH v2 1/2 spidermonkey185: New package.
Quoted 18 lines · Maxime Hadjinlian
Hi Nicolas, all
Quoted 7 lines · Nicolas Cavallari
Quoted 6 lines · Maxime Hadjinlian
Hi Nicolas, all,
Thanks for your patch, I look forward to have spidermonkey, because we can then update polkit, which is a long standing issue for me. My comments are inline.
Quoted 7 lines
Quoted 5 lines
Some of your patches did not apply on the sources, I would recommend that you extract the sources, then move the directory somehere and do a 'git init' then 'git add . && git commit -m "init"' and work in that directory, when you are finished you can use 'git format-patch HEAD~n' and collect your patch in a mailbox format.
It works for me. How/why does it fails for you ?
Quoted 8 lines
There's two problem on my side.
First when I try to git-am your patch on top of the actual master I get this:Applying patch #632988 using 'git am -s'
Description: [1/2,v2] spidermonkey185: New package.
Applying: spidermonkey185: New package. .git/rebase-apply/patch:93: space before tab in indent.
mv -f $(SHLIB_ANY_VER) $(SHLIB_EXACT_VER)
I am patching a makefile. The makefile is obviously indented with tabs, and diff add a space at the beggining of context lines.
Quoted 8 lines
.git/rebase-apply/patch:94: space before tab in indent.
@[ ! -h $(SHLIB_ABI_VER) ] || rm -f $(SHLIB_ABI_VER)
.git/rebase-apply/patch:121: trailing whitespace..git/rebase-apply/patch:146: trailing whitespace.
.git/rebase-apply/patch:163: trailing whitespace.
Those are context empty lines.
Quoted 8 lines
error: patch failed: package/Config.in:1284
error: package/Config.in: patch does not apply
Patch failed at 0001 spidermonkey185: New package.
The copy of the patch that failed is found in: .git/rebase-apply/patch When you have resolved this problem, run "git am --continue". If you prefer to skip this patch, run "git am --skip" instead. To restore the original branch and stop patching, run "git am --abort".
Quoted 7 lines
So I have to use patch -p1 to apply it by hand, I removed my git configuration but to no avail.
The second part is Buildroot applying the patches in your patch but it appears to be something in my git config, probably because there's some line ending mixes between Windows/Linux or things like that. I am using git.core.apply.whitespace=fix, maybe that's not an important issue.
If you "fix" the white space in these patch files, they obviously won't apply anymore.
Quoted 38 lines
Quoted 38 lines
Quoted 31 lines
package/spidermonkey185/0002-make-shlib-synlink-relative.patch
Quoted 27 lines
package/spidermonkey185/0001-remove-unused-pkgconfg-nspr-dependency.patch new file +18
-0@@ -0,0 +1,18 @@ +From: Nicolas Cavallari <[email protected]> + +Remove the dependency on nspr. + +This dependency was removed when spidermonkey was extracted from the +mozilla code base. This is probably a left-over, since it is not used. + +Signed-off-by: Nicolas Cavallari <[email protected]> + +--- spidermonkey185-1.0.0/js/src/mozjs185.pc.in 2016-05-23 13:41:28.430466213 +0200 ++++ spidermonkey185-1.0.0/js/src/mozjs185.pc.in 2016-05-23 13:42:00.727558977 +0200 +@@ -5,6 +5,5 @@ + Name: SpiderMonkey 1.8.5 + Description: The Mozilla library for JavaScript 1.8.5 + Version: %MOZILLA_VERSION% +-Requires: nspr >= 4.7 + Libs: -L${libdir} -lmozjs185 + Cflags: -I${includedir}/jspackage/spidermonkey185/0002-make-shlib-synlink-relative.patch new file +0
-0When I quickly grepped through the source, you can still find:
js/jsd/jsd_xpc.h:47:#include "nspr.h"Quoted 2 lines
Won't that cause trouble ? Since we have libnspr, why don't we add the dependencies and be done with it ?
Anything outside of js/src is ignored. Specifically, js/jsd has no complete build system (there is Makefile.in, but no configure script), so it cannot cause any problem.
Quoted 6 lines
Quoted 2 lines
And why should we re-add libnspr when upstream did massive patches to get rid of it, even if they missed some places ?
Ok, it's indeed a small patch and if the file in question is not even touched there's no harm.
There's no link to what does upstream as it's a deprecated version and it will never be updated anymore.
The spidermonkey code base heavily depended on nspr, especially its various integer typedefs which were sprinkled everywhere. To release an independent javascript engine, almost all the source code had to be converted to use the JSInt* typedefs. There are even some conversion scripts left in the tarball.
Even if upstream stopped updating this package, the removal of the nspr dependency is still 99.9% complete.
Anyway, here are the V3 of the patches.
PATCH v3 1/2 spidermonkey185: New package.
This is the old 1.8.5 branch of spidermonkey, used in Firefox 4. It is rather unmaintained, but some software still depend on it, such as couchdb.
--- package/Config.in | 1 + ...01-remove-unused-pkgconfg-nspr-dependency.patch | 18 +++++ .../0002-make-shlib-synlink-relative.patch | 21 +++++ .../0003-regenerate-configure.patch | 44 ++++++++++ ...val_layout-on-64-bit-big-endian-platforms.patch | 91 +++++++++++++++++++++ ...tatic-assert-fix-strict-aliasing-warnings.patch | 94 ++++++++++++++++++++++ ...heFlush-support-error-on-exotic-platforms.patch | 34 ++++++++ package/spidermonkey185/Config.in | 14 ++++ package/spidermonkey185/spidermonkey185.hash | 2 + package/spidermonkey185/spidermonkey185.mk | 30 +++++++ 10 files changed, 349 insertions(+) create mode 100644 package/spidermonkey185/0001-remove-unused-pkgconfg-nspr-dependency.patch create mode 100644 package/spidermonkey185/0002-make-shlib-synlink-relative.patch create mode 100644 package/spidermonkey185/0003-regenerate-configure.patch create mode 100644 package/spidermonkey185/0004-Fix-jsval_layout-on-64-bit-big-endian-platforms.patch create mode 100644 package/spidermonkey185/0005-Remove-bad-static-assert-fix-strict-aliasing-warnings.patch create mode 100644 package/spidermonkey185/0006-Avoid-missing-cacheFlush-support-error-on-exotic-platforms.patch create mode 100644 package/spidermonkey185/Config.in create mode 100644 package/spidermonkey185/spidermonkey185.hash create mode 100644 package/spidermonkey185/spidermonkey185.mk
v2 -> v3: Addressed Maxime Hadjinlian's comments
v1 -> v2:
* Moved package to Libraries/Other
* Tried to make the package reconfigurable, but stopped when the patch grew even larger than previous patches. Instead, simplified the patch to not force a specific arm version, to make the configure patch smaller.
* Added patches to fix DESTDIR being embedded in the symlink and remove the leftover nspr dependency.
* Added comment on why we define symbols for the host compiler.
* Added upstream patches to fix problems on various architectures, taking inspiration for the patches that Debian uses.
* Disabled the JIT on sparc64 because that does not compile.
* Added host-perl and host-python, because they are used to build.
* Changed license as per Arnout suggestion
package/Config.in +1 -0
@@ -1306,6 +1306,7 @@ endif source "package/qhull/Config.in" source "package/qlibc/Config.in" source "package/sphinxbase/Config.in" + source "package/spidermonkey185/Config.in" source "package/startup-notification/Config.in" source "package/tz/Config.in" source "package/tzdata/Config.in"
package/spidermonkey185/0001-remove-unused-pkgconfg-nspr-dependency.patch new file +18 -0
@@ -0,0 +1,18 @@ +From: Nicolas Cavallari <[email protected]> + +Remove the dependency on nspr. + +This dependency was removed when spidermonkey was extracted from the +mozilla code base. This is probably a left-over, since it is not used. + +Signed-off-by: Nicolas Cavallari <[email protected]> + +--- spidermonkey185-1.0.0/js/src/mozjs185.pc.in 2016-05-23 13:41:28.430466213 +0200 ++++ spidermonkey185-1.0.0/js/src/mozjs185.pc.in 2016-05-23 13:42:00.727558977 +0200 +@@ -5,6 +5,5 @@ + Name: SpiderMonkey 1.8.5 + Description: The Mozilla library for JavaScript 1.8.5 + Version: %MOZILLA_VERSION% +-Requires: nspr >= 4.7 + Libs: -L${libdir} -lmozjs185 + Cflags: -I${includedir}/js
package/spidermonkey185/0002-make-shlib-synlink-relative.patch new file +21 -0
@@ -0,0 +1,21 @@ +From: Nicolas Cavallari <[email protected]> + +Fix the creation of the shared library symbolic links. + +Do not create absolute symbolic links that references DESTDIR. + +Signed-off-by: Nicolas Cavallari <[email protected]> + +--- spidermonkey185-1.0.0/js/src/Makefile.in 2016-05-23 13:49:39.535010860 +0200 ++++ spidermonkey185-1.0.0/js/src/Makefile.in 2016-05-23 13:50:06.555917036 +0200 +@@ -888,8 +888,8 @@ + ifeq (,$(HOST_BIN_SUFFIX)) + mv -f $(SHLIB_ANY_VER) $(SHLIB_EXACT_VER) + @[ ! -h $(SHLIB_ABI_VER) ] || rm -f $(SHLIB_ABI_VER) +- ln -s $(SHLIB_EXACT_VER) $(SHLIB_ABI_VER) +- ln -s $(SHLIB_ABI_VER) $(SHLIB_ANY_VER) ++ ln -s $(notdir $(SHLIB_EXACT_VER)) $(SHLIB_ABI_VER) ++ ln -s $(notdir $(SHLIB_ABI_VER)) $(SHLIB_ANY_VER) + endif + endif + ifneq (,$(IMPORT_LIBRARY))
package/spidermonkey185/0003-regenerate-configure.patch new file +44 -0
44 lines not on this page · raw message
package/spidermonkey185/0004-Fix-jsval_layout-on-64-bit-big-endian-platforms.patch new file +91 -0
91 lines not on this page · raw message
package/spidermonkey185/0005-Remove-bad-static-assert-fix-strict-aliasing-warnings.patch new file +94 -0
94 lines not on this page · raw message
package/spidermonkey185/0006-Avoid-missing-cacheFlush-support-error-on-exotic-platforms.patch new file +34 -0
@@ -0,0 +1,34 @@ + +# HG changeset patch +# User Mike Hommey <[email protected]> +# Date 1303461188 -7200 +# Node ID 59771590e9203d48ef8cbcd7eaf2f8ae45dbb1c1 +# Parent c4b82ec27d6d6e1c02ef0abb3b6e805bfdd092ec +Bug 638056 - Avoid "The cacheFlush support is missing on this platform" error on exotic platforms. r=cdleary + +[nicolas.cavallari at green-communications.fr: refresh patch] +Signed-off-by: Nicolas Cavallari <[email protected]> + +diff --git a/js/src/Makefile.in b/js/src/Makefile.in +--- a/js/src/Makefile.in ++++ b/js/src/Makefile.in +@@ -377,17 +377,17 @@ CPPSRCS += checks.cc \ + platform.cc \ + utils.cc \ + $(NONE) + + # + # END enclude sources for V8 dtoa + ############################################# + +-ifeq (,$(filter-out powerpc sparc,$(TARGET_CPU))) ++ifeq (,$(filter arm %86 x86_64,$(TARGET_CPU))) + + VPATH += $(srcdir)/assembler \ + $(srcdir)/assembler/wtf \ + $(srcdir)/yarr/pcre \ + $(NULL) + + CPPSRCS += pcre_compile.cpp \ + pcre_exec.cpp \ +
package/spidermonkey185/Config.in new file +14 -0
@@ -0,0 +1,14 @@ +config BR2_PACKAGE_SPIDERMONKEY185 + bool "spidermonkey (1.8.5)" + depends on BR2_USE_MMU # fork in executable tools. + depends on BR2_INSTALL_LIBSTDCPP + depends on BR2_TOOLCHAIN_HAS_THREADS + help + SpiderMonkey is Mozilla's JavaScript engine written in C/C++. It is + used in various Mozilla products, including Firefox. + + This is the old 1.8.5 branch, used in Firefox 4. + +comment "Spider monkey (1.8.5) need a toolchain with C++, threads" + depends on BR2_USE_MMU + depends on !BR2_INSTALL_LIBSTDCPP || !BR2_TOOLCHAIN_HAS_THREADS
package/spidermonkey185/spidermonkey185.hash new file +2 -0
@@ -0,0 +1,2 @@ +# Locally generated. +sha256 5d12f7e1f5b4a99436685d97b9b7b75f094d33580227aa998c406bbae6f2a687 js185-1.0.0.tar.gz
package/spidermonkey185/spidermonkey185.mk new file +30 -0
@@ -0,0 +1,30 @@ +################################################################################ +# +# Spidermonkey (1.8.5) +# +################################################################################ + +SPIDERMONKEY185_VERSION = 1.0.0 +SPIDERMONKEY185_SITE = http://ftp.mozilla.org/pub/js +SPIDERMONKEY185_SOURCE = js185-${SPIDERMONKEY185_VERSION}.tar.gz +SPIDERMONKEY185_SUBDIR = js/src + +SPIDERMONKEY185_LICENSE = MPLv1.1 or GPLv2.0+ or LGPLv2.1+ +SPIDERMONKEY185_INSTALL_STAGING = YES +SPIDERMONKEY185_DEPENDENCIES = host-python host-perl + +# This define is used by jscpucfg.cpp which is normally used to runtime-detect +# the system endianess. +SPIDERMONKEY185_CONF_ENV = \ + HOST_CXXFLAGS="$(HOST_CXXFLAGS) -DFORCE_$(BR2_ENDIAN)_ENDIAN" + +# Mozilla mixes up target, host and build. See the comment in configure.in +# around line 360. Also, nanojit fails to build on sparc64 with +# #error "unknown nanojit architecture", so disable the JIT. +SPIDERMONKEY185_CONF_OPTS = \ + --target=$(GNU_TARGET_NAME) \ + --build=$(GNU_TARGET_NAME) \ + --host=$(GNU_HOST_NAME) \ + $(if $(BR2_sparc64),--disable-tracejit) + +$(eval $(autotools-package))
Signature · 1 line
2.8.1
PATCH v3 2/2 couchdb: New package.
--- package/Config.in | 1 + package/couchdb/0001-remove-unsafe-paths.patch | 41 +++++++++++++++++++++ package/couchdb/Config.in | 22 +++++++++++ package/couchdb/S96prepare-couchdb | 14 +++++++ package/couchdb/couchdb.hash | 6 +++ package/couchdb/couchdb.mk | 51 ++++++++++++++++++++++++++ 6 files changed, 135 insertions(+) create mode 100644 package/couchdb/0001-remove-unsafe-paths.patch create mode 100644 package/couchdb/Config.in create mode 100644 package/couchdb/S96prepare-couchdb create mode 100644 package/couchdb/couchdb.hash create mode 100644 package/couchdb/couchdb.mk
v2->v3: no changes
package/Config.in +1 -0
@@ -877,6 +877,7 @@ endmenu menu "Database" source "package/berkeleydb/Config.in" + source "package/couchdb/Config.in" source "package/cppdb/Config.in" source "package/gdbm/Config.in" source "package/kompexsqlite/Config.in"
package/couchdb/0001-remove-unsafe-paths.patch new file +41 -0
41 lines not on this page · raw message
package/couchdb/Config.in new file +22 -0
@@ -0,0 +1,22 @@ +comment "CouchDB need a toolchain with C++, wchar, threads, dynamic libs." + depends on !BR2_BINFMT_FLAT + depends on BR2_USE_MMU + depends on BR2_PACKAGE_LIBATOMIC_OPS_ARCH_SUPPORTS + depends on !BR2_TOOLCHAIN_HAS_THREADS || \ + BR2_STATIC_LIBS || !BR2_INSTALL_LIBSTDCPP || !BR2_USE_WCHAR + +config BR2_PACKAGE_COUCHDB + bool "couchdb" + depends on BR2_USE_MMU # erlang, spidermonkey185 + depends on !BR2_BINFMT_FLAT # icu + depends on BR2_INSTALL_LIBSTDCPP # icu, spidermonkey185 + depends on BR2_PACKAGE_LIBATOMIC_OPS_ARCH_SUPPORTS # erlang + depends on !BR2_STATIC_LIBS # erlang + depends on BR2_TOOLCHAIN_HAS_THREADS # icu + depends on BR2_USE_WCHAR # icu + + select BR2_PACKAGE_ERLANG + select BR2_PACKAGE_ICU + select BR2_PACKAGE_LIBCURL + select BR2_PACKAGE_OPENSSL + select BR2_PACKAGE_SPIDERMONKEY185
package/couchdb/S96prepare-couchdb new file +14 -0
@@ -0,0 +1,14 @@ +#!/bin/sh + +REQUIRED_DIRS=/var/log/couchdb + +PREPARE_COUCHDB_DEFAULT=/etc/default/prepare-couchdb + +if [ -r "$PREPARE_COUCHDB_DEFAULT" ]; then + . "$PREPARE_COUCHDB_DEFAULT" +fi + +case "$1" in + start) + install -d -o couchdb -g couchdb $REQUIRED_DIRS;; +esac
package/couchdb/couchdb.hash new file +6 -0
@@ -0,0 +1,6 @@ +# From https://archive.apache.org/dist/couchdb/source/1.6.1/apache-couchdb-1.6.1.tar.gz.{md5,sha} +sha1 6275f3818579d7b307052e9735c42a8a64313229 apache-couchdb-1.6.1.tar.gz +md5 01a2c8ab4fcde457529428993901a060 apache-couchdb-1.6.1.tar.gz + +# Locally generated after checking PGP signature +sha256 5a601b173733ce3ed31b654805c793aa907131cd70b06d03825f169aa48c8627 apache-couchdb-1.6.1.tar.gz
package/couchdb/couchdb.mk new file +51 -0
51 lines not on this page · raw message
Signature · 1 line
2.8.1
PATCH v3 2/2 couchdb: New package.
Hi,
Am Wed, 06 Jul 2016 12:24:09 +0200 schrieb Nicolas Cavallari:
package/couchdb/Config.in line 18
Quoted 1 line
package/couchdb/Config.in new file +1
-0+ select BR2_PACKAGE_ERLANG
the elrang version provided by buildroot is detected as incompatible with couchdb 1.6.1:
checking Erlang version compatibility... detected Erlang version:
7.3.0...configure: error: The installed Erlang version must be >= R14B (erts-5.8.1) and =< 17 (erts-6.0) major_version does not match
Regards, Bernd
PATCH v3 2/2 couchdb: New package.
I have been using CouchDB 1.6.1 in operation for a long time now. I have patches that make CouchDB use Erlang OTP 19.0 for a while now and patched in OTP 18 support more than a year ago, and that has always worked with no problems.
If you care to look at CouchDB "included" packages, for instance snappy and mochiweb, you'll see that even in CouchDB 2.0 they use some ancient versions when they really shouldn't. So I am not advising you to patch CouchDB to use newer versions of its dependencies, but that I have good results with newer OTP, and that CouchDB development appears to be rather conservative in what they want to support.
If you're interested in my CouchDB/buildroot patches, let me know.
Kind regards,
jer
Quoted 13 lines · Bernd Kuhls
Hi,
Am Wed, 06 Jul 2016 12:24:09 +0200 schrieb Nicolas Cavallari:
Quoted 1 line
+ select
BR2_PACKAGE_ERLANGthe elrang version provided by buildroot is detected as incompatible with couchdb 1.6.1:
checking Erlang version compatibility... detected Erlang version:
7.3.0...configure: error: The installed Erlang version must be >= R14B (erts-5.8.1) and =< 17 (erts-6.0)major_versiondoes not match
Quoted 7 lines
Regards, Bernd
_______________________________________________
buildroot mailing list
buildroot at busybox.net
http://lists.busybox.net/mailman/listinfo/buildroot
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20161003/67655c36/attachment.html>
PATCH v3 2/2 couchdb: New package.
Jeroen Roovers <[email protected]> wrote in news:CANCHnQrDJQ7Ke=wQU7hWPnOZTM7ruF-KbCber0KhBsMQkrhccQ at mail.gmail.com:
Quoted 1 line
If you're interested in my CouchDB/buildroot patches, let me know.
Hi Jeroen,
I guess a patch like Gentoo uses is enough to make couchdb 1.6.1 compatible with the erlang version provided by buildroot?
https://gitweb.gentoo.org/repo/gentoo.git/tree/dev-db/couchdb/files/1.6.1-
erlang-18.patch?id=f1e3aa13062e9b59ef383e8078c7e4f61f140604
Regards, Bernd
PATCH v3 2/2 couchdb: New package.
Yes, my patch does a few things slightly differently with the same effect.
Quoted 13 lines · Bernd Kuhls
Jeroen Roovers <[email protected]> wrote in news:CANCHnQrDJQ7Ke=wQU7hWPnOZTM7ruF-KbCber0KhBsMQkrhccQ at mail.gmail.com:
Quoted 1 line
If you're interested in my CouchDB/buildroot patches, let me know.
Hi Jeroen,
I guess a patch like Gentoo uses is enough to make couchdb 1.6.1 compatible with the erlang version provided by buildroot?
https://gitweb.gentoo.org/repo/gentoo.git/tree/dev-db/couchdb/files/1.6.1-
erlang-18.patch?id=f1e3aa13062e9b59ef383e8078c7e4f61f140604
Quoted 7 lines
Regards, Bernd
_______________________________________________
buildroot mailing list
buildroot at busybox.net
http://lists.busybox.net/mailman/listinfo/buildroot
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.busybox.net/pipermail/buildroot/attachments/20161003/7d2791ec/attachment.html>
PATCH v3 2/2 couchdb: New package.
In reply to Bernd KuhlsQuoted 8 lines · Bernd Kuhls
Hi,
Am Wed, 06 Jul 2016 12:24:09 +0200 schrieb Nicolas Cavallari:
package/couchdb/Config.in line 18
Quoted 1 line
package/couchdb/Config.in new file +1
-0+ select BR2_PACKAGE_ERLANGthe elrang version provided by buildroot is detected as incompatible with couchdb 1.6.1:
Yes, the erlang version was bumped one month after posting my patch.
I remembered that patching the configure was enough for the thing to build anyway, but I couldn't test it because the other program that was using couchdb was utterly broken.
But still, with the previous patch revision, people were unsure of whether my two patches were actually wanted, considering the uglyness of spidermonkey185.
And, by the way, couchdb 2.0 is still not usable for distribution packaging, let alone cross-compilation.
PATCH v3 1/2 spidermonkey185: New package.
In reply to Nicolas CavallariHi,
Am Wed, 06 Jul 2016 12:24:08 +0200 schrieb Nicolas Cavallari:
package/Config.in index endif · line 1312
Quoted 10 lines
package/Config.in index renamed from package/Config.in +0
-015271a2..fdc3194 100644 --- a/package/Config.in +++ b/package/Config.in
package/Config.in index renamed from package/Config.in +1
-0@@ -1306,6 +1306,7 @@ endif source "package/qhull/Config.in" source "package/qlibc/Config.in" source "package/sphinxbase/Config.in" + source "package/spidermonkey185/Config.in" source "package/startup-notification/Config.in" source "package/tz/Config.in" source "package/tzdata/Config.in"
after the addition of shapelib
https://git.buildroot.net/buildroot/commit/package/Config.in?
id=2655d676f0151f6cfd36c42435cf84926c209e24
your patch does not apply anymore.
The package fails to compile using this toolchain:
http://autobuild.buildroot.net/toolchains/configs/br-x86-64-core2-
full.config
jsapi.cpp:361:63: error: cannot convert ?__va_list_tag**? to ?__va_list_tag (*)[1]? for argument ?5? to ?JSBool TryArgumentFormatter (JSContext*, const char**, JSBool, jsval**, __va_list_tag (*)[1])?
JS_ADDRESSOF_VA_LIST(ap))) {To solve the problem add
printf("#define HAVE_VA_LIST_AS_ARRAY \n");
in js/src/jscpucfg.cpp after line 76 according to
https://groups.google.com/forum/#!topic/jsdb/CnWRh11hRHQ
Regards, Bernd
PATCH v3 1/2 spidermonkey185: New package.
Quoted 7 lines · Bernd Kuhls
The package fails to compile using this toolchain:
http://autobuild.buildroot.net/toolchains/configs/br-x86-64-core2-
full.configjsapi.cpp:361:63: error: cannot convert ?__va_list_tag**? to ?__va_list_tag (*)[1]? for argument ?5? to ?JSBool TryArgumentFormatter (JSContext*, const char**, JSBool, jsval**,
__va_list_tag(*)[1])?
Quoted 8 lines
JS_ADDRESSOF_VA_LIST(ap))) {To solve the problem add
printf("#define HAVE_VA_LIST_AS_ARRAY \n");in js/src/jscpucfg.cpp after line 76 according to
https://groups.google.com/forum/#!topic/jsdb/CnWRh11hRHQ
This link mention other modifications that one has to do for it to run. I'm not sure i can just "pick them up" if they do not have a license.
PATCH v3 1/2 spidermonkey185: New package.
In reply to Nicolas CavallariHello Nicolas,
Quoted 18 lines · Nicolas Cavallari
This is the old 1.8.5 branch of spidermonkey, used in Firefox 4. It is rather unmaintained, but some software still depend on it, such as couchdb.
Signed-off-by Nicolas Cavallari <[email protected]>--- package/Config.in | 1 + ...01-remove-unused-pkgconfg-nspr-dependency.patch | 18 +++++ .../0002-make-shlib-synlink-relative.patch | 21 +++++ .../0003-regenerate-configure.patch | 44 ++++++++++ ...val_layout-on-64-bit-big-endian-platforms.patch | 91 +++++++++++++++++++++ ...tatic-assert-fix-strict-aliasing-warnings.patch | 94 ++++++++++++++++++++++ ...heFlush-support-error-on-exotic-platforms.patch | 34 ++++++++ package/spidermonkey185/Config.in | 14 ++++ package/spidermonkey185/spidermonkey185.hash | 2 + package/spidermonkey185/spidermonkey185.mk | 30 +++++++ 10 files changed, 349 insertions(+) create mode 100644 package/spidermonkey185/0001-remove-unused-pkgconfg-nspr-dependency.patch
Quoted 8 lines
create mode 100644 package/spidermonkey185/0002-make-shlib-synlink-relative.patch create mode 100644 package/spidermonkey185/0003-regenerate-configure.patch create mode 100644 package/spidermonkey185/0004-Fix-jsval_layout-on-64-bit-big-endian-platforms.patch create mode 100644 package/spidermonkey185/0005-Remove-bad-static-assert-fix-strict-aliasing-warnings.patch create mode 100644 package/spidermonkey185/0006-Avoid-missing-cacheFlush-support-error-on-exotic-platforms.patch create mode 100644 package/spidermonkey185/Config.in create mode 100644 package/spidermonkey185/spidermonkey185.hash create mode 100644 package/spidermonkey185/spidermonkey185.mk
We have been looking a bit at your patches during the Buildroot meeting this week-end. For both patches (spidermonkey185 and couchdb) there have been a number of comments. If you're still interested, could you address those comments ?
Another thing is that CouchDB 2.0 has now been released (on September 20), so we would preferably have that version packaged, if possible.
We'll mark your patches as Changes Requested in patchwork, so don't forget to send an updated version, otherwise we will forget about them.
Thanks a lot!
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons Embedded Linux, Kernel and Android engineering http://free-electrons.com
PATCH v3 1/2 spidermonkey185: New package.
Hi Thomas,
Am Sun, 16 Oct 2016 12:01:29 +0200 schrieb Thomas Petazzoni:
Quoted 4 lines
We have been looking a bit at your patches during the Buildroot meeting this week-end. For both patches (spidermonkey185 and couchdb) there have been a number of comments. If you're still interested, could you address those comments ?
just sent v4 of the spidermonkey patch, oh and yes, it is meant for the next branch, just forgot to mention it in the patch subject:
http://patchwork.ozlabs.org/patch/798416/
Quoted 2 lines
Another thing is that CouchDB 2.0 has now been released (on September 20), so we would preferably have that version packaged, if possible.
CouchDB 2.1 is just around the corner, the package is not yet finished, I am struggeling to get host-erlang-rebar do the right things...
Regards, Bernd
PATCH v2 2/2 couchdb: New package.
In reply to Nicolas Cavallari---
v1 -> v2:
* added default file to S96prepare-couchdb init script, to allow customizing where to store the log and maybe store the data on a tmpfs too.
* addressed arnout comments.
package/Config.in | 1 + package/couchdb/0001-remove-unsafe-paths.patch | 41 +++++++++++++++++++++ package/couchdb/Config.in | 22 +++++++++++ package/couchdb/S96prepare-couchdb | 14 +++++++ package/couchdb/couchdb.hash | 6 +++ package/couchdb/couchdb.mk | 51 ++++++++++++++++++++++++++ 6 files changed, 135 insertions(+) create mode 100644 package/couchdb/0001-remove-unsafe-paths.patch create mode 100644 package/couchdb/Config.in create mode 100644 package/couchdb/S96prepare-couchdb create mode 100644 package/couchdb/couchdb.hash create mode 100644 package/couchdb/couchdb.mk
package/Config.in +1 -0
@@ -866,6 +866,7 @@ endmenu menu "Database" source "package/berkeleydb/Config.in" + source "package/couchdb/Config.in" source "package/cppdb/Config.in" source "package/gdbm/Config.in" source "package/kompexsqlite/Config.in"
package/couchdb/0001-remove-unsafe-paths.patch new file +41 -0
41 lines not on this page · raw message
package/couchdb/Config.in new file +22 -0
@@ -0,0 +1,22 @@ +comment "CouchDB need a toolchain with C++, wchar, threads, dynamic libs." + depends on !BR2_BINFMT_FLAT + depends on BR2_USE_MMU + depends on BR2_PACKAGE_LIBATOMIC_OPS_ARCH_SUPPORTS + depends on !BR2_TOOLCHAIN_HAS_THREADS || \ + BR2_STATIC_LIBS || !BR2_INSTALL_LIBSTDCPP || !BR2_USE_WCHAR + +config BR2_PACKAGE_COUCHDB + bool "couchdb" + depends on BR2_USE_MMU # erlang, spidermonkey185 + depends on !BR2_BINFMT_FLAT # icu + depends on BR2_INSTALL_LIBSTDCPP # icu, spidermonkey185 + depends on BR2_PACKAGE_LIBATOMIC_OPS_ARCH_SUPPORTS # erlang + depends on !BR2_STATIC_LIBS # erlang + depends on BR2_TOOLCHAIN_HAS_THREADS # icu + depends on BR2_USE_WCHAR # icu + + select BR2_PACKAGE_ERLANG + select BR2_PACKAGE_ICU + select BR2_PACKAGE_LIBCURL + select BR2_PACKAGE_OPENSSL + select BR2_PACKAGE_SPIDERMONKEY185
package/couchdb/S96prepare-couchdb new file +14 -0
@@ -0,0 +1,14 @@ +#!/bin/sh + +REQUIRED_DIRS=/var/log/couchdb + +PREPARE_COUCHDB_DEFAULT=/etc/default/prepare-couchdb + +if [ -r "$PREPARE_COUCHDB_DEFAULT" ]; then + . "$PREPARE_COUCHDB_DEFAULT" +fi + +case "$1" in + start) + install -d -o couchdb -g couchdb $REQUIRED_DIRS;; +esac
package/couchdb/couchdb.hash new file +6 -0
@@ -0,0 +1,6 @@ +# From https://archive.apache.org/dist/couchdb/source/1.6.1/apache-couchdb-1.6.1.tar.gz.{md5,sha} +sha1 6275f3818579d7b307052e9735c42a8a64313229 apache-couchdb-1.6.1.tar.gz +md5 01a2c8ab4fcde457529428993901a060 apache-couchdb-1.6.1.tar.gz + +# Locally generated after checking PGP signature +sha256 5a601b173733ce3ed31b654805c793aa907131cd70b06d03825f169aa48c8627 apache-couchdb-1.6.1.tar.gz
package/couchdb/couchdb.mk new file +51 -0
51 lines not on this page · raw message
Signature · 1 line
2.8.1
PATCH 1/2 spidermonkey185: New package.
In reply to Nicolas CavallariQuoted 2 lines · Nicolas Cavallari
This is the old 1.8.5 branch of spidermonkey, used in Firefox 4. It is rather unmaintained, but some software still depend on it.
Mention couchdb explicitly here.
Quoted 6 lines
Signed-off-by Nicolas Cavallari <[email protected]>---
There are many ugly things in here, I would like your advice/opinion on whether this package can be upstreamable.
Except for the huge patches, it's not _that_ ugly IMHO.
Quoted 7 lines
This commit is based on the 'next' branch.
package/Config.in | 1 + .../0001-fix-arm-compiler-flags.patch | 340 ++ .../0002-regenerate-configure.patch | 5397 ++++++++++++++++++++
Ouch! Is it really necessary to add this? Usually it's possible to regenerate
the configure script with recent automake by making some small modifications to the AC_INIT etc. calls.
Quoted 15 lines
package/spidermonkey185/Config.in | 15 + package/spidermonkey185/spidermonkey185.hash | 2 + package/spidermonkey185/spidermonkey185.mk | 51 + 6 files changed, 5806 insertions(+) create mode 100644 package/spidermonkey185/0001-fix-arm-compiler-flags.patch create mode 100644 package/spidermonkey185/0002-regenerate-configure.patch create mode 100644 package/spidermonkey185/Config.in create mode 100644 package/spidermonkey185/spidermonkey185.hash create mode 100644 package/spidermonkey185/spidermonkey185.mkpackage/Config.in +0
-0
package/Config.in menu "External python modules" · line 765
Quoted 4 lines
package/Config.in +1
-0@@ -762,6 +762,7 @@ menu "External python modules" endmenu endif source "package/ruby/Config.in" + source "package/spidermonkey185/Config.in"
It feels a bit weird to put this in scripting languages, but I don't really
know a better place for it.
Quoted 9 lines
package/Config.in +0
-0source "package/tcl/Config.in" if BR2_PACKAGE_TCL menu "Tcl libraries/modules"package/spidermonkey185/0001-fix-arm-compiler-flags.patch new file +0
-0
package/spidermonkey185/0001-fix-arm-compiler-flags.patch line 7
Quoted 7 lines
package/spidermonkey185/0001-fix-arm-compiler-flags.patch new file +7
-0@@ -0,0 +1,340 @@ +# HG changeset patch +# User Mike Hommey <[email protected]> +# Date 1304348823 -7200 +# Node ID e38cec9f833829a6137c03f4f1d282aca4063fcd +# Parent 6322e8f7cb2dd4e393b7ad18acbc09f1bae69771 +Bug 626035 - Modify the way arm compiler flags are set in configure +[nicolas.cavallari: refresh the patch]
This needs a better explanation why the patch is needed. Since this is such a
huge patch with unclear purpose, and since we know all the relevant ARM information at the buildroot level, and since it's not upstreamable anyway because it's such an old version, I'd prefer to do a minimal patch that just removes things that can't be worked around, and pass all the relevant info through CPPFLAGS or environment variables.
package/spidermonkey185/0001-fix-arm-compiler-flags.patch line 10
Quoted 3 lines
package/spidermonkey185/0001-fix-arm-compiler-flags.patch new file +3
-0+ +From: https://bug626035.bmoattachments.org/attachment.cgi?id=529479 +
[snip] Phew, glad I got rid of that :-)
package/spidermonkey185/Config.in line 5
Quoted 11 lines
package/spidermonkey185/Config.in new file +5
-0@@ -0,0 +1,15 @@ +config BR2_PACKAGE_SPIDERMONKEY185 + bool "spidermonkey (1.8.5)" + depends on BR2_INSTALL_LIBSTDCPP + depends on BR2_TOOLCHAIN_HAS_THREADS + depends on BR2_USE_MMU # fork in executable tools.
I believe v8 has much stricter arch requirements, and also atomics/sync
requirements.
Quoted 26 lines
package/spidermonkey185/Config.in new file +10
-0+ help + SpiderMonkey is Mozilla's JavaScript engine written in C/C++. It is + used in various Mozilla products, including Firefox. + + This is the old 1.8.5 branch, used in Firefox 4. + + +comment "Spider monkey (1.8.5) need a toolchain with C++, threads" + depends on BR2_USE_MMU + depends on !BR2_INSTALL_LIBSTDCPP || !BR2_TOOLCHAIN_HAS_THREADSpackage/spidermonkey185/spidermonkey185.hash new file +2
-0@@ -0,0 +1,2 @@ +# Locally generated. +sha256 5d12f7e1f5b4a99436685d97b9b7b75f094d33580227aa998c406bbae6f2a687 js185-1.0.0.tar.gzpackage/spidermonkey185/spidermonkey185.mk new file +2
-0@@ -0,0 +1,51 @@ +################################################################################ +#
package/spidermonkey185/spidermonkey185.mk line 12
Quoted 10 lines
package/spidermonkey185/spidermonkey185.mk new file +10
-0+# Spidermonkey (1.8.5) +# +################################################################################ + +SPIDERMONKEY185_VERSION = 1.0.0 +SPIDERMONKEY185_SITE = http://ftp.mozilla.org/pub/js +SPIDERMONKEY185_SOURCE = js185-${SPIDERMONKEY185_VERSION}.tar.gz + +SPIDERMONKEY185_INSTALL_STAGING = YES +SPIDERMONKEY185_INSTALL_TARGET = YES
This is the default -> remove
package/spidermonkey185/spidermonkey185.mk line 17
Quoted 5 lines
package/spidermonkey185/spidermonkey185.mk new file +5
-0+ +SPIDERMONKEY185_LICENSE = \ + MPL-1.1/GPL-2.0/LGPL-2.1 (Mostly), \ + MIT variants (libffi+, v8, mkdepend), \ + BSD-2c/BSD-3c (various parts), public domain (some tests)
We only specify the license of the things actually installed to target (or
host). So not the build utils (mkdepend), not the things that are not installed (tests). The Mostly can also be removed. The / is not clear, you either use , for and, or ' or ' for or. BSD, MIT and public domain can be left out if the combined work (i.e. the binary) is anyway MPL/GPL - but they have to be included if it's for separate scripts. For historical reasons, we use MPLv1.1, GPLv2 and LGPLv2.1. Are all of them without +?
Are there no license files at all?
package/spidermonkey185/spidermonkey185.mk line 20
Quoted 3 lines
package/spidermonkey185/spidermonkey185.mk new file +3
-0+ +SPIDERMONKEY185_CONF_ENV = \ + HOST_CXXFLAGS="$(HOST_CXXFLAGS) -DFORCE_$(BR2_ENDIAN)_ENDIAN"
That doesn't look right: forcing target endianness in the host flags?
package/spidermonkey185/spidermonkey185.mk line 24
Quoted 4 lines
package/spidermonkey185/spidermonkey185.mk new file +4
-0+SPIDERMONKEY185_CONF_OPTS = \ + --target=$(GNU_TARGET_NAME) \ + --build=$(GNU_TARGET_NAME) \ + --host=$(GNU_HOST_NAME)
This is already passed by the default _CONFIGURE_CMDS.
package/spidermonkey185/spidermonkey185.mk line 26
Quoted 2 lines
package/spidermonkey185/spidermonkey185.mk new file +2
-0+ +# This dependency does not make sense outside of the mozilla code base.
How so? Either the libraries depend on libnspr so the dependency has to be
there, or they don't so the dependency should be removed - also within the mozilla code base.
package/spidermonkey185/spidermonkey185.mk line 29
Quoted 3 lines
package/spidermonkey185/spidermonkey185.mk new file +3
-0+define SPIDERMONKEY185_FIX_PC_NSPR_DEPENDENCY + sed -i -re 's/nspr >= 4.7//' \ + $(STAGING_DIR)/usr/lib/pkgconfig/mozjs185.pc
I think I prefer a patch to .pc.in instead.
package/spidermonkey185/spidermonkey185.mk line 36
Quoted 7 lines
package/spidermonkey185/spidermonkey185.mk new file +7
-0+endef + +SPIDERMONKEY185_POST_INSTALL_STAGING_HOOKS += \ + SPIDERMONKEY185_FIX_PC_NSPR_DEPENDENCY + + +# These symlinks are created absolute with DESTDIR embedded into it.
Eek...
package/spidermonkey185/spidermonkey185.mk line 37
Quoted 1 line
package/spidermonkey185/spidermonkey185.mk new file +1
-0+# Make them relative so they work on the target.
We probably want to do that in staging as well (for the long-term goal of
relocatable HOST_DIR). And perhaps it's easier to do that with a patch than with a hook - in particular if you manage to get AUTORECONF to work.
package/spidermonkey185/spidermonkey185.mk line 49
Quoted 12 lines
package/spidermonkey185/spidermonkey185.mk new file +12
-0+define SPIDERMONKEY185_FIX_SHLIB_SYMLINK + ln -fs libmozjs185.so.1.0.0 $(TARGET_DIR)/usr/lib/libmozjs185.so + ln -fs libmozjs185.so.1.0.0 $(TARGET_DIR)/usr/lib/libmozjs185.so.1.0 +endef + +SPIDERMONKEY185_POST_INSTALL_TARGET_HOOKS += \ + SPIDERMONKEY185_FIX_SHLIB_SYMLINK + +$(eval $(autotools-package)) + +# Hack so configure/make is run inside the js/src subdirectory. +SPIDERMONKEY185_SRCDIR = $(SPIDERMONKEY185_DIR)/js/src/
Just doSPIDERMONKEY185_SUBDIR = js/src
(not a hack at all).
package/spidermonkey185/spidermonkey185.mk line 51
Quoted 2 lines
package/spidermonkey185/spidermonkey185.mk new file +2
-0+ +
Spurious empty lines.
Regards,
Arnout
Signature · 6 lines
Arnout Vandecappelle arnout at mind be Senior Embedded Software Architect +32-16-286500 Essensium/Mind http://www.mind.be G.Geenslaan 9, 3001 Leuven, Belgium BE 872 984 063 RPR Leuven LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle GPG fingerprint: 7493 020B C7E3 8618 8DEC 222C 82EB F404 F9AC 0DDF
PATCH 1/2 spidermonkey185: New package.
Quoted 5 lines · Arnout Vandecappelle
Quoted 2 lines · Nicolas Cavallari
This is the old 1.8.5 branch of spidermonkey, used in Firefox 4. It is rather unmaintained, but some software still depend on it.
Mention couchdb explicitly here.
ok.
Quoted 7 lines
Quoted 3 lines
package/Config.in | 1 + .../0001-fix-arm-compiler-flags.patch | 340 ++ .../0002-regenerate-configure.patch | 5397 ++++++++++++++++++++Ouch! Is it really necessary to add this? Usually it's possible to regenerate
the configure script with recent automake by making some small modifications to theAC_INITetc. calls.
Given how ugly and huge the configure.in script is, i think it would be a bit hard. I'll try.
Quoted 4 lines
Quoted 4 lines
package/Config.in +0
-0
Quoted 8 lines
package/Config.in menu "External python modules" · line 765
Quoted 5 lines
package/Config.in +1
-0@@ -762,6 +762,7 @@ menu "External python modules" endmenu endif source "package/ruby/Config.in" + source "package/spidermonkey185/Config.in"It feels a bit weird to put this in scripting languages, but I don't really
know a better place for it.
... Probably Libraries/Other ? It's a bit strange since it has a javascript shell which is not installed on the target by 'make install'
Quoted 16 lines
Quoted 16 lines
package/Config.in +0
-0source "package/tcl/Config.in" if BR2_PACKAGE_TCL menu "Tcl libraries/modules"package/spidermonkey185/0001-fix-arm-compiler-flags.patch new file +6
-0@@ -0,0 +1,340 @@ +# HG changeset patch +# User Mike Hommey <[email protected]> +# Date 1304348823 -7200 +# Node ID e38cec9f833829a6137c03f4f1d282aca4063fcd +# Parent 6322e8f7cb2dd4e393b7ad18acbc09f1bae69771 +Bug 626035 - Modify the way arm compiler flags are set in configure
Quoted 8 lines
package/spidermonkey185/0001-fix-arm-compiler-flags.patch line 7
Quoted 1 line
package/spidermonkey185/0001-fix-arm-compiler-flags.patch new file +1
-0+[nicolas.cavallari: refresh the patch]This needs a better explanation why the patch is needed. Since this is such a
huge patch with unclear purpose, and since we know all the relevant ARM information at the buildroot level, and since it's not upstreamable anyway because it's such an old version, I'd prefer to do a minimal patch that just removes things that can't be worked around, and pass all the relevant info through CPPFLAGS or environment variables.
I should have left a link to the bug report.
Basically, on arm, the build system forced armv5 in thumb mode, for no reason.
If the (normally upstream ?) patch is too ugly, i'll try to do something simpler.
Quoted 4 lines
package/spidermonkey185/0001-fix-arm-compiler-flags.patch line 10
Quoted 3 lines
package/spidermonkey185/0001-fix-arm-compiler-flags.patch new file +3
-0+ +From: https://bug626035.bmoattachments.org/attachment.cgi?id=529479 +[snip] Phew, glad I got rid of that :-)
Quoted 14 lines
package/spidermonkey185/Config.in line 5
Quoted 11 lines
package/spidermonkey185/Config.in new file +5
-0@@ -0,0 +1,15 @@ +config BR2_PACKAGE_SPIDERMONKEY185 + bool "spidermonkey (1.8.5)" + depends on BR2_INSTALL_LIBSTDCPP + depends on BR2_TOOLCHAIN_HAS_THREADS + depends on BR2_USE_MMU # fork in executable tools.I believe v8 has much stricter arch requirements, and also atomics/sync
requirements.
Spidermonkey seems to use inline assembly on linux on arches were the JIT is supported.
I'll try to figure out the arch requirements, but i don't think there are many. the JIT isn't mandatory.
Quoted 4 lines
package/spidermonkey185/Config.in line 7
Quoted 2 lines
package/spidermonkey185/Config.in new file +2
-0+SPIDERMONKEY185_INSTALL_STAGING = YES +SPIDERMONKEY185_INSTALL_TARGET = YESThis is the default -> remove
done.
I've also spotted dependencies on python and perl on the host.
Quoted 14 lines
package/spidermonkey185/Config.in line 12
Quoted 5 lines
package/spidermonkey185/Config.in new file +5
-0+ +SPIDERMONKEY185_LICENSE = \ + MPL-1.1/GPL-2.0/LGPL-2.1 (Mostly), \ + MIT variants (libffi+, v8, mkdepend), \ + BSD-2c/BSD-3c (various parts), public domain (some tests)We only specify the license of the things actually installed to target (or
host). So not the build utils (mkdepend), not the things that are not installed (tests). The Mostly can also be removed. The / is not clear, you either use , for and, or ' or ' for or. BSD, MIT and public domain can be left out if the combined work (i.e. the binary) is anyway MPL/GPL - but they have to be included if it's for separate scripts. For historical reasons, we use MPLv1.1, GPLv2 and LGPLv2.1. Are all of them without +?
Quoted 1 line
Are there no license files at all?
Not in the spidermonkey tarball.
From what i understand, spidermonkey is a part of the mozilla code base. It also has been released as a standalone package, but not really properly. Hence no license, all stuff in a js/ subdirectory, some dependencies left on nspr and other weirdnesses.
I'll try to sort out the licenses, without cheating by looking at debian's copyright file.
Quoted 5 lines
package/spidermonkey185/Config.in line 15
Quoted 3 lines
package/spidermonkey185/Config.in new file +3
-0+ +SPIDERMONKEY185_CONF_ENV = \ + HOST_CXXFLAGS="$(HOST_CXXFLAGS) -DFORCE_$(BR2_ENDIAN)_ENDIAN"That doesn't look right: forcing target endianness in the host flags?
The build system compiles a jscpucfg.cpp for the host. The program outputs a C header file on standart output. It does things like determining whether the (host) architecture is little, big endian or mixed endian by runtime-testing it.
When cross compiling, it does funky things: If -DFORCE_BIG/LITTLE_ENDIAN isn't given, jscpucfg.cpp includes a header file which is normally part of nspr but not included in the spidermonkey tarball, so this fails. And it appears that this header file seems to be unused.
I'll add a comment.
Quoted 6 lines
package/spidermonkey185/Config.in
Quoted 4 lines
package/spidermonkey185/Config.in new file +4
-0+SPIDERMONKEY185_CONF_OPTS = \ + --target=$(GNU_TARGET_NAME) \ + --build=$(GNU_TARGET_NAME) \ + --host=$(GNU_HOST_NAME)This is already passed by the default
_CONFIGURE_CMDS.
Actually, not. Buildroot passes the correct value, but spidermonkey needs incorrect values. See this gem in configure.in:
# Note:
# In Mozilla, we use the names $target, $host and $build
incorrectly, but are
# too far gone to back out now. See Bug 475488:
# - When we say $target, we mean $host, that is, the system on which
# Mozilla will be run.
# - When we say $host, we mean $build, that is, the system on
which Mozilla
# is built.
# - $target (in its correct usage) is for compilers who generate
code for a
# different platform than $host, so it would not be used by Mozilla.
I'll add a comment.
Quoted 6 lines
package/spidermonkey185/Config.in
Quoted 2 lines
package/spidermonkey185/Config.in new file +2
-0+ +# This dependency does not make sense outside of the mozilla code base.How so? Either the libraries depend on libnspr so the dependency has to be
there, or they don't so the dependency should be removed - also within the mozilla code base.
The dependency is simply not used on Linux. This is probably a difference between the extracted spidermonkey source code and the mozilla code base. There are even some migration scripts that replace references to nspr by alternatives.
Quoted 5 lines
package/spidermonkey185/Config.in
Quoted 3 lines
package/spidermonkey185/Config.in new file +3
-0+define SPIDERMONKEY185_FIX_PC_NSPR_DEPENDENCY + sed -i -re 's/nspr >= 4.7//' \ + $(STAGING_DIR)/usr/lib/pkgconfig/mozjs185.pcI think I prefer a patch to .pc.in instead.
ok.
Quoted 11 lines
package/spidermonkey185/Config.in
Quoted 8 lines
package/spidermonkey185/Config.in new file +7
-0+endef + +SPIDERMONKEY185_POST_INSTALL_STAGING_HOOKS += \ + SPIDERMONKEY185_FIX_PC_NSPR_DEPENDENCY + + +# These symlinks are created absolute with DESTDIR embedded into it.Eek...
Quoted 5 lines
Quoted 1 line
+# Make them relative so they work on the target.
We probably want to do that in staging as well (for the long-term goal of
relocatableHOST_DIR). And perhaps it's easier to do that with a patch than with a hook - in particular if you manage to get AUTORECONF to work.
I'll try. There are variable indirections in there.
Quoted 17 lines
package/spidermonkey185/Config.in
Quoted 13 lines
package/spidermonkey185/Config.in new file +12
-0+define SPIDERMONKEY185_FIX_SHLIB_SYMLINK + ln -fs libmozjs185.so.1.0.0 $(TARGET_DIR)/usr/lib/libmozjs185.so + ln -fs libmozjs185.so.1.0.0 $(TARGET_DIR)/usr/lib/libmozjs185.so.1.0 +endef + +SPIDERMONKEY185_POST_INSTALL_TARGET_HOOKS += \ + SPIDERMONKEY185_FIX_SHLIB_SYMLINK + +$(eval $(autotools-package)) + +# Hack so configure/make is run inside the js/src subdirectory. +SPIDERMONKEY185_SRCDIR = $(SPIDERMONKEY185_DIR)/js/src/Just do
SPIDERMONKEY185_SUBDIR= js/src
(not a hack at all).
Done.