summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--extra/files/rust/check-rustc109
-rw-r--r--extra/patches/js78/disable-jslint.patch17
-rw-r--r--extra/patches/js78/fd6847c9416f9eebde636e21d794d25d1be8791d.patch37
-rw-r--r--extra/patches/js78/fix-musl-build.patch16
-rw-r--r--extra/patches/js78/fix-python3.10-compilation.patch300
-rw-r--r--extra/patches/js78/fix-rust-target.patch15
-rw-r--r--repo/devel/gcc.xibuild22
-rw-r--r--repo/devel/rustc.xibuild23
-rw-r--r--repo/skip/js78.xibuild55
-rw-r--r--repo/system/binutils.xibuild7
-rw-r--r--repo/system/js78.xibuild42
-rw-r--r--repo/util/keyutils.xibuild9
-rw-r--r--repo/xi/xipkg.xibuild2
-rw-r--r--repo/xi/xiutils.xibuild10
14 files changed, 593 insertions, 71 deletions
diff --git a/extra/files/rust/check-rustc b/extra/files/rust/check-rustc
new file mode 100644
index 0000000..d4b85be
--- /dev/null
+++ b/extra/files/rust/check-rustc
@@ -0,0 +1,109 @@
+#!/bin/sh
+# vim: set ts=4:
+set -eu
+
+RUSTC="$1"
+TMPDIR="$(pwd)/.tmp-${0##*/}-$RANDOM"
+failed=0
+
+unset RUST_BACKTRACE
+unset RUSTC_CRT_STATIC
+
+
+_rustc() {
+ printf '\n$ rustc %s\n' "$*"
+ "$RUSTC" "$@"
+}
+
+die() {
+ printf '\033[1;31mERROR:\033[0m %s\n' "$1" >&2 # bold red
+ exit 1
+}
+
+fail() {
+ printf '\033[1;31mFAIL:\033[0m %s\n' "$1" >&2 # bold red
+ failed=$(( failed + 1 ))
+}
+
+assert_dynamic() {
+ readelf -l "$1" | grep -Fqw INTERP \
+ && readelf -d "$1" | grep -Fqw NEEDED || {
+ fail "$1 is not a dynamic executable!"
+ readelf -ld "$1"
+ }
+}
+
+assert_ok() {
+ "$1" || fail "$1 exited with status $?"
+}
+
+assert_panic() {
+ local status=0
+ "$1" || status=$? && [ "$status" = 101 ] \
+ || fail "$1 exited with status $status, but expected 101"
+}
+
+assert_pie() {
+ readelf -d "$1" | grep -Fw FLAGS_1 | grep -Fqw PIE || {
+ fail "$1 is not a PIE executable!"
+ readelf -d "$1"
+ }
+}
+
+assert_static() {
+ test -f "$1" \
+ && ! readelf -l "$1" | grep -Fqw INTERP \
+ && ! readelf -d "$1" | grep -Fqw NEEDED || {
+ fail "$1 is not a static executable!"
+ readelf -ld "$1"
+ }
+}
+
+
+#-------------------- M a i n --------------------
+
+test -d "$TMPDIR" && die "$TMPDIR already exists!"
+mkdir -p "$TMPDIR"
+trap "rm -R '$TMPDIR'" EXIT
+
+cd "$TMPDIR"
+
+cat >> hello_world.rs <<-EOF
+ fn main() {
+ println!("Hello, world!");
+ }
+EOF
+
+_rustc hello_world.rs
+assert_ok ./hello_world
+assert_dynamic hello_world
+assert_pie hello_world
+rm -f hello_world
+
+_rustc -C target-feature=-crt-static hello_world.rs
+assert_ok ./hello_world
+assert_dynamic hello_world
+assert_pie hello_world
+rm -f hello_world
+
+_rustc -C target-feature=+crt-static hello_world.rs
+assert_ok ./hello_world
+assert_static hello_world
+assert_pie hello_world
+rm -f hello_world
+
+
+cat >> panic.rs <<-EOF
+ fn main() {
+ panic!("This should panic");
+ }
+EOF
+
+_rustc -C target-feature=-crt-static panic.rs
+assert_panic ./panic
+
+_rustc -C target-feature=+crt-static panic.rs
+assert_panic ./panic
+
+
+[ "$failed" -eq 0 ] || die "$failed assertion(s) has failed"
diff --git a/extra/patches/js78/disable-jslint.patch b/extra/patches/js78/disable-jslint.patch
new file mode 100644
index 0000000..04a8b3e
--- /dev/null
+++ b/extra/patches/js78/disable-jslint.patch
@@ -0,0 +1,17 @@
+--- a/js/src/build/moz.build
++++ b/js/src/build/moz.build
+@@ -80,14 +80,3 @@
+ NO_EXPAND_LIBS = True
+
+ DIST_INSTALL = True
+-
+-# Run SpiderMonkey style checker after linking the static library. This avoids
+-# running the script for no-op builds.
+-GeneratedFile(
+- 'spidermonkey_checks', script='/config/run_spidermonkey_checks.py',
+- inputs=[
+- '!%sjs_static.%s' % (CONFIG['LIB_PREFIX'], CONFIG['LIB_SUFFIX']),
+- '/config/check_spidermonkey_style.py',
+- '/config/check_macroassembler_style.py',
+- '/config/check_js_opcode.py'
+- ])
diff --git a/extra/patches/js78/fd6847c9416f9eebde636e21d794d25d1be8791d.patch b/extra/patches/js78/fd6847c9416f9eebde636e21d794d25d1be8791d.patch
new file mode 100644
index 0000000..1af68d9
--- /dev/null
+++ b/extra/patches/js78/fd6847c9416f9eebde636e21d794d25d1be8791d.patch
@@ -0,0 +1,37 @@
+See https://bugzilla.mozilla.org/show_bug.cgi?id=1539739
+
+From fd6847c9416f9eebde636e21d794d25d1be8791d Mon Sep 17 00:00:00 2001
+From: Mike Hommey <mh@glandium.org>
+Date: Sat, 1 Jun 2019 09:06:01 +0900
+Subject: [PATCH] Bug 1526653 - Include struct definitions for user_vfp and
+ user_vfp_exc.
+
+---
+ js/src/wasm/WasmSignalHandlers.cpp | 11 ++++++++++-
+ 1 file changed, 10 insertions(+), 1 deletion(-)
+
+diff --git a/js/src/wasm/WasmSignalHandlers.cpp b/js/src/wasm/WasmSignalHandlers.cpp
+index 636537f8478..383c380f04c 100644
+--- a/js/src/wasm/WasmSignalHandlers.cpp
++++ b/js/src/wasm/WasmSignalHandlers.cpp
+@@ -248,7 +248,16 @@ using mozilla::DebugOnly;
+ #endif
+
+ #ifdef WASM_EMULATE_ARM_UNALIGNED_FP_ACCESS
+-# include <sys/user.h>
++struct user_vfp {
++ unsigned long long fpregs[32];
++ unsigned long fpscr;
++};
++
++struct user_vfp_exc {
++ unsigned long fpexc;
++ unsigned long fpinst;
++ unsigned long fpinst2;
++};
+ #endif
+
+ #if defined(ANDROID)
+--
+2.20.1
+
diff --git a/extra/patches/js78/fix-musl-build.patch b/extra/patches/js78/fix-musl-build.patch
new file mode 100644
index 0000000..af39467
--- /dev/null
+++ b/extra/patches/js78/fix-musl-build.patch
@@ -0,0 +1,16 @@
+Upstream: No
+Reason: mozjs60 miscompiles on musl if built with HAVE_THREAD_TLS_KEYWORD:
+https://github.com/void-linux/void-packages/issues/2598
+diff --git a/js/src/old-configure.in b/js/src/old-configure.in
+--- a/js/src/old-configure.in
++++ b/js/src/old-configure.in
+@@ -1272,6 +1272,9 @@
+ *-android*|*-linuxandroid*)
+ :
+ ;;
++ *-musl*)
++ :
++ ;;
+ *)
+ AC_DEFINE(HAVE_THREAD_TLS_KEYWORD)
+ ;;
diff --git a/extra/patches/js78/fix-python3.10-compilation.patch b/extra/patches/js78/fix-python3.10-compilation.patch
new file mode 100644
index 0000000..7f5f507
--- /dev/null
+++ b/extra/patches/js78/fix-python3.10-compilation.patch
@@ -0,0 +1,300 @@
+#https://src.fedoraproject.org/rpms/mozjs78/blob/rawhide/f/Fixup-compatibility-of-mozbuild-with-Python-3.10.patch
+
+m a88d0c8e27b48344942187c2611bb121bde9332d Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Franti=C5=A1ek=20Zatloukal?= <fzatlouk@redhat.com>
+Date: Tue, 13 Jul 2021 11:46:20 +0200
+Subject: [PATCH] Fixup compatibility of mozbuild with Python 3.10
+
+---
+ python/mach/mach/config.py | 4 ++--
+ python/mach/mach/decorators.py | 2 +-
+ python/mozbuild/mozbuild/backend/configenvironment.py | 3 ++-
+ python/mozbuild/mozbuild/makeutil.py | 2 +-
+ python/mozbuild/mozbuild/util.py | 2 +-
+ testing/marionette/client/marionette_driver/wait.py | 2 +-
+ testing/mozbase/manifestparser/manifestparser/filters.py | 3 ++-
+ testing/mozbase/versioninfo.py | 2 +-
+ testing/web-platform/tests/tools/manifest/vcs.py | 2 +-
+ .../web-platform/tests/tools/third_party/h2/h2/settings.py | 2 +-
+ .../tests/tools/third_party/html5lib/html5lib/_trie/_base.py | 2 +-
+ .../tools/third_party/html5lib/html5lib/treebuilders/dom.py | 2 +-
+ .../tests/tools/third_party/hyper/hyper/common/headers.py | 2 +-
+ .../tests/tools/third_party/hyper/hyper/h2/settings.py | 2 +-
+ .../tests/tools/third_party/hyper/hyper/http11/connection.py | 4 ++--
+ .../third_party/hyper/hyper/packages/hyperframe/flags.py | 2 +-
+ .../tests/tools/third_party/hyperframe/hyperframe/flags.py | 2 +-
+ testing/web-platform/tests/tools/wptserve/wptserve/config.py | 3 ++-
+ testing/web-platform/tests/webdriver/tests/support/sync.py | 2 +-
+ 19 files changed, 24 insertions(+), 21 deletions(-)
+
+diff --git a/python/mach/mach/config.py b/python/mach/mach/config.py
+index 7210eca82..edb4d2e93 100644
+--- a/python/mach/mach/config.py
++++ b/python/mach/mach/config.py
+@@ -144,7 +144,7 @@ def reraise_attribute_error(func):
+ return _
+
+
+-class ConfigSettings(collections.Mapping):
++class ConfigSettings(collections.abc.Mapping):
+ """Interface for configuration settings.
+
+ This is the main interface to the configuration.
+@@ -190,7 +190,7 @@ class ConfigSettings(collections.Mapping):
+ will result in exceptions being raised.
+ """
+
+- class ConfigSection(collections.MutableMapping, object):
++ class ConfigSection(collections.abc.MutableMapping, object):
+ """Represents an individual config section."""
+ def __init__(self, config, name, settings):
+ object.__setattr__(self, '_config', config)
+diff --git a/python/mach/mach/decorators.py b/python/mach/mach/decorators.py
+index 27f7f34a6..5f63271a3 100644
+--- a/python/mach/mach/decorators.py
++++ b/python/mach/mach/decorators.py
+@@ -140,7 +140,7 @@ def CommandProvider(cls):
+ 'Conditions argument must take a list ' + \
+ 'of functions. Found %s instead.'
+
+- if not isinstance(command.conditions, collections.Iterable):
++ if not isinstance(command.conditions, collections.abc.Iterable):
+ msg = msg % (command.name, type(command.conditions))
+ raise MachError(msg)
+
+diff --git a/python/mozbuild/mozbuild/backend/configenvironment.py b/python/mozbuild/mozbuild/backend/configenvironment.py
+index 20d1a9fa6..8747958bd 100644
+--- a/python/mozbuild/mozbuild/backend/configenvironment.py
++++ b/python/mozbuild/mozbuild/backend/configenvironment.py
+@@ -9,7 +9,8 @@ import six
+ import sys
+ import json
+
+-from collections import Iterable, OrderedDict
++from collections import OrderedDict
++from collections.abc import Iterable
+ from types import ModuleType
+
+ import mozpack.path as mozpath
+diff --git a/python/mozbuild/mozbuild/makeutil.py b/python/mozbuild/mozbuild/makeutil.py
+index 4da1a3b26..4ce56848c 100644
+--- a/python/mozbuild/mozbuild/makeutil.py
++++ b/python/mozbuild/mozbuild/makeutil.py
+@@ -7,7 +7,7 @@ from __future__ import absolute_import, print_function, unicode_literals
+ import os
+ import re
+ import six
+-from collections import Iterable
++from collections.abc import Iterable
+
+
+ class Makefile(object):
+diff --git a/python/mozbuild/mozbuild/util.py b/python/mozbuild/mozbuild/util.py
+index 044cf645c..98ed3ef52 100644
+--- a/python/mozbuild/mozbuild/util.py
++++ b/python/mozbuild/mozbuild/util.py
+@@ -782,7 +782,7 @@ class HierarchicalStringList(object):
+ self._strings = StrictOrderingOnAppendList()
+ self._children = {}
+
+- class StringListAdaptor(collections.Sequence):
++ class StringListAdaptor(collections.abc.Sequence):
+ def __init__(self, hsl):
+ self._hsl = hsl
+
+diff --git a/testing/marionette/client/marionette_driver/wait.py b/testing/marionette/client/marionette_driver/wait.py
+index eeaa1e23d..c147f463f 100644
+--- a/testing/marionette/client/marionette_driver/wait.py
++++ b/testing/marionette/client/marionette_driver/wait.py
+@@ -82,7 +82,7 @@ class Wait(object):
+
+ exceptions = []
+ if ignored_exceptions is not None:
+- if isinstance(ignored_exceptions, collections.Iterable):
++ if isinstance(ignored_exceptions, collections.abc.Iterable):
+ exceptions.extend(iter(ignored_exceptions))
+ else:
+ exceptions.append(ignored_exceptions)
+diff --git a/testing/mozbase/manifestparser/manifestparser/filters.py b/testing/mozbase/manifestparser/manifestparser/filters.py
+index 287ee033b..b1d608003 100644
+--- a/testing/mozbase/manifestparser/manifestparser/filters.py
++++ b/testing/mozbase/manifestparser/manifestparser/filters.py
+@@ -12,7 +12,8 @@ from __future__ import absolute_import
+
+ import itertools
+ import os
+-from collections import defaultdict, MutableSequence
++from collections import defaultdict
++from collections.abc import MutableSequence
+
+ import six
+ from six import string_types
+diff --git a/testing/mozbase/versioninfo.py b/testing/mozbase/versioninfo.py
+index 91d1a0473..8c1680069 100755
+--- a/testing/mozbase/versioninfo.py
++++ b/testing/mozbase/versioninfo.py
+@@ -11,7 +11,7 @@ from commit messages.
+
+ from __future__ import absolute_import, print_function
+
+-from collections import Iterable
++from collections.abc import Iterable
+ from distutils.version import StrictVersion
+ import argparse
+ import os
+diff --git a/testing/web-platform/tests/tools/manifest/vcs.py b/testing/web-platform/tests/tools/manifest/vcs.py
+index 7c0feeb81..05ee19c7c 100644
+--- a/testing/web-platform/tests/tools/manifest/vcs.py
++++ b/testing/web-platform/tests/tools/manifest/vcs.py
+@@ -3,7 +3,7 @@ import json
+ import os
+ import stat
+ from collections import deque
+-from collections import MutableMapping
++from collections.abc import MutableMapping
+
+ from six import with_metaclass, PY2
+
+diff --git a/testing/web-platform/tests/tools/third_party/h2/h2/settings.py b/testing/web-platform/tests/tools/third_party/h2/h2/settings.py
+index 3da720329..e097630e9 100644
+--- a/testing/web-platform/tests/tools/third_party/h2/h2/settings.py
++++ b/testing/web-platform/tests/tools/third_party/h2/h2/settings.py
+@@ -88,7 +88,7 @@ class ChangedSetting:
+ )
+
+
+-class Settings(collections.MutableMapping):
++class Settings(collections.abc.MutableMapping):
+ """
+ An object that encapsulates HTTP/2 settings state.
+
+diff --git a/testing/web-platform/tests/tools/third_party/html5lib/html5lib/_trie/_base.py b/testing/web-platform/tests/tools/third_party/html5lib/html5lib/_trie/_base.py
+index a1158bbbf..a9295a2ba 100644
+--- a/testing/web-platform/tests/tools/third_party/html5lib/html5lib/_trie/_base.py
++++ b/testing/web-platform/tests/tools/third_party/html5lib/html5lib/_trie/_base.py
+@@ -1,6 +1,6 @@
+ from __future__ import absolute_import, division, unicode_literals
+
+-from collections import Mapping
++from collections.abc import Mapping
+
+
+ class Trie(Mapping):
+diff --git a/testing/web-platform/tests/tools/third_party/html5lib/html5lib/treebuilders/dom.py b/testing/web-platform/tests/tools/third_party/html5lib/html5lib/treebuilders/dom.py
+index dcfac220b..818a33433 100644
+--- a/testing/web-platform/tests/tools/third_party/html5lib/html5lib/treebuilders/dom.py
++++ b/testing/web-platform/tests/tools/third_party/html5lib/html5lib/treebuilders/dom.py
+@@ -1,7 +1,7 @@
+ from __future__ import absolute_import, division, unicode_literals
+
+
+-from collections import MutableMapping
++from collections.abc import MutableMapping
+ from xml.dom import minidom, Node
+ import weakref
+
+diff --git a/testing/web-platform/tests/tools/third_party/hyper/hyper/common/headers.py b/testing/web-platform/tests/tools/third_party/hyper/hyper/common/headers.py
+index 655a591ac..6454f550a 100644
+--- a/testing/web-platform/tests/tools/third_party/hyper/hyper/common/headers.py
++++ b/testing/web-platform/tests/tools/third_party/hyper/hyper/common/headers.py
+@@ -10,7 +10,7 @@ import collections
+ from hyper.common.util import to_bytestring, to_bytestring_tuple
+
+
+-class HTTPHeaderMap(collections.MutableMapping):
++class HTTPHeaderMap(collections.abc.MutableMapping):
+ """
+ A structure that contains HTTP headers.
+
+diff --git a/testing/web-platform/tests/tools/third_party/hyper/hyper/h2/settings.py b/testing/web-platform/tests/tools/third_party/hyper/hyper/h2/settings.py
+index fedc5e3c4..040afea92 100755
+--- a/testing/web-platform/tests/tools/third_party/hyper/hyper/h2/settings.py
++++ b/testing/web-platform/tests/tools/third_party/hyper/hyper/h2/settings.py
+@@ -151,7 +151,7 @@ class ChangedSetting:
+ )
+
+
+-class Settings(collections.MutableMapping):
++class Settings(collections.abc.MutableMapping):
+ """
+ An object that encapsulates HTTP/2 settings state.
+
+diff --git a/testing/web-platform/tests/tools/third_party/hyper/hyper/http11/connection.py b/testing/web-platform/tests/tools/third_party/hyper/hyper/http11/connection.py
+index 61361c358..a214311d2 100644
+--- a/testing/web-platform/tests/tools/third_party/hyper/hyper/http11/connection.py
++++ b/testing/web-platform/tests/tools/third_party/hyper/hyper/http11/connection.py
+@@ -10,7 +10,7 @@ import os
+ import socket
+ import base64
+
+-from collections import Iterable, Mapping
++from collections.abc import Iterable, Mapping
+
+ import collections
+ from hyperframe.frame import SettingsFrame
+@@ -295,7 +295,7 @@ class HTTP11Connection(object):
+ return
+
+ # Iterables that set a specific content length.
+- elif isinstance(body, collections.Iterable):
++ elif isinstance(body, collections.abc.Iterable):
+ for item in body:
+ try:
+ self._sock.send(item)
+diff --git a/testing/web-platform/tests/tools/third_party/hyper/hyper/packages/hyperframe/flags.py b/testing/web-platform/tests/tools/third_party/hyper/hyper/packages/hyperframe/flags.py
+index e8f630056..8f2ea689b 100644
+--- a/testing/web-platform/tests/tools/third_party/hyper/hyper/packages/hyperframe/flags.py
++++ b/testing/web-platform/tests/tools/third_party/hyper/hyper/packages/hyperframe/flags.py
+@@ -11,7 +11,7 @@ import collections
+ Flag = collections.namedtuple("Flag", ["name", "bit"])
+
+
+-class Flags(collections.MutableSet):
++class Flags(collections.abc.MutableSet):
+ """
+ A simple MutableSet implementation that will only accept known flags as elements.
+
+diff --git a/testing/web-platform/tests/tools/third_party/hyperframe/hyperframe/flags.py b/testing/web-platform/tests/tools/third_party/hyperframe/hyperframe/flags.py
+index 05b35017e..14c352e10 100644
+--- a/testing/web-platform/tests/tools/third_party/hyperframe/hyperframe/flags.py
++++ b/testing/web-platform/tests/tools/third_party/hyperframe/hyperframe/flags.py
+@@ -11,7 +11,7 @@ import collections
+ Flag = collections.namedtuple("Flag", ["name", "bit"])
+
+
+-class Flags(collections.MutableSet):
++class Flags(collections.abc.MutableSet):
+ """
+ A simple MutableSet implementation that will only accept known flags as
+ elements.
+diff --git a/testing/web-platform/tests/tools/wptserve/wptserve/config.py b/testing/web-platform/tests/tools/wptserve/wptserve/config.py
+index 7766565fe..3c1c36d6f 100644
+--- a/testing/web-platform/tests/tools/wptserve/wptserve/config.py
++++ b/testing/web-platform/tests/tools/wptserve/wptserve/config.py
+@@ -2,7 +2,8 @@ import copy
+ import logging
+ import os
+
+-from collections import defaultdict, Mapping
++from collections import defaultdict
++from collections.abc import Mapping
+ from six import integer_types, iteritems, itervalues, string_types
+
+ from . import sslutils
+diff --git a/testing/web-platform/tests/webdriver/tests/support/sync.py b/testing/web-platform/tests/webdriver/tests/support/sync.py
+index 3fc77131c..8e8f6b819 100644
+--- a/testing/web-platform/tests/webdriver/tests/support/sync.py
++++ b/testing/web-platform/tests/webdriver/tests/support/sync.py
+@@ -81,7 +81,7 @@ class Poll(object):
+
+ exceptions = []
+ if ignored_exceptions is not None:
+- if isinstance(ignored_exceptions, collections.Iterable):
++ if isinstance(ignored_exceptions, collections.abc.Iterable):
+ exceptions.extend(iter(ignored_exceptions))
+ else:
+ exceptions.append(ignored_exceptions)
+--
+2.31.1
+
+
diff --git a/extra/patches/js78/fix-rust-target.patch b/extra/patches/js78/fix-rust-target.patch
new file mode 100644
index 0000000..f1a98df
--- /dev/null
+++ b/extra/patches/js78/fix-rust-target.patch
@@ -0,0 +1,15 @@
+Allow us to just set RUST_TARGEt ourselves instead of hacking around in mozilla's
+weird custom build system...
+
+diff -upr firefox-68.9.0.orig/build/moz.configure/rust.configure firefox-68.9.0/build/moz.configure/rust.configure
+--- firefox-68.9.0.orig/build/moz.configure/rust.configure 2020-06-02 22:54:39.982616128 +0200
++++ firefox-68.9.0/build/moz.configure/rust.configure 2020-06-02 23:08:37.656332899 +0200
+@@ -345,7 +345,7 @@ def rust_triple_alias(host_or_target):
+
+ return None
+
+- rustc_target = find_candidate(candidates)
++ rustc_target = os.environ['RUST_TARGET']
+
+ if rustc_target is None:
+ die("Don't know how to translate {} for rustc".format(
diff --git a/repo/devel/gcc.xibuild b/repo/devel/gcc.xibuild
index bceb9c2..18b6e2e 100644
--- a/repo/devel/gcc.xibuild
+++ b/repo/devel/gcc.xibuild
@@ -1,6 +1,6 @@
#!/bin/sh
-MAKEDEPS="grep make dejagnu inetutils"
+MAKEDEPS="grep make dejagnu inetutils flex"
DEPS="musl binutils mpc mpfr gmp"
PKG_VER=11.2.0
@@ -19,10 +19,8 @@ ADDITIONAL="
$PATCH_SRC/0007-Enable-Wtrampolines-by-default.patch
$PATCH_SRC/0009-Ensure-that-msgfmt-doesn-t-encounter-problems-during.patch
$PATCH_SRC/0010-Don-t-declare-asprintf-if-defined-as-a-macro.patch
- $PATCH_SRC/0011-libiberty-copy-PIC-objects-during-build-process.patch
$PATCH_SRC/0012-libitm-disable-FORTIFY.patch
$PATCH_SRC/0013-libgcc_s.patch
- $PATCH_SRC/0014-nopie.patch
$PATCH_SRC/0015-libffi-use-__linux__-instead-of-__gnu_linux__-for-mu.patch
$PATCH_SRC/0016-dlang-update-zlib-binding.patch
$PATCH_SRC/0017-dlang-fix-fcntl-on-mips-add-libucontext-dep.patch
@@ -79,11 +77,8 @@ prepare () {
tar xf isl-$ISL_VER.tar.xz
mv isl-$ISL_VER isl
-
- for p in *.patch; do
- patch -Np1 -i $p || true
- done
-
+
+ apply_patches
}
build () {
@@ -115,7 +110,6 @@ build () {
export FON+="--enable-tls "
export FON+="--enable-libstdcxx-time "
export FON+="--enable-fully-dynamic-string "
- export FON+="--enable-default-pie "
export FON+="--enable-default-ssp "
export FON+="--enable-linker-build-id "
export FON+="--enable-checking=release "
@@ -137,9 +131,9 @@ build () {
make &&
cd .. &&
- cc -fpie getent.c -o getent &&
- cc -fpie getconf.c -o getconf &&
- cc -fpie iconv.c -o iconv
+ cc getent.c -o getent &&
+ cc getconf.c -o getconf &&
+ cc iconv.c -o iconv
}
check () {
@@ -177,5 +171,9 @@ package () {
mkdir -p $PKG_DEST/usr/share/gdb/auto-load/usr/lib
#mv $PKG_DEST/usr/lib/*gdb.py $PKG_DEST/usr/share/gdb/auto-load/usr/lib
+ for p in gcov gcc-ar gcc gcc-ranlib c++ g++ gcc-nm lto-dump gcov-tools gcov-dump cpp; do
+ ln -s $TRUPLE-$p $PKG_DEST/usr/bin/$p
+ done
+
}
diff --git a/repo/devel/rustc.xibuild b/repo/devel/rustc.xibuild
index d8cebf5..1e4df28 100644
--- a/repo/devel/rustc.xibuild
+++ b/repo/devel/rustc.xibuild
@@ -7,18 +7,25 @@ PKG_VER=1.58.1
SOURCE=https://static.rust-lang.org/dist/rustc-$PKG_VER-src.tar.gz
DESC="Systems programming language focused on safety, speed and concurrency"
+ADDITIONAL="
+ https://git.alpinelinux.org/aports/plain/community/rust/link-musl-dynamically.patch
+"
+
prepare () {
+
+ apply_patches
+
mkdir -p $PKG_DEST/opt/rustc-$PKG_VER &&
ln -sf rustc-$PKG_VER $PKG_DEST/opt/rustc
- openssl_file=vendor/openssl-sys/build/main.rs
- checksum_before=$(sha256sum $openssl_file | cut -d' ' -f1)
- sed -i "240i (3, 4, _) => ('3', '4', 'x')," $openssl_file
- checksum_after=$(sha256sum $openssl_file | cut -d' ' -f1)
- echo "checksum before: $checksum_before"
- echo "checksum after: $checksum_after"
+ #openssl_file=vendor/openssl-sys/build/main.rs
+ #checksum_before=$(sha256sum $openssl_file | cut -d' ' -f1)
+ #sed -i "240i (3, 4, _) => ('3', '4', 'x')," $openssl_file
+ #checksum_after=$(sha256sum $openssl_file | cut -d' ' -f1)
+ #echo "checksum before: $checksum_before"
+ #echo "checksum after: $checksum_after"
- sed -i "s/$checksum_before/$checksum_after/g" vendor/openssl-sys/.cargo-checksum.json
+ #sed -i "s/$checksum_before/$checksum_after/g" vendor/openssl-sys/.cargo-checksum.json
}
@@ -43,7 +50,7 @@ build () {
--set="rust.musl-root=/usr" \
--set="rust.codegen-units=1" \
--set="rust.codegen-units-std=1" \
- --set="rust.parallel-compiler=false" \
+ --set="rust.parallel-compiler=true" \
--set="target.$target.llvm-config=/usr/bin/llvm-config" \
--set="target.$target.musl-root=/usr" \
--set="target.$target.crt-static=false" \
diff --git a/repo/skip/js78.xibuild b/repo/skip/js78.xibuild
new file mode 100644
index 0000000..8ac277c
--- /dev/null
+++ b/repo/skip/js78.xibuild
@@ -0,0 +1,55 @@
+#!/bin/sh
+
+MAKEDEPS="gcc autoconf2-13 icu rustc zlib which zip llvm patch make"
+DEPS="readline nspr bash zlib"
+
+PKG_VER=78.15.0
+SOURCE=https://archive.mozilla.org/pub/firefox/releases/${PKG_VER}esr/source/firefox-${PKG_VER}esr.source.tar.xz
+ADDITIONAL="
+ patches/js78/disable-jslint.patch
+ patches/js78/fd6847c9416f9eebde636e21d794d25d1be8791d.patch
+ patches/js78/fix-musl-build.patch
+ patches/js78/fix-python3.10-compilation.patch
+ "
+
+DESC="JavaScript interpreter and libraries - Version 78"
+
+prepare () {
+ apply_patches
+
+ mountpoint -q /dev/shm || mount -t tmpfs devshm /dev/shm
+ export PATH=/opt/rustc/bin:$PATH
+ export LD_LIBRARY_PATH=/opt/rustc/lib:$LD_LIBRARY_PATH
+}
+
+build () {
+ mkdir obj &&
+ cd obj &&
+
+ CC=gcc CXX=g++ \
+ CFLAGS="-fPIE -fPIC" CXXFLAGS="-fPIE -fPIC" SHELL=/bin/bash PYTHON=/usr/bin/python3 \
+ ../js/src/configure --prefix=/usr \
+ --disable-jemalloc \
+ --disable-optimize \
+ --enable-ctypes \
+ --enable-readline \
+ --enable-shared-js \
+ --enable-system-ffi \
+ --enable-tests \
+ --with-intl-api \
+ --with-system-icu \
+ --with-system-nspr \
+ --enable-hardening \
+ --enable-release \
+ --with-system-zlib \
+ --host=x86_64-linux-musl
+
+ make -j1
+
+}
+
+package () {
+ make DESTDIR=$PKG_DEST install
+ [ -f $PKG_DEST/usr/lib/libjs_static.ajs ] && rm $PKG_DEST/usr/lib/libjs_static.ajs
+ sed -i '/@NSPR_CFLAGS@/d' $PKG_DEST/usr/bin/js78-config
+}
diff --git a/repo/system/binutils.xibuild b/repo/system/binutils.xibuild
index d57d538..b8f383e 100644
--- a/repo/system/binutils.xibuild
+++ b/repo/system/binutils.xibuild
@@ -49,9 +49,8 @@ build () {
--enable-threads \
--disable-multilib \
--with-mmap \
- --with-pic \
--enable-64-bit-bfd \
- --with-pic $EXTRA_CONFIG
+ $EXTRA_CONFIG
make tooldir=/usr
}
@@ -65,8 +64,8 @@ package() {
cd ..
# how about we use binutils ld?
- #rm -f $PKG_DEST/usr/bin/ld
- #ln -sf /usr/bin/ld.bfd $PKG_DEST/usr/bin/ld
+ rm -f $PKG_DEST/usr/bin/ld
+ ln -sf /usr/bin/ld.bfd $PKG_DEST/usr/bin/ld
install -m 644 include/libiberty.h $PKG_DEST/usr/include
install -m 644 include/demangle.h $PKG_DEST/usr/include
diff --git a/repo/system/js78.xibuild b/repo/system/js78.xibuild
deleted file mode 100644
index 7b88f18..0000000
--- a/repo/system/js78.xibuild
+++ /dev/null
@@ -1,42 +0,0 @@
-#!/bin/sh
-
-MAKEDEPS="gcc autoconf2-13 icu rustc which zip llvm patch make"
-DEPS="readline bash zlib"
-
-PKG_VER=78.15.0
-SOURCE=https://archive.mozilla.org/pub/firefox/releases/${PKG_VER}esr/source/firefox-${PKG_VER}esr.source.tar.xz
-ADDITIONAL="
- https://www.linuxfromscratch.org/patches/blfs/svn/js-$PKG_VER-python_3_10-1.patch
- "
-
-DESC="JavaScript interpreter and libraries - Version 78"
-
-prepare () {
- patch -Np1 -i js-$PKG_VER-python_3_10-1.patch
-
- mountpoint -q /dev/shm || mount -t tmpfs devshm /dev/shm
- export PATH=/opt/rustc/bin:$PATH
- export LD_LIBRARY_PATH=/opt/rustc/lib:$LD_LIBRARY_PATH
-}
-
-build () {
- mkdir obj &&
- cd obj &&
-
- CC=gcc CXX=g++ \
- ../js/src/configure --prefix=/usr \
- --with-intl-api \
- --with-system-zlib \
- --with-system-icu \
- --disable-jemalloc \
- --disable-debug-symbols \
- --enable-readline &&
- make
-
-}
-
-package () {
- make DESTDIR=$PKG_DEST install
- [ -f $PKG_DEST/usr/lib/libjs_static.ajs ] && rm $PKG_DEST/usr/lib/libjs_static.ajs
- sed -i '/@NSPR_CFLAGS@/d' $PKG_DEST/usr/bin/js78-config
-}
diff --git a/repo/util/keyutils.xibuild b/repo/util/keyutils.xibuild
index d1aa438..d966a89 100644
--- a/repo/util/keyutils.xibuild
+++ b/repo/util/keyutils.xibuild
@@ -1,6 +1,6 @@
#!/bin/sh
-MAKEDEPS="make "
+MAKEDEPS="make file"
DEPS="musl sh"
PKG_VER=1.6.3
@@ -12,5 +12,10 @@ build () {
}
package () {
- make DESTDIR=$PKG_DEST install
+ make DESTDIR=$PKG_DEST \
+ NO_ARLIB=1 \
+ LIBDIR=/usr/lib \
+ USRLIBDIR=/usr/lib \
+ install
+
}
diff --git a/repo/xi/xipkg.xibuild b/repo/xi/xipkg.xibuild
index bebde6b..f98ab19 100644
--- a/repo/xi/xipkg.xibuild
+++ b/repo/xi/xipkg.xibuild
@@ -3,7 +3,7 @@
MAKEDEPS="make"
DEPS="openssl curl dash xiutils findutils diffutils sed xichroot grep"
-PKG_VER=1.0.4
+PKG_VER=1.1.0
SOURCE=https://git.davidovski.xyz/xilinux/xipkg.git
BRANCH="v$PKG_VER"
diff --git a/repo/xi/xiutils.xibuild b/repo/xi/xiutils.xibuild
index c3b9a10..c8f7bf6 100644
--- a/repo/xi/xiutils.xibuild
+++ b/repo/xi/xiutils.xibuild
@@ -3,7 +3,7 @@
MAKEDEPS="gcc"
DEPS="bash"
-PKG_VER=1.0.1
+PKG_VER=1.0.2
SOURCE=https://git.davidovski.xyz/xilinux/xiutils.git
BRANCH="v$PKG_VER"
@@ -13,7 +13,13 @@ build () {
make
}
+check () {
+ make check
+}
+
package () {
- mkdir -pv $PKG_DEST/usr/{include,bin,lib}
+ for dir in include bin lib; do
+ mkdir -p $PKG_DEST/usr/$dir
+ done
make DESTDIR=$PKG_DEST install
}