cinnamon.cjs: 4.6.0 -> 4.6.0-gjs1.66.0
This commit is contained in:
parent
1e80ede78d
commit
b77e830d9e
@ -1,6 +1,4 @@
|
|||||||
{ autoconf-archive
|
{ dbus-glib
|
||||||
, autoreconfHook
|
|
||||||
, dbus-glib
|
|
||||||
, fetchFromGitHub
|
, fetchFromGitHub
|
||||||
, gobject-introspection
|
, gobject-introspection
|
||||||
, pkgconfig
|
, pkgconfig
|
||||||
@ -17,26 +15,51 @@
|
|||||||
, libffi
|
, libffi
|
||||||
, gtk3
|
, gtk3
|
||||||
, readline
|
, readline
|
||||||
|
, spidermonkey_78
|
||||||
|
, meson
|
||||||
|
, sysprof
|
||||||
|
, dbus
|
||||||
|
, xvfb_run
|
||||||
|
, ninja
|
||||||
|
, makeWrapper
|
||||||
|
, which
|
||||||
|
, libxml2
|
||||||
}:
|
}:
|
||||||
|
|
||||||
let
|
|
||||||
|
|
||||||
# https://github.com/linuxmint/cjs/issues/80
|
|
||||||
spidermonkey_52 = callPackage ./spidermonkey_52.nix {};
|
|
||||||
|
|
||||||
in
|
|
||||||
|
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation rec {
|
||||||
pname = "cjs";
|
pname = "cjs";
|
||||||
version = "4.6.0";
|
version = "4.6.0-gjs-1.66.0";
|
||||||
|
|
||||||
src = fetchFromGitHub {
|
src = fetchFromGitHub {
|
||||||
owner = "linuxmint";
|
owner = "leigh123linux";
|
||||||
repo = pname;
|
repo = pname;
|
||||||
rev = version;
|
rev = "gjs-1.66.0";
|
||||||
sha256 = "1caa43cplb40dm1bwnwca7z4yafvnrncm96k7mih6kg3m87fxqi5";
|
sha256 = "1pccz7h8mwljziflhn04gmfnbl99pvcj1byz1c6zn947v5gqskj1";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
outputs = [ "out" "dev" ];
|
||||||
|
|
||||||
|
nativeBuildInputs = [
|
||||||
|
meson # ADDING cmake breaks the build, ignore meson warning
|
||||||
|
ninja
|
||||||
|
pkgconfig
|
||||||
|
makeWrapper
|
||||||
|
which # for locale detection
|
||||||
|
libxml2 # for xml-stripblanks
|
||||||
|
];
|
||||||
|
|
||||||
|
buildInputs = [
|
||||||
|
gobject-introspection
|
||||||
|
cairo
|
||||||
|
readline
|
||||||
|
spidermonkey_78
|
||||||
|
dbus # for dbus-run-session
|
||||||
|
];
|
||||||
|
|
||||||
|
checkInputs = [
|
||||||
|
xvfb_run
|
||||||
|
];
|
||||||
|
|
||||||
propagatedBuildInputs = [
|
propagatedBuildInputs = [
|
||||||
glib
|
glib
|
||||||
|
|
||||||
@ -47,25 +70,8 @@ stdenv.mkDerivation rec {
|
|||||||
xapps
|
xapps
|
||||||
];
|
];
|
||||||
|
|
||||||
nativeBuildInputs = [
|
mesonFlags = [
|
||||||
autoconf-archive
|
"-Dprofiler=disabled"
|
||||||
autoreconfHook
|
|
||||||
wrapGAppsHook
|
|
||||||
pkgconfig
|
|
||||||
];
|
|
||||||
|
|
||||||
buildInputs = [
|
|
||||||
# from .pc
|
|
||||||
gobject-introspection
|
|
||||||
libffi
|
|
||||||
spidermonkey_52 # mozjs-52
|
|
||||||
cairo # +cairo-gobject
|
|
||||||
gtk3
|
|
||||||
|
|
||||||
# other
|
|
||||||
|
|
||||||
dbus-glib
|
|
||||||
readline
|
|
||||||
];
|
];
|
||||||
|
|
||||||
meta = with stdenv.lib; {
|
meta = with stdenv.lib; {
|
||||||
@ -77,11 +83,12 @@ stdenv.mkDerivation rec {
|
|||||||
'';
|
'';
|
||||||
|
|
||||||
license = with licenses; [
|
license = with licenses; [
|
||||||
gpl2Plus
|
gpl2Plus
|
||||||
lgpl2Plus
|
lgpl2Plus
|
||||||
mit
|
mit
|
||||||
mpl11
|
mpl11
|
||||||
];
|
];
|
||||||
|
|
||||||
platforms = platforms.linux;
|
platforms = platforms.linux;
|
||||||
maintainers = teams.cinnamon.members;
|
maintainers = teams.cinnamon.members;
|
||||||
};
|
};
|
||||||
|
@ -1,39 +0,0 @@
|
|||||||
From 1b802175914418f5675047c34f1ab1593dd35b18 Mon Sep 17 00:00:00 2001
|
|
||||||
From: =?UTF-8?q?Maciej=20Kr=C3=BCger?= <mkg20001@gmail.com>
|
|
||||||
Date: Wed, 8 Jan 2020 11:04:27 +0100
|
|
||||||
Subject: [PATCH] fix werror
|
|
||||||
|
|
||||||
---
|
|
||||||
js/src/moz.build | 2 +-
|
|
||||||
js/src/shell/moz.build | 2 +-
|
|
||||||
2 files changed, 2 insertions(+), 2 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/js/src/moz.build b/js/src/moz.build
|
|
||||||
index 1162cb70c..595ea9842 100644
|
|
||||||
--- a/js/src/moz.build
|
|
||||||
+++ b/js/src/moz.build
|
|
||||||
@@ -785,7 +785,7 @@ if CONFIG['JS_HAS_CTYPES']:
|
|
||||||
DEFINES['FFI_BUILDING'] = True
|
|
||||||
|
|
||||||
if CONFIG['GNU_CXX']:
|
|
||||||
- CXXFLAGS += ['-Wno-shadow', '-Werror=format']
|
|
||||||
+ CXXFLAGS += ['-Wno-shadow']
|
|
||||||
|
|
||||||
# Suppress warnings in third-party code.
|
|
||||||
if CONFIG['CLANG_CXX']:
|
|
||||||
diff --git a/js/src/shell/moz.build b/js/src/shell/moz.build
|
|
||||||
index 72ea8145c..77475b241 100644
|
|
||||||
--- a/js/src/shell/moz.build
|
|
||||||
+++ b/js/src/shell/moz.build
|
|
||||||
@@ -51,7 +51,7 @@ shellmoduleloader.inputs = [
|
|
||||||
]
|
|
||||||
|
|
||||||
if CONFIG['GNU_CXX']:
|
|
||||||
- CXXFLAGS += ['-Wno-shadow', '-Werror=format']
|
|
||||||
+ CXXFLAGS += ['-Wno-shadow']
|
|
||||||
|
|
||||||
# This is intended as a temporary workaround to enable VS2015.
|
|
||||||
if CONFIG['_MSC_VER']:
|
|
||||||
--
|
|
||||||
2.17.1
|
|
||||||
|
|
@ -1,95 +0,0 @@
|
|||||||
{ stdenv, fetchurl, fetchpatch, autoconf213, pkgconfig, perl, zip, which, readline, icu, zlib, nspr, buildPackages }:
|
|
||||||
|
|
||||||
let
|
|
||||||
version = "52.9.0";
|
|
||||||
in stdenv.mkDerivation {
|
|
||||||
pname = "spidermonkey";
|
|
||||||
inherit version;
|
|
||||||
|
|
||||||
src = fetchurl {
|
|
||||||
url = "mirror://mozilla/firefox/releases/${version}esr/source/firefox-${version}esr.source.tar.xz";
|
|
||||||
sha256 = "1mlx34fgh1kaqamrkl5isf0npch3mm6s4lz3jsjb7hakiijhj7f0";
|
|
||||||
};
|
|
||||||
|
|
||||||
outputs = [ "out" "dev" ];
|
|
||||||
setOutputFlags = false; # Configure script only understands --includedir
|
|
||||||
|
|
||||||
buildInputs = [ readline icu zlib nspr ];
|
|
||||||
nativeBuildInputs = [ autoconf213 pkgconfig perl which buildPackages.python2 zip ];
|
|
||||||
|
|
||||||
# Apparently this package fails to build correctly with modern compilers, which at least
|
|
||||||
# on ARMv6 causes polkit testsuite to break with an assertion failure in spidermonkey.
|
|
||||||
# These flags were stolen from:
|
|
||||||
# https://git.archlinux.org/svntogit/packages.git/tree/trunk/PKGBUILD?h=packages/js52
|
|
||||||
NIX_CFLAGS_COMPILE = "-fno-delete-null-pointer-checks -fno-strict-aliasing -fno-tree-vrp";
|
|
||||||
|
|
||||||
patches = [
|
|
||||||
# needed to build gnome3.gjs
|
|
||||||
(fetchpatch {
|
|
||||||
name = "mozjs52-disable-mozglue.patch";
|
|
||||||
url = "https://git.archlinux.org/svntogit/packages.git/plain/trunk/mozjs52-disable-mozglue.patch?h=packages/js52&id=4279d2e18d9a44f6375f584911f63d13de7704be";
|
|
||||||
sha256 = "18wkss0agdyff107p5lfflk72qiz350xqw2yqc353alkx4fsfpz0";
|
|
||||||
})
|
|
||||||
(fetchpatch {
|
|
||||||
url = "https://git.archlinux.org/svntogit/packages.git/plain/trunk/no-error.diff?h=packages/js52";
|
|
||||||
sha256 = "1vsw6558lxiy0r1mg6y49cgddan1mfqvqlkyv734bgxyg6n3pb9i";
|
|
||||||
})
|
|
||||||
./fix-werror.patch
|
|
||||||
];
|
|
||||||
|
|
||||||
configurePlatforms = [ ];
|
|
||||||
|
|
||||||
preConfigure = ''
|
|
||||||
export CXXFLAGS="-fpermissive"
|
|
||||||
export LIBXUL_DIST=$out
|
|
||||||
export PYTHON="${buildPackages.python2.interpreter}"
|
|
||||||
configureFlagsArray+=("--includedir=$dev/include")
|
|
||||||
|
|
||||||
cd js/src
|
|
||||||
|
|
||||||
autoconf
|
|
||||||
'';
|
|
||||||
|
|
||||||
configureFlags = [
|
|
||||||
"--with-nspr-prefix=${nspr}"
|
|
||||||
"--with-system-zlib"
|
|
||||||
"--with-system-icu"
|
|
||||||
"--with-intl-api"
|
|
||||||
"--enable-readline"
|
|
||||||
"--enable-shared-js"
|
|
||||||
] ++ stdenv.lib.optional stdenv.hostPlatform.isMusl "--disable-jemalloc"
|
|
||||||
++ stdenv.lib.optionals (stdenv.hostPlatform != stdenv.buildPlatform) [
|
|
||||||
"--host=${stdenv.buildPlatform.config}"
|
|
||||||
"--target=${stdenv.hostPlatform.config}"
|
|
||||||
];
|
|
||||||
|
|
||||||
makeFlags = [
|
|
||||||
"HOST_CC=${buildPackages.stdenv.cc}/bin/cc"
|
|
||||||
];
|
|
||||||
|
|
||||||
depsBuildBuild = [ buildPackages.stdenv.cc ];
|
|
||||||
|
|
||||||
enableParallelBuilding = true;
|
|
||||||
|
|
||||||
postInstall = ''
|
|
||||||
moveToOutput bin/js52-config "$dev"
|
|
||||||
# Nuke a static lib.
|
|
||||||
rm $out/lib/libjs_static.ajs
|
|
||||||
'';
|
|
||||||
|
|
||||||
meta = with stdenv.lib; {
|
|
||||||
description = "Mozilla's JavaScript engine written in C/C++";
|
|
||||||
homepage = "https://developer.mozilla.org/en/SpiderMonkey";
|
|
||||||
license = licenses.gpl2; # TODO: MPL/GPL/LGPL tri-license.
|
|
||||||
maintainers = [ maintainers.abbradar ];
|
|
||||||
platforms = platforms.linux;
|
|
||||||
|
|
||||||
# Commented out so hydra builds the package
|
|
||||||
# (I know what you're thinking now, but cjs won't be pulling anything from the network
|
|
||||||
# and modules are allowed to execute commands anyways, so an RCE is basically irrelevant)
|
|
||||||
#
|
|
||||||
# knownVulnerabilities = [
|
|
||||||
# "The runtime was extracted from Firefox 52, which EOL’d on September 5, 2018."
|
|
||||||
# ];
|
|
||||||
};
|
|
||||||
}
|
|
Loading…
Reference in New Issue
Block a user