mirror of
https://github.com/chromebrew/chromebrew.git
synced 2026-01-10 07:57:59 -05:00
* Add LLVM 20 builds, Mold 2.37.1, and add rebuilds. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Update wayland_protocols. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Add more llvm20 updates. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * More LLVM 20 updates. Signed-off-by: Satadru Pramanik <satadru@gmail.com> --------- Signed-off-by: Satadru Pramanik <satadru@gmail.com> Co-authored-by: Satadru Pramanik <satadru@gmail.com> Co-authored-by: Ed Reel <edreel@gmail.com>
51 lines
1.6 KiB
Ruby
51 lines
1.6 KiB
Ruby
# Adapted from Arch Linux mold PKGBUILD at:
|
|
# https://github.com/archlinux/svntogit-community/raw/packages/mold/trunk/PKGBUILD
|
|
|
|
require 'buildsystems/cmake'
|
|
|
|
class Mold < CMake
|
|
description 'A Modern Linker'
|
|
homepage 'https://github.com/rui314/mold'
|
|
version '2.37.1'
|
|
license 'MIT'
|
|
compatibility 'all'
|
|
source_url 'https://github.com/rui314/mold.git'
|
|
git_hashtag "v#{version}"
|
|
binary_compression 'tar.zst'
|
|
|
|
binary_sha256({
|
|
aarch64: 'b6407f2120728eb1d34462d63f6adf1d13551e8618b300f359011878657bbc41',
|
|
armv7l: 'b6407f2120728eb1d34462d63f6adf1d13551e8618b300f359011878657bbc41',
|
|
i686: 'd5344a4205722043234fab04b186e1a69cd37e2b0d7d8effea3c7356ddace70b',
|
|
x86_64: '8601323798df48bcbb5e09366a2190c06a5d982bb423daaa6ab8badf138f7994'
|
|
})
|
|
|
|
depends_on 'gcc_lib' # R
|
|
depends_on 'glibc' # R
|
|
depends_on 'openssl' # R
|
|
depends_on 'xxhash' => :build
|
|
depends_on 'zlib' # R
|
|
depends_on 'zstd' # R
|
|
|
|
no_env_options
|
|
print_source_bashrc
|
|
|
|
cmake_options "-DBUILD_TESTING=OFF \
|
|
-DMOLD_LTO=ON \
|
|
-DMOLD_USE_MOLD=ON \
|
|
-DTBB_WARNING_LEVEL='-Wno-error=stringop-overflow'"
|
|
|
|
def self.install
|
|
system "DESTDIR=#{CREW_DEST_DIR} #{CREW_NINJA} -C builddir install"
|
|
File.write 'moldenv', <<~MOLD_ENV_EOF
|
|
# See https://github.com/rui314/mold/commit/36fc0655489eb96e1be15b03b3f5e227cd97a22e
|
|
if [[ $(free | head -n 2 | tail -n 1 | awk '{print $4}') -gt '4096000' ]]; then
|
|
unset MOLD_JOBS
|
|
else
|
|
MOLD_JOBS=1
|
|
fi
|
|
MOLD_ENV_EOF
|
|
FileUtils.install 'moldenv', "#{CREW_DEST_PREFIX}/etc/env.d/mold", mode: 0o644
|
|
end
|
|
end
|