Commit graph

266 commits

Author SHA1 Message Date
Baitinq
48389f4179 Toolchain: serenity.nix: Fix fuse2fs not being installed
Nix (nixpkgs) have updated a while back how the e2fsprogs derivation
works and now fuse2fs wasnt being installed with it. It is now needed to
add a new derivation (package) to the dependency list: "fuse2fs". This
fixes the Meta/serenity.sh script not finding the fuse2fs binary for
rootless image building :^)
2022-10-06 16:16:51 +01:00
Liav A
74018be739 Meta: Make x86-64 target the default
This is a preparation to check if our users find noticeable bugs in the
x86-64 target, before we can decide if we want to remove the i686 target
for good.
2022-10-03 11:14:53 +02:00
Andrew Kaster
9c32b9ea3c Toolchain: Update BuildMold to mold 1.5.1 and use CMake
Per the release notes for 1.5.0, the CMake build is preferred going
forward.
2022-10-03 10:01:06 +01:00
Tim Schumacher
eb6c911b3a Toolchain: Hardcode the results of LLVM runtime library detection
This keeps us from accidentally building toolchains that don't make it
through a clean build if we build them using a populated sysroot, as it
would otherwise detect libpthread and friends and try to pull them in
while LibC is not yet built.
2022-10-01 18:59:51 +01:00
Tim Schumacher
b52b6e8739 Toolchain: Only reextract GCC-related tarballs if patches change
This brings the behaviour in line with Clang, which already does this
since a few revisions.
2022-10-01 18:43:29 +01:00
Tim Schumacher
1faca15193 Toolchain: Move the binutils patch into its own folder
This makes binutils compatible with `./package.sh dev`, so that we can
regenerate patches more easily, and neatly stack (temporary) patches on
top.
2022-10-01 18:43:29 +01:00
Tim Schumacher
cb2f0d9861 Toolchain: Regenerate patches using the latest format rules 2022-09-18 13:00:46 +04:30
Tim Schumacher
77f124c87a Toolchain: Remove references to -lm 2022-09-16 16:09:19 +00:00
Tim Schumacher
1b25c38b8b Everywhere: Fully remove the separate LibM directory 2022-09-16 16:09:19 +00:00
Tim Schumacher
81d46fa100 LibM: Move the math standard library to LibC 2022-09-16 16:09:19 +00:00
Tim Schumacher
f45238db0f Toolchain: Update to LLVM 15.0.0 2022-09-16 05:39:28 +00:00
Tim Schumacher
39477e923f Toolchain: Remove references to -ldl 2022-09-05 10:12:02 +01:00
Tim Schumacher
8778bb3473 Everywhere: Fully remove the separate LibDl directory 2022-09-05 10:12:02 +01:00
Tim Schumacher
226608a48f LibDl: Move the dlfcn implementation to LibC 2022-09-05 10:12:02 +01:00
Veronika Horáčků
6587638ffe Toolchain: Update Dockerfile to ubuntu:22.10 2022-09-02 23:50:49 +01:00
Brian Gianforcaro
344a0e00c8 Toolchain: Update GDB to version 12.1 2022-08-24 22:24:34 +00:00
Brian Gianforcaro
e9e8111f4a Toolchain: Update binutils to version 2.39 2022-08-24 22:24:34 +00:00
Brian Gianforcaro
7ac3dffe9e Toolchain: Update gcc to version 12.2.0 2022-08-24 22:24:34 +00:00
Timon Kruiper
408e2f607a Toolchain: Allow setting QEMU_{VERSION, MD5SUM} from command line
This can be used to download and build a specific QEMU version.
2022-08-17 15:44:38 +01:00
Tim Schumacher
a857b6297a Toolchain: Don't pass -lpthread when pthreads are requested
This is essentially a no-op since we have our replacement linker script,
but if we can skip over that entirely, why not?
2022-07-19 11:00:35 +01:00
Tim Schumacher
28061cf94d Everywhere: Fully remove the separate LibPthread directory 2022-07-19 11:00:35 +01:00
Tim Schumacher
2f3b9c49a5 LibPthread: Move the pthread and semaphore implementation to LibC
This additionally adds some compatibility code to redirect linking
attempts for LibPthread to LibC instead.
2022-07-19 11:00:35 +01:00
Tim Schumacher
0abc21132a Toolchain: Update mold to 1.3.1 2022-07-16 20:45:06 +01:00
Tim Schumacher
fb877effb8 Meta+Ports: Automatically generate a meson cross file that we can use 2022-07-13 21:22:52 +01:00
Andrew Kaster
010190beb8 Toolchain: Remove workarounds for initializer_list and _aligned_alloc
These are no longer required to use libc++ on Serenity
2022-06-30 12:34:16 +01:00
Andrew Kaster
efc1805b8f Toolchain: Create separate serenity xlocale support file 2022-06-30 12:34:16 +01:00
Andrew Kaster
d889294036 Toolchain: Format llvm patches per new patch format
This removes the patch series 1/N comments, git version at the bottom of
the patch, and zeros out the original commit hash.
2022-06-30 12:34:16 +01:00
Andrew Kaster
809852aeb1 Toolchain+Ports: Install host ruby into Local/ruby, not Local/$ARCH
Following the pattern for qemu, mold, and clang, we should install the
host ruby required to build the ruby port into its own install tree
rather than forcing it into the GNU compiler's bindir.
2022-06-30 12:29:18 +01:00
Andrew Kaster
dcc0f299be Toolchain+Ports: Install host python into Local/python, not Local/$ARCH
Following the pattern for qemu, mold, and clang, we should install the
host python required to build the python port into its own install tree
rather than forcing it into the GNU compiler's bindir.
2022-06-30 12:29:18 +01:00
Tim Schumacher
242bbf1be4 Toolchain: Set '/' as default division character for binutils
While we are at it, regenerate the patch and remove some outdated parts
of the description.
2022-06-30 12:27:17 +01:00
Andrew Kaster
05058d185c Toolchain: Update Platform files to match those in upstream cmake
Serenity support was merged into the CMake master branch for the 3.25.0
milestone (https://gitlab.kitware.com/cmake/cmake/-/merge_requests/6837)

Remove some settings that are now redundant from the Toolchain files.
2022-06-29 13:36:38 +01:00
Tim Schumacher
2df56f840f Revert "Toolchain: Load x64 executables at a higher address"
Now that the lower pages can be unmapped and more of the virtual
address range is available to us, we can actually use the default
mapping address of x86_64 again.

This reverts commit 292398b585.
2022-06-21 22:38:15 +01:00
kleines Filmröllchen
026cea990a Toolchain: Update mold to 1.0.3 2022-06-19 15:45:14 +01:00
Daniel Bertalan
d4d6f2d945 Toolchain: Add $arch-pc-serenity-clang symlink
This will allow us to build ports that don't allow the --target and
--sysroot compiler arguments to be specified in $CC/$CXX.
2022-06-11 22:40:23 +01:00
Daniel Bertalan
52710c2672 Toolchain: Fix shellcheck warning 2022-05-20 12:44:12 +01:00
Daniel Bertalan
d0edf2627c Toolchain+Ports: Split the GCC patches
This shouldn't cause any breaking changes, so a toolchain rebuild is not
required.

As per Hendiadyoin's request, math errno is disabled by default, which
should enable some extra compiler optimizations in LibGL and LibSoftGPU
code that uses math functions heavily.

Co-Authored-By: Ali Mohammad Pur <mpfard@serenityos.org>
2022-05-19 20:17:10 +04:30
Daniel Bertalan
6cf260c7af Toolchain: Upgrade to GCC 12.1.0
This release brings support for various C++23 constructs like `if
consteval` and multidimensional subscript operators. Vectorization is
now enabled for O2 too, and `-ftrivial-auto-var-init` has been added
which can help us find and prevent security issues coming from
uninitialized variables.

Toolchain/Patches/gcc.patch is now significanly smaller as some unused,
autoconf-generated code has been removed.
2022-05-12 13:12:37 +02:00
Lucas CHOLLET
ebb35e03be Toolchain: Allow BuildQemu.sh to resume downloads
Use -C option for curl to resume if a partially downloaded file already
exists.
2022-05-08 17:48:05 +02:00
Andrew Kaster
4334bd06b8 Toolchain: Enable LLVM Profile instrumentation
Add a patch to let llvm's InstrProfiling modules know serenity supports
all the Unix-y features required to make -fprofile-instr-generate and
-fcoverage-mapping work properly on target.
2022-05-02 01:46:18 +02:00
Andrew Kaster
29fefe2d3e Toolchain: Explicitly install llvm-config and FileCheck
Also disable the "toolchain only build" to ensure we install llvm
headers for when we want to build host tools that link against llvm.
2022-04-25 10:45:46 +02:00
EWouters
ab37791431 Toolchain: Update BuildQemu.sh to qemu-7.0
QEMU 7.0 was released on April 19th.
Release Notes: https://wiki.qemu.org/ChangeLog/7.0
2022-04-23 10:44:39 -07:00
Daniel Bertalan
01b31d9858 Toolchain+Ports: Update LLVM to 14.0.1
Besides a version bump, the following changes have been made to our
toolchain infrastructure:
- LLVM/Clang is now built with -march=native if the host compiler
  supports it. An exception to this is CI, as the toolchain cache is
  shared among many different machines there.
- The LLVM tarball is not re-extracted if the hash of the applied
  patches doesn't differ.
- The patches have been split up into atomic chunks.
- Port-specific patches have been integrated into the main patches,
  which will aid in the work towards self-hosting.
- <sysroot>/usr/local/lib is now appended to the linker's search path by
  default.
- --pack-dyn-relocs=relr is appended to the linker command line by
  default, meaning ports take advantage of RELR relocations without any
  patches or additional compiler flags.

The formatting of LLVM port's package.sh has been bothering me, so I
also indented the arguments to the CMake invocation.
2022-04-23 10:43:32 -07:00
James Mintram
81b6386c87 Toolchain: Fix the gdb build for aarch64 target on macOS host 2022-04-01 19:39:56 +01:00
James Mintram
11bcde0bbd Toolchain: Add a gcc patch to fix linker error on M1 host 2022-03-31 19:22:53 -07:00
jd
ba6ba67fa0 Toolchain: Fix serenity.nix
* x11 package name has changed to xlibsWrapper.
* texinfo is necessary for Makeinfo.
* e2fsprogs was recenty fixed on nicpkgs to include fuse2fs to mount
serenity images without root access but it needed some configuration.
2022-03-29 16:36:28 -07:00
Daniel Bertalan
5550905c00 Toolchain: Update gdb to 11.2 2022-03-24 20:08:08 -07:00
Tim Schumacher
2788d46ae0 Toolchain: Make wint_t unsigned for Clang 2022-03-19 00:11:45 +00:00
Tim Schumacher
5d0869d5ca Toolchain: Enable IFUNC support for GCC 2022-03-19 00:11:45 +00:00
Tim Schumacher
b55a3a504e Toolchain: Enforce correct sizes for size_t and ptrdiff_t 2022-03-19 00:11:45 +00:00
Jonathan Marler
97c0a8c063 Toolchain: Move nix script from Documentation into Toolchain
Moves the nix script to setup the build environment from Documentation
into the Toolchain as a callable script.  I also modified the script
to accept a "pkgs" argument to make it easy to override the nixpkgs
version from the command-line when calling the script.
2022-03-08 23:31:45 +01:00