compiler rework (#8391)

* initial llvm16 rework

* update openmp

* start i686 builds

* fix getrealdeps grep with multiple exclusions

* fix crew conflicts handling _build packages, fix getrealdeps handling _build packages

* add more libs to gcc_lib

* update libssp

* add armv7 builds

* add builds

* suggested changes

* update rubocop
This commit is contained in:
Satadru Pramanik, DO, MPH, MEng
2023-06-15 11:22:41 -04:00
committed by GitHub
parent a4e35d3ea2
commit e91463ec30
55 changed files with 5852 additions and 1461 deletions

View File

@@ -1071,14 +1071,14 @@ def determine_conflicts(dir, pkg)
conflicts = []
if File.file?("#{dir}/filelist")
if File.file?("#{CREW_META_PATH}#{pkg}.filelist")
puts 'Checking for conflicts with files from installed packages...'
conflictscmd = `grep --exclude #{CREW_META_PATH}#{pkg}.filelist --exclude #{CREW_META_PATH}*_build.filelist -Fxf #{dir}/filelist #{CREW_META_PATH}*.filelist`
puts 'Checking for conflicts with files from installed packages...'.orange
conflictscmd = `grep --exclude=#{CREW_META_PATH}#{pkg}.filelist --exclude=#{CREW_META_PATH}\\\*_build.filelist -Fxf #{dir}/filelist #{CREW_META_PATH}*.filelist`
conflicts = conflictscmd.gsub(/(\.filelist|#{CREW_META_PATH})/, '').split("\n")
conflicts.reject!(&:empty?)
end
elsif File.file?("#{CREW_META_PATH}#{pkg}.filelist")
puts "Checking for conflicts of #{pkg} with files from installed packages...".orange
conflictscmd = `grep --exclude #{CREW_META_PATH}#{pkg}.filelist --exclude #{CREW_META_PATH}*_build.filelist -Fxf #{CREW_META_PATH}#{pkg}.filelist #{CREW_META_PATH}*.filelist`
conflictscmd = `grep --exclude=#{CREW_META_PATH}#{pkg}.filelist --exclude=#{CREW_META_PATH}\\\*_build.filelist -Fxf #{CREW_META_PATH}#{pkg}.filelist #{CREW_META_PATH}*.filelist`
conflicts = conflictscmd.gsub(/(\.filelist|#{CREW_META_PATH})/, '').split("\n")
conflicts.reject!(&:empty?)
end

View File

@@ -1,6 +1,6 @@
# Defines common constants used in different parts of crew
CREW_VERSION = '1.34.3'
CREW_VERSION = '1.34.4'
# kernel architecture
KERN_ARCH = `uname -m`.chomp

File diff suppressed because it is too large Load Diff

View File

@@ -1,2 +1,38 @@
/usr/local/lib/bfd-plugins/liblto_plugin.so
/usr/local/libexec/gcc/armv7l-cros-linux-gnueabihf/13/liblto_plugin.so
/usr/local/lib/gcc/armv7l-cros-linux-gnueabihf/13/plugin/libcc1plugin.so
/usr/local/lib/gcc/armv7l-cros-linux-gnueabihf/13/plugin/libcc1plugin.so.0
/usr/local/lib/gcc/armv7l-cros-linux-gnueabihf/13/plugin/libcc1plugin.so.0.0.0
/usr/local/lib/gcc/armv7l-cros-linux-gnueabihf/13/plugin/libcp1plugin.so
/usr/local/lib/gcc/armv7l-cros-linux-gnueabihf/13/plugin/libcp1plugin.so.0
/usr/local/lib/gcc/armv7l-cros-linux-gnueabihf/13/plugin/libcp1plugin.so.0.0.0
/usr/local/lib/libasan.so
/usr/local/lib/libasan.so.8
/usr/local/lib/libasan.so.8.0.0
/usr/local/lib/libatomic.so
/usr/local/lib/libatomic.so.1
/usr/local/lib/libatomic.so.1.2.0
/usr/local/lib/libcc1.so
/usr/local/lib/libcc1.so.0
/usr/local/lib/libcc1.so.0.0.0
/usr/local/lib/libgcc_s.so
/usr/local/lib/libgcc_s.so.1
/usr/local/lib/libgfortran.so
/usr/local/lib/libgfortran.so.5
/usr/local/lib/libgfortran.so.5.0.0
/usr/local/lib/libgomp.so
/usr/local/lib/libgomp.so.1
/usr/local/lib/libgomp.so.1.0.0
/usr/local/lib/libitm.so
/usr/local/lib/libitm.so.1
/usr/local/lib/libitm.so.1.0.0
/usr/local/lib/libobjc.so
/usr/local/lib/libobjc.so.4
/usr/local/lib/libobjc.so.4.0.0
/usr/local/lib/libstdc++.so
/usr/local/lib/libstdc++.so.6
/usr/local/lib/libstdc++.so.6.0.31
/usr/local/lib/libubsan.so
/usr/local/lib/libubsan.so.1
/usr/local/lib/libubsan.so.1.0.0
/usr/local/share/gdb/auto-load/usr/lib/libstdc++.so.6.0.31-gdb.py

View File

@@ -1,7 +1,7 @@
/usr/local/lib/gcc/armv7l-cros-linux-gnueabihf/12/include/ssp/ssp.h
/usr/local/lib/gcc/armv7l-cros-linux-gnueabihf/12/include/ssp/stdio.h
/usr/local/lib/gcc/armv7l-cros-linux-gnueabihf/12/include/ssp/string.h
/usr/local/lib/gcc/armv7l-cros-linux-gnueabihf/12/include/ssp/unistd.h
/usr/local/lib/gcc/armv7l-cros-linux-gnueabihf/13/include/ssp/ssp.h
/usr/local/lib/gcc/armv7l-cros-linux-gnueabihf/13/include/ssp/stdio.h
/usr/local/lib/gcc/armv7l-cros-linux-gnueabihf/13/include/ssp/string.h
/usr/local/lib/gcc/armv7l-cros-linux-gnueabihf/13/include/ssp/unistd.h
/usr/local/lib/libssp.a
/usr/local/lib/libssp.la
/usr/local/lib/libssp_nonshared.a

View File

@@ -4058,7 +4058,7 @@
/usr/local/lib/libclangSerialization.a
/usr/local/lib/libclang.so
/usr/local/lib/libclang.so.16
/usr/local/lib/libclang.so.16.0.5
/usr/local/lib/libclang.so.16.0.6
/usr/local/lib/libclangStaticAnalyzerCheckers.a
/usr/local/lib/libclangStaticAnalyzerCore.a
/usr/local/lib/libclangStaticAnalyzerFrontend.a
@@ -4107,14 +4107,14 @@
/usr/local/lib/liblldbIntelFeatures.so.16
/usr/local/lib/liblldb.so
/usr/local/lib/liblldb.so.16
/usr/local/lib/liblldb.so.16.0.5
/usr/local/lib/liblldb.so.16.0.6
/usr/local/lib/liblldCOFF.a
/usr/local/lib/liblldCommon.a
/usr/local/lib/liblldELF.a
/usr/local/lib/liblldMachO.a
/usr/local/lib/liblldMinGW.a
/usr/local/lib/liblldWasm.a
/usr/local/lib/libLLVM-16.0.5.so
/usr/local/lib/libLLVM-16.0.6.so
/usr/local/lib/libLLVM-16.so
/usr/local/lib/libLLVMAArch64AsmParser.a
/usr/local/lib/libLLVMAArch64CodeGen.a

View File

@@ -4057,7 +4057,7 @@
/usr/local/lib/libclangSerialization.a
/usr/local/lib/libclang.so
/usr/local/lib/libclang.so.16
/usr/local/lib/libclang.so.16.0.5
/usr/local/lib/libclang.so.16.0.6
/usr/local/lib/libclangStaticAnalyzerCheckers.a
/usr/local/lib/libclangStaticAnalyzerCore.a
/usr/local/lib/libclangStaticAnalyzerFrontend.a
@@ -4106,7 +4106,7 @@
/usr/local/lib/liblldbIntelFeatures.so.16
/usr/local/lib/liblldb.so
/usr/local/lib/liblldb.so.16
/usr/local/lib/liblldb.so.16.0.5
/usr/local/lib/liblldb.so.16.0.6
/usr/local/lib/liblldCOFF.a
/usr/local/lib/liblldCommon.a
/usr/local/lib/liblldELF.a

View File

@@ -1,4 +1,4 @@
/usr/local/bin/llvm-strip
/usr/local/lib/libLLVM-16.0.5.so
/usr/local/lib/libLLVM-16.0.6.so
/usr/local/lib/libLLVM-16.so
/usr/local/lib/libLLVM.so

File diff suppressed because it is too large Load Diff

View File

@@ -1,2 +1,41 @@
/usr/local/lib/bfd-plugins/liblto_plugin.so
/usr/local/libexec/gcc/i686-cros-linux-gnu/13/liblto_plugin.so
/usr/local/lib/gcc/i686-cros-linux-gnu/13/plugin/libcc1plugin.so
/usr/local/lib/gcc/i686-cros-linux-gnu/13/plugin/libcc1plugin.so.0
/usr/local/lib/gcc/i686-cros-linux-gnu/13/plugin/libcc1plugin.so.0.0.0
/usr/local/lib/gcc/i686-cros-linux-gnu/13/plugin/libcp1plugin.so
/usr/local/lib/gcc/i686-cros-linux-gnu/13/plugin/libcp1plugin.so.0
/usr/local/lib/gcc/i686-cros-linux-gnu/13/plugin/libcp1plugin.so.0.0.0
/usr/local/lib/libasan.so
/usr/local/lib/libasan.so.8
/usr/local/lib/libasan.so.8.0.0
/usr/local/lib/libatomic.so
/usr/local/lib/libatomic.so.1
/usr/local/lib/libatomic.so.1.2.0
/usr/local/lib/libcc1.so
/usr/local/lib/libcc1.so.0
/usr/local/lib/libcc1.so.0.0.0
/usr/local/lib/libgcc_s.so
/usr/local/lib/libgcc_s.so.1
/usr/local/lib/libgfortran.so
/usr/local/lib/libgfortran.so.5
/usr/local/lib/libgfortran.so.5.0.0
/usr/local/lib/libgomp.so
/usr/local/lib/libgomp.so.1
/usr/local/lib/libgomp.so.1.0.0
/usr/local/lib/libitm.so
/usr/local/lib/libitm.so.1
/usr/local/lib/libitm.so.1.0.0
/usr/local/lib/libobjc.so
/usr/local/lib/libobjc.so.4
/usr/local/lib/libobjc.so.4.0.0
/usr/local/lib/libquadmath.so
/usr/local/lib/libquadmath.so.0
/usr/local/lib/libquadmath.so.0.0.0
/usr/local/lib/libstdc++.so
/usr/local/lib/libstdc++.so.6
/usr/local/lib/libstdc++.so.6.0.31
/usr/local/lib/libubsan.so
/usr/local/lib/libubsan.so.1
/usr/local/lib/libubsan.so.1.0.0
/usr/local/share/gdb/auto-load/usr/lib/libstdc++.so.6.0.31-gdb.py

View File

@@ -1,7 +1,7 @@
/usr/local/lib/gcc/i686-cros-linux-gnu/12/include/ssp/ssp.h
/usr/local/lib/gcc/i686-cros-linux-gnu/12/include/ssp/stdio.h
/usr/local/lib/gcc/i686-cros-linux-gnu/12/include/ssp/string.h
/usr/local/lib/gcc/i686-cros-linux-gnu/12/include/ssp/unistd.h
/usr/local/lib/gcc/i686-cros-linux-gnu/13/include/ssp/ssp.h
/usr/local/lib/gcc/i686-cros-linux-gnu/13/include/ssp/stdio.h
/usr/local/lib/gcc/i686-cros-linux-gnu/13/include/ssp/string.h
/usr/local/lib/gcc/i686-cros-linux-gnu/13/include/ssp/unistd.h
/usr/local/lib/libssp.a
/usr/local/lib/libssp.la
/usr/local/lib/libssp_nonshared.a

View File

@@ -4053,7 +4053,7 @@
/usr/local/lib/libclangSerialization.a
/usr/local/lib/libclang.so
/usr/local/lib/libclang.so.16
/usr/local/lib/libclang.so.16.0.5
/usr/local/lib/libclang.so.16.0.6
/usr/local/lib/libclangStaticAnalyzerCheckers.a
/usr/local/lib/libclangStaticAnalyzerCore.a
/usr/local/lib/libclangStaticAnalyzerFrontend.a
@@ -4102,14 +4102,14 @@
/usr/local/lib/liblldbIntelFeatures.so.16
/usr/local/lib/liblldb.so
/usr/local/lib/liblldb.so.16
/usr/local/lib/liblldb.so.16.0.5
/usr/local/lib/liblldb.so.16.0.6
/usr/local/lib/liblldCOFF.a
/usr/local/lib/liblldCommon.a
/usr/local/lib/liblldELF.a
/usr/local/lib/liblldMachO.a
/usr/local/lib/liblldMinGW.a
/usr/local/lib/liblldWasm.a
/usr/local/lib/libLLVM-16.0.5.so
/usr/local/lib/libLLVM-16.0.6.so
/usr/local/lib/libLLVM-16.so
/usr/local/lib/libLLVMAArch64AsmParser.a
/usr/local/lib/libLLVMAArch64CodeGen.a

File diff suppressed because it is too large Load Diff

View File

@@ -1,4 +1,4 @@
/usr/local/bin/llvm-strip
/usr/local/lib/libLLVM-16.0.5.so
/usr/local/lib/libLLVM-16.0.6.so
/usr/local/lib/libLLVM-16.so
/usr/local/lib/libLLVM.so

File diff suppressed because it is too large Load Diff

View File

@@ -1,2 +1,51 @@
/usr/local/lib64/bfd-plugins/liblto_plugin.so
/usr/local/lib64/gcc/x86_64-cros-linux-gnu/13/plugin/libcc1plugin.so
/usr/local/lib64/gcc/x86_64-cros-linux-gnu/13/plugin/libcc1plugin.so.0
/usr/local/lib64/gcc/x86_64-cros-linux-gnu/13/plugin/libcc1plugin.so.0.0.0
/usr/local/lib64/gcc/x86_64-cros-linux-gnu/13/plugin/libcp1plugin.so
/usr/local/lib64/gcc/x86_64-cros-linux-gnu/13/plugin/libcp1plugin.so.0
/usr/local/lib64/gcc/x86_64-cros-linux-gnu/13/plugin/libcp1plugin.so.0.0.0
/usr/local/lib64/libasan.so
/usr/local/lib64/libasan.so.8
/usr/local/lib64/libasan.so.8.0.0
/usr/local/lib64/libatomic.so
/usr/local/lib64/libatomic.so.1
/usr/local/lib64/libatomic.so.1.2.0
/usr/local/lib64/libcc1.so
/usr/local/lib64/libcc1.so.0
/usr/local/lib64/libcc1.so.0.0.0
/usr/local/lib64/libgcc_s.so
/usr/local/lib64/libgcc_s.so.1
/usr/local/lib64/libgfortran.so
/usr/local/lib64/libgfortran.so.5
/usr/local/lib64/libgfortran.so.5.0.0
/usr/local/lib64/libgomp.so
/usr/local/lib64/libgomp.so.1
/usr/local/lib64/libgomp.so.1.0.0
/usr/local/lib64/libhwasan.so
/usr/local/lib64/libhwasan.so.0
/usr/local/lib64/libhwasan.so.0.0.0
/usr/local/lib64/libitm.so
/usr/local/lib64/libitm.so.1
/usr/local/lib64/libitm.so.1.0.0
/usr/local/lib64/liblsan.so
/usr/local/lib64/liblsan.so.0
/usr/local/lib64/liblsan.so.0.0.0
/usr/local/lib64/libobjc.so
/usr/local/lib64/libobjc.so.4
/usr/local/lib64/libobjc.so.4.0.0
/usr/local/lib64/libquadmath.so
/usr/local/lib64/libquadmath.so.0
/usr/local/lib64/libquadmath.so.0.0.0
/usr/local/lib64/libstdc++.so
/usr/local/lib64/libstdc++.so.6
/usr/local/lib64/libstdc++.so.6.0.31
/usr/local/lib64/libtsan.so
/usr/local/lib64/libtsan.so.2
/usr/local/lib64/libtsan.so.2.0.0
/usr/local/lib64/libubsan.so
/usr/local/lib64/libubsan.so.1
/usr/local/lib64/libubsan.so.1.0.0
/usr/local/lib/bfd-plugins/liblto_plugin.so
/usr/local/libexec/gcc/x86_64-cros-linux-gnu/13/liblto_plugin.so
/usr/local/share/gdb/auto-load/usr/lib/libstdc++.so.6.0.31-gdb.py

View File

@@ -1,7 +1,7 @@
/usr/local/lib64/gcc/x86_64-cros-linux-gnu/12/include/ssp/ssp.h
/usr/local/lib64/gcc/x86_64-cros-linux-gnu/12/include/ssp/stdio.h
/usr/local/lib64/gcc/x86_64-cros-linux-gnu/12/include/ssp/string.h
/usr/local/lib64/gcc/x86_64-cros-linux-gnu/12/include/ssp/unistd.h
/usr/local/lib64/gcc/x86_64-cros-linux-gnu/13/include/ssp/ssp.h
/usr/local/lib64/gcc/x86_64-cros-linux-gnu/13/include/ssp/stdio.h
/usr/local/lib64/gcc/x86_64-cros-linux-gnu/13/include/ssp/string.h
/usr/local/lib64/gcc/x86_64-cros-linux-gnu/13/include/ssp/unistd.h
/usr/local/lib64/libssp.a
/usr/local/lib64/libssp.la
/usr/local/lib64/libssp_nonshared.a

View File

@@ -70,6 +70,7 @@
/usr/local/bin/llvm-debuginfod-find
/usr/local/bin/llvm-diff
/usr/local/bin/llvm-dis
/usr/local/bin/llvm-dlltool
/usr/local/bin/llvm-dwarfdump
/usr/local/bin/llvm-dwarfutil
/usr/local/bin/llvm-dwp
@@ -4054,7 +4055,7 @@
/usr/local/lib64/libclangSerialization.a
/usr/local/lib64/libclang.so
/usr/local/lib64/libclang.so.16
/usr/local/lib64/libclang.so.16.0.5
/usr/local/lib64/libclang.so.16.0.6
/usr/local/lib64/libclangStaticAnalyzerCheckers.a
/usr/local/lib64/libclangStaticAnalyzerCore.a
/usr/local/lib64/libclangStaticAnalyzerFrontend.a
@@ -4103,14 +4104,14 @@
/usr/local/lib64/liblldbIntelFeatures.so.16
/usr/local/lib64/liblldb.so
/usr/local/lib64/liblldb.so.16
/usr/local/lib64/liblldb.so.16.0.5
/usr/local/lib64/liblldb.so.16.0.6
/usr/local/lib64/liblldCOFF.a
/usr/local/lib64/liblldCommon.a
/usr/local/lib64/liblldELF.a
/usr/local/lib64/liblldMachO.a
/usr/local/lib64/liblldMinGW.a
/usr/local/lib64/liblldWasm.a
/usr/local/lib64/libLLVM-16.0.5.so
/usr/local/lib64/libLLVM-16.0.6.so
/usr/local/lib64/libLLVM-16.so
/usr/local/lib64/libLLVMAArch64AsmParser.a
/usr/local/lib64/libLLVMAArch64CodeGen.a

View File

@@ -70,6 +70,7 @@
/usr/local/bin/llvm-debuginfod-find
/usr/local/bin/llvm-diff
/usr/local/bin/llvm-dis
/usr/local/bin/llvm-dlltool
/usr/local/bin/llvm-dwarfdump
/usr/local/bin/llvm-dwarfutil
/usr/local/bin/llvm-dwp
@@ -4053,7 +4054,7 @@
/usr/local/lib64/libclangSerialization.a
/usr/local/lib64/libclang.so
/usr/local/lib64/libclang.so.16
/usr/local/lib64/libclang.so.16.0.5
/usr/local/lib64/libclang.so.16.0.6
/usr/local/lib64/libclangStaticAnalyzerCheckers.a
/usr/local/lib64/libclangStaticAnalyzerCore.a
/usr/local/lib64/libclangStaticAnalyzerFrontend.a
@@ -4102,7 +4103,7 @@
/usr/local/lib64/liblldbIntelFeatures.so.16
/usr/local/lib64/liblldb.so
/usr/local/lib64/liblldb.so.16
/usr/local/lib64/liblldb.so.16.0.5
/usr/local/lib64/liblldb.so.16.0.6
/usr/local/lib64/liblldCOFF.a
/usr/local/lib64/liblldCommon.a
/usr/local/lib64/liblldELF.a

View File

@@ -1,4 +1,4 @@
/usr/local/bin/llvm-strip
/usr/local/lib64/libLLVM-16.0.5.so
/usr/local/lib64/libLLVM-16.0.6.so
/usr/local/lib64/libLLVM-16.so
/usr/local/lib64/libLLVM.so

View File

@@ -25,7 +25,7 @@ class Amtk < Package
depends_on 'gtk3'
depends_on 'gobject_introspection' => :build
depends_on 'gtk_doc' => :build
depends_on 'llvm_lib16' => :build
depends_on 'llvm16_lib' => :build
def self.build
system "meson setup #{CREW_MESON_FNO_LTO_OPTIONS} \

View File

@@ -96,8 +96,8 @@ class Buildessential < Package
# LLVM
# This can be pulled in on a per-package basis...
# depends_on 'llvm_dev16'
depends_on 'llvm_lib16' # This provides llvm-strip
# depends_on 'llvm16_dev'
depends_on 'llvm16_lib' # This provides llvm-strip
# Meson build system
depends_on 'meson'

View File

@@ -32,7 +32,7 @@ class Cmake < Package
depends_on 'libnghttp2'
depends_on 'librhash'
depends_on 'libuv'
depends_on 'llvm_lib16' => :build
depends_on 'llvm16_lib' => :build
depends_on 'ncurses' # R
depends_on 'xzutils'
depends_on 'zlibpkg'

View File

@@ -28,7 +28,7 @@ class Cras < Package
depends_on 'gtest' => :build
depends_on 'iniparser' # R
depends_on 'ladspa'
depends_on 'llvm_dev16' => :build
depends_on 'llvm16_dev' => :build
depends_on 'rust' => :build
depends_on 'sbc' # R
depends_on 'speexdsp' # R

View File

@@ -9,7 +9,7 @@ class Crew_launcher < Package
source_url 'https://github.com/chromebrew/crew-launcher.git'
git_hashtag '1.1'
depends_on 'llvm_lib16'
depends_on 'llvm16_lib'
depends_on 'graphicsmagick'
def self.install

View File

@@ -9,7 +9,7 @@ class Crystal < Package
source_url 'https://github.com/crystal-lang/crystal/releases/download/1.6.0/crystal-1.6.0-1-linux-x86_64-bundled.tar.gz'
source_sha256 '5b1b287563839c3c9a2fa7b620c48b5c56de0756464e8370f3a7f720a3ba4df0'
depends_on 'llvm_lib16' # R
depends_on 'llvm16_lib' # R
def self.install
FileUtils.mkdir_p CREW_DEST_PREFIX.to_s

View File

@@ -2,26 +2,26 @@ require 'package'
require_relative 'gcc_build'
class Gcc_dev < Package
description 'The GNU Compiler Collection: Everything except libgcc'
description 'The GNU Compiler Collection: Everything (excepting libraries aside from libgccjit)'
homepage Gcc_build.homepage
version '13.1.0' # Do not use @_ver here, it will break the installer.
version '13.1.0-1' # Do not use @_ver here, it will break the installer.
license Gcc_build.license
# When upgrading gcc_build, be sure to upgrade gcc_lib and gcc_dev in tandem.
puts "#{self} version differs from gcc version #{Gcc_build.version}".orange if version != Gcc_build.version.to_s
# When upgrading gcc_build, be sure to upgrade gcc_lib, gcc_dev, and libssp in tandem.
puts "#{self} version differs from gcc version #{Gcc_build.version}".orange if version.to_s.gsub(/-.*/, '') != Gcc_build.version.to_s
compatibility 'all'
source_url 'SKIP'
binary_url({
aarch64: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/gcc_dev/13.1.0_armv7l/gcc_dev-13.1.0-chromeos-armv7l.tar.zst',
armv7l: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/gcc_dev/13.1.0_armv7l/gcc_dev-13.1.0-chromeos-armv7l.tar.zst',
i686: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/gcc_dev/13.1.0_i686/gcc_dev-13.1.0-chromeos-i686.tar.zst',
x86_64: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/gcc_dev/13.1.0_x86_64/gcc_dev-13.1.0-chromeos-x86_64.tar.zst'
aarch64: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/gcc_dev/13.1.0-1_armv7l/gcc_dev-13.1.0-1-chromeos-armv7l.tar.zst',
armv7l: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/gcc_dev/13.1.0-1_armv7l/gcc_dev-13.1.0-1-chromeos-armv7l.tar.zst',
i686: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/gcc_dev/13.1.0-1_i686/gcc_dev-13.1.0-1-chromeos-i686.tar.zst',
x86_64: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/gcc_dev/13.1.0-1_x86_64/gcc_dev-13.1.0-1-chromeos-x86_64.tar.zst'
})
binary_sha256({
aarch64: '12169c998f12d1117a90252ebdf49f3139d1a22c58474db202a86f24060d285b',
armv7l: '12169c998f12d1117a90252ebdf49f3139d1a22c58474db202a86f24060d285b',
i686: '072646bcb2d26baed67c80357367cadb30aef30523b6b39c2984cdf4761c0a86',
x86_64: 'c9eb15813b74fa9393da20d38b30aab61c14079adb052e4cc7e98e73fa61a04a'
aarch64: 'ec00172ae8c82f8288f612eb3f904b69f8336aa3c9a624a78e103926e1cfea91',
armv7l: 'ec00172ae8c82f8288f612eb3f904b69f8336aa3c9a624a78e103926e1cfea91',
i686: '44f3bb02fc9c390159be9c0524d93e980eddc97a3e9793ee57a0dc7c1545f61e',
x86_64: '9a9e860071fef3fade59033428e54fec7c469d8094fb5dacc738d80045304f12'
})
depends_on 'gcc_build' => :build
@@ -42,7 +42,7 @@ class Gcc_dev < Package
@filelist = File.readlines(@filelist_path, chomp: true).sort
@filelist.each do |filename|
next if filename.include?('.so') && filename.include?('libgcc_s')
next if filename.include?('.so') && !filename.include?('libgccjit')
@destpath = "#{CREW_DEST_DIR.chomp('/')}#{filename}"
@filename_target = File.realpath(filename)

View File

@@ -2,26 +2,26 @@ require 'package'
require_relative 'gcc_build'
class Gcc_lib < Package
description 'Libgcc'
description 'GCC shared libs except libgccjit'
homepage Gcc_build.homepage
version '13.1.0' # Do not use @_ver here, it will break the installer.
version '13.1.0-1' # Do not use @_ver here, it will break the installer.
license Gcc_build.license
# When upgrading gcc_build, be sure to upgrade gcc_lib and gcc_dev in tandem.
puts "#{self} version differs from gcc version #{Gcc_build.version}".orange if version != Gcc_build.version.to_s
# When upgrading gcc_build, be sure to upgrade gcc_lib, gcc_dev, and libssp in tandem.
puts "#{self} version differs from gcc version #{Gcc_build.version}".orange if version.to_s.gsub(/-.*/, '') != Gcc_build.version.to_s
compatibility 'all'
source_url 'SKIP'
binary_url({
aarch64: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/gcc_lib/13.1.0_armv7l/gcc_lib-13.1.0-chromeos-armv7l.tar.zst',
armv7l: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/gcc_lib/13.1.0_armv7l/gcc_lib-13.1.0-chromeos-armv7l.tar.zst',
i686: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/gcc_lib/13.1.0_i686/gcc_lib-13.1.0-chromeos-i686.tar.zst',
x86_64: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/gcc_lib/13.1.0_x86_64/gcc_lib-13.1.0-chromeos-x86_64.tar.zst'
aarch64: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/gcc_lib/13.1.0-1_armv7l/gcc_lib-13.1.0-1-chromeos-armv7l.tar.zst',
armv7l: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/gcc_lib/13.1.0-1_armv7l/gcc_lib-13.1.0-1-chromeos-armv7l.tar.zst',
i686: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/gcc_lib/13.1.0-1_i686/gcc_lib-13.1.0-1-chromeos-i686.tar.zst',
x86_64: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/gcc_lib/13.1.0-1_x86_64/gcc_lib-13.1.0-1-chromeos-x86_64.tar.zst'
})
binary_sha256({
aarch64: '43e835c2e924a80bf0fd87a853a3f5692e3db97e6368a820f08da6065086e540',
armv7l: '43e835c2e924a80bf0fd87a853a3f5692e3db97e6368a820f08da6065086e540',
i686: '563c75cd3dba893bf6231f84e328fe368ec4307b599ad6bff72a8d34cd2e9251',
x86_64: '98e1240095dd7dbfb3539f5c6d1450cb01a9674733b7490a5f32eff9c8458d86'
aarch64: '3c5c72d2955468c9aa44014ad3a880a3c988f5e9da174225634965fdae1a26c5',
armv7l: '3c5c72d2955468c9aa44014ad3a880a3c988f5e9da174225634965fdae1a26c5',
i686: '395ef2e6e37c5d3e2745d83f9c7aadc90cb11387a0099578ab98f6265d90c791',
x86_64: '30fc5cd851e8785798dc5ddaf1f0fdd905e0f1abd0d3dd581cf0b12770c591e6'
})
depends_on 'gcc_build' => :build
@@ -34,7 +34,7 @@ class Gcc_lib < Package
@filelist = File.readlines(@filelist_path, chomp: true).sort
@filelist.each do |filename|
next unless filename.include?('.so') && filename.include?('libgcc_s')
next unless filename.include?('.so') && !filename.include?('libgccjit')
@destpath = "#{CREW_DEST_DIR.chomp('/')}#{filename}"
@filename_target = File.realpath(filename)

View File

@@ -36,7 +36,7 @@ class Gspell < Package
depends_on 'icu4c' # R
depends_on 'iso_codes' => :build
depends_on 'libxml2' => :build
depends_on 'llvm_lib16' => :build
depends_on 'llvm16_lib' => :build
depends_on 'ncurses' # R
depends_on 'pango' # R
depends_on 'vala' => :build

View File

@@ -35,7 +35,7 @@ class Icecream < Package
depends_on 'libarchive' # R
depends_on 'libcap_ng' # R
depends_on 'libxml2' # R
depends_on 'llvm_lib16' => :build
depends_on 'llvm16_lib' => :build
depends_on 'lz4' # R
depends_on 'lzo' # R
depends_on 'openssl' # R

View File

@@ -59,7 +59,7 @@ class Inkscape < Package
depends_on 'libxext' # R
depends_on 'libxml2' # R
depends_on 'libxslt' # R
depends_on 'llvm_lib16' => :build
depends_on 'llvm16_lib' => :build
depends_on 'pangomm_1_4' # R
depends_on 'pango' # R
depends_on 'poppler' # R

View File

@@ -27,7 +27,7 @@ class Js102 < Package
depends_on 'glibc' # R
depends_on 'icu4c' # R
depends_on 'libnotify' => :build
depends_on 'llvm_dev16' => :build
depends_on 'llvm16_dev' => :build
depends_on 'ncurses' # R
depends_on 'nspr'
depends_on 'nss' # R

View File

@@ -24,7 +24,7 @@ class Js78 < Package
depends_on 'autoconf213' => :build
depends_on 'rust' => :build
depends_on 'llvm_dev16' => :build
depends_on 'llvm16_dev' => :build
depends_on 'nspr'
@rust_default_host = case ARCH

View File

@@ -24,7 +24,7 @@ class Js91 < Package
depends_on 'autoconf213' => :build
depends_on 'rust' => :build
depends_on 'llvm_dev16' => :build
depends_on 'llvm16_dev' => :build
depends_on 'nspr'
@rust_default_host = case ARCH

View File

@@ -8,7 +8,7 @@ class Ld_default < Package
compatibility 'all'
source_url 'SKIP'
depends_on 'llvm_dev16'
depends_on 'llvm16_dev'
def self.build
system "cat << 'EOF' > ld_default

View File

@@ -22,7 +22,7 @@ class Libgnome_keyring < Package
depends_on 'dbus'
depends_on 'libgcrypt'
depends_on 'llvm_lib16' => :build
depends_on 'llvm16_lib' => :build
def self.build
system "./configure #{CREW_OPTIONS} --enable-introspection=no --enable-vala=no"

View File

@@ -1,33 +1,34 @@
require 'package'
require_relative 'gcc_build'
class Libssp < Package
description 'Libssp is a part of the GCC toolkit.'
homepage 'https://gcc.gnu.org/'
version '12.2.1-b80a690'
version '13.1.0'
license 'GPL-3, LGPL-3, libgcc, FDL-1.2'
# When upgrading gcc_build, be sure to upgrade gcc_lib, gcc_dev, and libssp in tandem.
puts "#{self} version differs from gcc version #{Gcc_build.version}".orange if version.to_s.gsub(/-.*/, '') != Gcc_build.version.to_s
compatibility 'all'
source_url 'https://github.com/gcc-mirror/gcc.git'
git_hashtag 'b80a690673272919896ee5939250e50d882f2418'
git_hashtag "releases/gcc-#{version}"
binary_url({
aarch64: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/libssp/12.2.1-b80a690_armv7l/libssp-12.2.1-b80a690-chromeos-armv7l.tar.zst',
armv7l: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/libssp/12.2.1-b80a690_armv7l/libssp-12.2.1-b80a690-chromeos-armv7l.tar.zst',
i686: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/libssp/12.2.1-b80a690_i686/libssp-12.2.1-b80a690-chromeos-i686.tar.zst',
x86_64: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/libssp/12.2.1-b80a690_x86_64/libssp-12.2.1-b80a690-chromeos-x86_64.tar.zst'
aarch64: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/libssp/13.1.0_armv7l/libssp-13.1.0-chromeos-armv7l.tar.zst',
armv7l: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/libssp/13.1.0_armv7l/libssp-13.1.0-chromeos-armv7l.tar.zst',
i686: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/libssp/13.1.0_i686/libssp-13.1.0-chromeos-i686.tar.zst',
x86_64: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/libssp/13.1.0_x86_64/libssp-13.1.0-chromeos-x86_64.tar.zst'
})
binary_sha256({
aarch64: '3776481deeb8dde51144ddf76be645b6a5935d0fc8b8ed72a4371887eb54c78b',
armv7l: '3776481deeb8dde51144ddf76be645b6a5935d0fc8b8ed72a4371887eb54c78b',
i686: '1031c6b3d3b917c59674fcfb89d36e800d4e4671dfed387b930992cf0ad53484',
x86_64: 'f9889ae9a6f85730a203793f891c7152cf6e548d0fd012929bd719230157ee97'
aarch64: '1bbf7715c57c0ea0fd357d5828c1f57b913d824365aafba078536b4ed004b802',
armv7l: '1bbf7715c57c0ea0fd357d5828c1f57b913d824365aafba078536b4ed004b802',
i686: 'aef99be4baeaa602293b09c54c40931c9b4008a9caec991a0186c87ba2c80b40',
x86_64: 'ded94b3dbb3489531f46c01abe2e5a0c70a85dad9171e8e5155e5277cb6ad960'
})
# depends_on 'ccache' => :build
depends_on 'ccache' => :build
depends_on 'dejagnu' => :build # for test
depends_on 'glibc' # R
patchelf
@gcc_name = 'libssp'
@gcc_global_opts = '--disable-libmpx \

View File

@@ -29,7 +29,7 @@ class Libx11 < Package
depends_on 'libxcb' # R
depends_on 'libxdmcp' # R
depends_on 'libxtrans' => :build
depends_on 'llvm_lib16' => :build
depends_on 'llvm16_lib' => :build
depends_on 'xorg_proto' => :build
def self.build

View File

@@ -22,7 +22,7 @@ class Libxext < Package
x86_64: '9024bf186472eeb3ed2fe0ea7c77716f76c9860248418d8f804f600d5b5c2704'
})
depends_on 'llvm_lib16' => :build
depends_on 'llvm16_lib' => :build
def self.build
ENV['CFLAGS'] = '-fuse-ld=lld'

View File

@@ -1,15 +1,15 @@
require 'package'
require_relative 'llvm_build16'
require_relative 'llvm16_build'
class Llvm < Package
description 'The LLVM Project is a collection of modular and reusable compiler and toolchain technologies. The optional packages clang, lld, lldb, polly, compiler-rt, libcxx, and libcxxabi are included.'
homepage Llvm_build16.homepage.to_s
version Llvm_build16.version.to_s
license Llvm_build16.license
compatibility Llvm_build16.compatibility.to_s
homepage Llvm16_build.homepage.to_s
version Llvm16_build.version.to_s
license Llvm16_build.license
compatibility Llvm16_build.compatibility.to_s
is_fake
depends_on 'llvm_lib16'
depends_on 'llvm_dev16'
depends_on 'llvm16_lib'
depends_on 'llvm16_dev'
end

218
packages/llvm16_build.rb Normal file
View File

@@ -0,0 +1,218 @@
require 'package'
class Llvm16_build < Package
description 'The LLVM Project is a collection of modular and reusable compiler and toolchain technologies. The optional packages clang, lld, lldb, polly, compiler-rt, libcxx, and libcxxabi are included.'
homepage 'http://llvm.org/'
version '16.0.6'
license 'Apache-2.0-with-LLVM-exceptions, UoI-NCSA, BSD, public-domain, rc, Apache-2.0 and MIT'
compatibility 'all'
source_url 'https://github.com/llvm/llvm-project.git'
git_hashtag "llvmorg-#{version}"
binary_url({
aarch64: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/llvm16_build/16.0.6_armv7l/llvm16_build-16.0.6-chromeos-armv7l.tar.zst',
armv7l: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/llvm16_build/16.0.6_armv7l/llvm16_build-16.0.6-chromeos-armv7l.tar.zst',
i686: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/llvm16_build/16.0.6_i686/llvm16_build-16.0.6-chromeos-i686.tar.zst',
x86_64: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/llvm16_build/16.0.6_x86_64/llvm16_build-16.0.6-chromeos-x86_64.tar.zst'
})
binary_sha256({
aarch64: 'ee0225da3164ae54a9d964b3606892b9cd0c6d37ade2096bbd64ce94eb2e586d',
armv7l: 'ee0225da3164ae54a9d964b3606892b9cd0c6d37ade2096bbd64ce94eb2e586d',
i686: '513668bf8310c34b0d0bfa26304a268a92904d3e6b81902f9148f69ab915ce6b',
x86_64: '53fbe0edeb0e5a7a9ad1767ce3bbaf00c306cf6f05960fe1e2bb0566ec61a748'
})
depends_on 'ocaml' => :build
depends_on 'py3_pygments' => :build
depends_on 'ccache' => :build
depends_on 'elfutils' # R
depends_on 'gcc_lib' # R
depends_on 'glibc' # R
depends_on 'libedit' # R
depends_on 'libffi' # R
depends_on 'libxml2' # R
depends_on 'ncurses' # R
depends_on 'py3_pyyaml' => :build
depends_on 'xzutils' # R
depends_on 'zlibpkg' # R
depends_on 'zstd' # R
no_env_options
conflicts_ok
case ARCH
when 'aarch64', 'armv7l'
# LLVM_TARGETS_TO_BUILD = 'ARM;AArch64;AMDGPU'
# LLVM_TARGETS_TO_BUILD = 'all'.freeze
@ARCH_C_FLAGS = "-fPIC -mfloat-abi=hard -mthumb -mfpu=vfpv3-d16 -march=armv7-a+fp -ccc-gcc-name #{CREW_BUILD}"
@ARCH_CXX_FLAGS = "-fPIC -mfloat-abi=hard -mthumb -mfpu=vfpv3-d16 -march=armv7-a+fp -ccc-gcc-name #{CREW_BUILD}"
@ARCH_LDFLAGS = ''
@ARCH_LTO_LDFLAGS = "#{@ARCH_LDFLAGS} -flto=thin"
LLVM_PROJECTS_TO_BUILD = 'clang;clang-tools-extra;compiler-rt;libclc;lld;lldb;polly;pstl'.freeze
when 'i686'
# LLVM_TARGETS_TO_BUILD = 'X86'.freeze
# Because ld.lld: error: undefinler-rt;libc;libcxx;libcxxabi;libunwind;openmped symbol: __atomic_store
# Polly demands fPIC
@ARCH_C_FLAGS = '-latomic -fPIC'
@ARCH_CXX_FLAGS = '-latomic -fPIC'
# Because getting this error:
# ld.lld: error: relocation R_386_PC32 cannot be used against symbol isl_map_fix_si; recompile with -fPIC
# So as per https://github.com/openssl/openssl/issues/11305#issuecomment-602003528
@ARCH_LDFLAGS = '-Wl,-znotext'
@ARCH_LTO_LDFLAGS = "#{@ARCH_LDFLAGS} -flto=thin"
# lldb fails on i686 due to requirement for a kernel > 4.1.
# See https://github.com/llvm/llvm-project/issues/57594
LLVM_PROJECTS_TO_BUILD = 'clang;clang-tools-extra;compiler-rt;libclc;lld;lldb;polly;pstl'.freeze
when 'x86_64'
# LLVM_TARGETS_TO_BUILD = 'X86;AMDGPU'
# LLVM_TARGETS_TO_BUILD = 'all'.freeze
@ARCH_C_FLAGS = '-fPIC'
@ARCH_CXX_FLAGS = '-fPIC'
@ARCH_LDFLAGS = ''
@ARCH_LTO_LDFLAGS = "#{@ARCH_LDFLAGS} -flto=thin"
LLVM_PROJECTS_TO_BUILD = 'clang;clang-tools-extra;compiler-rt;libclc;lld;lldb;polly;pstl'.freeze
end
@ARCH_C_LTO_FLAGS = "#{@ARCH_C_FLAGS} -flto=thin"
@ARCH_CXX_LTO_FLAGS = "#{@ARCH_CXX_FLAGS} -flto=thin"
# flang isn't supported on 32-bit architectures.
# openmp is its own package.
# LLVM_PROJECTS_TO_BUILD = 'clang;clang-tools-extra;libcxx;libcxxabi;libunwind;lldb;compiler-rt;lld;polly;openmp'.freeze
# Using Targets 'all' for non-i686 because otherwise mesa complains.
# This may be patched upstream as per
# https://reviews.llvm.org/rG1de56d6d13c083c996dfd44a32041dacae037d66
LLVM_TARGETS_TO_BUILD = 'all'.freeze
def self.patch
return unless ARCH == 'i686'
# Patch for LLVM 15 because of https://github.com/llvm/llvm-project/issues/58851
File.write 'llvm_i686.patch', <<~LLVM_PATCH_EOF
--- a/clang/lib/Driver/ToolChains/Linux.cpp 2022-11-30 15:50:36.777754608 -0500
+++ b/clang/lib/Driver/ToolChains/Linux.cpp 2022-11-30 15:51:57.004417484 -0500
@@ -314,6 +314,7 @@ Linux::Linux(const Driver &D, const llvm
D.getVFS().exists(D.Dir + "/../lib/libc++.so"))
addPathIfExists(D, D.Dir + "/../lib", Paths);
+ addPathIfExists(D, concat(SysRoot, "#{CREW_LIB_PREFIX}"), Paths);
addPathIfExists(D, concat(SysRoot, "/lib"), Paths);
addPathIfExists(D, concat(SysRoot, "/usr/lib"), Paths);
}
LLVM_PATCH_EOF
system 'patch -Np1 -i llvm_i686.patch'
end
def self.build
############################################################
puts "Building LLVM Targets: #{LLVM_TARGETS_TO_BUILD}".lightgreen
puts "Building LLVM Projects: #{LLVM_PROJECTS_TO_BUILD}".lightgreen
############################################################
unless Dir.exist?('builddir')
FileUtils.mkdir_p 'builddir'
File.write 'builddir/clc', <<~CLC_EOF
#!/bin/bash
machine=$(gcc -dumpmachine)
version=$(gcc -dumpversion)
gnuc_lib=#{CREW_LIB_PREFIX}/gcc/${machine}/${version}
clang -B ${gnuc_lib} -L ${gnuc_lib} "$@"
CLC_EOF
File.write 'builddir/clc++', <<~CLCPLUSPLUS_EOF
#!/bin/bash
machine=$(gcc -dumpmachine)
version=$(gcc -dumpversion)
cxx_sys=#{CREW_PREFIX}/include/c++/${version}
cxx_inc=#{CREW_PREFIX}/include/c++/${version}/${machine}
gnuc_lib=#{CREW_LIB_PREFIX}/gcc/${machine}/${version}
clang++ -fPIC -rtlib=compiler-rt -stdlib=libc++ -cxx-isystem ${cxx_sys} -I ${cxx_inc} -B ${gnuc_lib} -L ${gnuc_lib} "$@"
CLCPLUSPLUS_EOF
system "cmake -B builddir -G Ninja llvm \
-DCMAKE_ASM_COMPILER_TARGET=#{CREW_BUILD} \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_C_COMPILER=$(which clang) \
-DCMAKE_C_COMPILER_LAUNCHER=ccache \
-DCMAKE_C_COMPILER_TARGET=#{CREW_BUILD} \
-DCMAKE_C_FLAGS='#{@ARCH_C_LTO_FLAGS}' \
-DCMAKE_CXX_COMPILER=$(which clang++) \
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache \
-DCMAKE_CXX_FLAGS='#{@ARCH_CXX_LTO_FLAGS}' \
-DCMAKE_EXE_LINKER_FLAGS='#{@ARCH_LTO_LDFLAGS}' \
-DCMAKE_INSTALL_PREFIX=#{CREW_PREFIX} \
-DCMAKE_LINKER=$(which ld.lld) \
-D_CMAKE_TOOLCHAIN_PREFIX=llvm- \
-DCOMPILER_RT_BUILD_BUILTINS=ON \
-DCOMPILER_RT_BUILD_LIBFUZZER=OFF \
-DCOMPILER_RT_BUILD_SANITIZERS=OFF \
-DCOMPILER_RT_DEFAULT_TARGET_ONLY=ON \
-DLIBOMP_ENABLE_SHARED=ON \
-DLIBOMP_INSTALL_ALIASES=OFF \
-DLIBUNWIND_C_FLAGS='-fno-exceptions -funwind-tables' \
-DLIBUNWIND_CXX_FLAGS='-fno-exceptions -funwind-tables' \
-DLIBUNWIND_SUPPORTS_FNO_EXCEPTIONS_FLAG=ON \
-DLIBUNWIND_SUPPORTS_FUNWIND_TABLES_FLAG=ON \
-DLLVM_BINUTILS_INCDIR='#{CREW_PREFIX}/include' \
-DLLVM_BUILD_LLVM_DYLIB=ON \
-DLLVM_CCACHE_BUILD=ON \
-DLLVM_DEFAULT_TARGET_TRIPLE=#{CREW_BUILD} \
-DLLVM_ENABLE_FFI=ON \
-DLLVM_ENABLE_LTO=Thin \
-DLLVM_ENABLE_PROJECTS='#{LLVM_PROJECTS_TO_BUILD}' \
-DLLVM_ENABLE_RTTI=ON \
-DLLVM_ENABLE_RUNTIME=all \
-DLLVM_ENABLE_TERMINFO=ON \
-DLLVM_INCLUDE_BENCHMARKS=OFF \
-DLLVM_INSTALL_UTILS=ON \
-DLLVM_LIBDIR_SUFFIX='#{CREW_LIB_SUFFIX}' \
-DLLVM_LINK_LLVM_DYLIB=ON \
-DLLVM_OPTIMIZED_TABLEGEN=ON \
-DLLVM_TARGETS_TO_BUILD='#{LLVM_TARGETS_TO_BUILD}' \
-DOPENMP_ENABLE_LIBOMPTARGET=OFF \
-DPYTHON_EXECUTABLE=$(which python3) \
-Wno-dev"
end
@counter = 1
@counter_max = 20
loop do
break if Kernel.system "#{CREW_NINJA} -C builddir -j #{CREW_NPROC}"
puts "Make iteration #{@counter} of #{@counter_max}...".orange
@counter += 1
break if @counter > @counter_max
end
end
def self.install
system "DESTDIR=#{CREW_DEST_DIR} #{CREW_NINJA} -C builddir install"
Dir.chdir('builddir') do
FileUtils.install 'clc', "#{CREW_DEST_PREFIX}/bin/clc", mode: 0o755
FileUtils.install 'clc++', "#{CREW_DEST_PREFIX}/bin/clc++", mode: 0o755
FileUtils.mkdir_p "#{CREW_DEST_LIB_PREFIX}/bfd-plugins"
Dir.chdir("#{CREW_DEST_LIB_PREFIX}/bfd-plugins") do
FileUtils.ln_s "../../lib#{CREW_LIB_SUFFIX}/LLVMgold.so", 'LLVMgold.so'
end
# libunwind.* conflicts with libunwind package
FileUtils.rm Dir.glob("#{CREW_DEST_LIB_PREFIX}/libunwind.*")
end
end
# preserve for check, skip check for current version
def self.check
# Dir.chdir('builddir') do
# system 'samu check-llvm || true'
# system 'samu check-clang || true'
# system 'samu check-lld || true'
# end
end
def self.postinstall
puts
puts "To compile programs, use 'clang' or 'clang++'.".lightblue
puts
puts 'To avoid the repeated use of switch options,'.lightblue
puts "try the wrapper scripts 'clc' or 'clc++'.".lightblue
puts
puts 'For more information, see http://llvm.org/pubs/2008-10-04-ACAT-LLVM-Intro.pdf'.lightblue
puts
end
end

58
packages/llvm16_dev.rb Normal file
View File

@@ -0,0 +1,58 @@
require 'package'
require_relative 'llvm16_build'
class Llvm16_dev < Package
description 'LLVM: Everything except libLLVM & llvm-strip'
homepage Llvm16_build.homepage
version '16.0.6'
# When upgrading llvm_build*, be sure to upgrade llvm_lib* and llvm_dev* in tandem.
puts "#{self} version differs from llvm version #{Llvm16_build.version}".orange if version != Llvm16_build.version.to_s
license Llvm16_build.license
compatibility 'all'
source_url 'SKIP'
binary_url({
aarch64: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/llvm16_dev/16.0.6_armv7l/llvm16_dev-16.0.6-chromeos-armv7l.tar.zst',
armv7l: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/llvm16_dev/16.0.6_armv7l/llvm16_dev-16.0.6-chromeos-armv7l.tar.zst',
i686: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/llvm16_dev/16.0.6_i686/llvm16_dev-16.0.6-chromeos-i686.tar.zst',
x86_64: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/llvm16_dev/16.0.6_x86_64/llvm16_dev-16.0.6-chromeos-x86_64.tar.zst'
})
binary_sha256({
aarch64: 'ec2e7ecd345e7d39e8e6e0de780b4770abe3f839d1ddaed51c16e86d97b7a024',
armv7l: 'ec2e7ecd345e7d39e8e6e0de780b4770abe3f839d1ddaed51c16e86d97b7a024',
i686: 'e8d83c2237656c00ff57c562c25901004a2e88a3015e6bf40954afad4172c05b',
x86_64: '427c152245ddd14db63e2b9d41038b1c0cc37e2c63ab758a5d04d654e066b69e'
})
depends_on 'gcc_dev' # R
depends_on 'gcc_lib' # R
depends_on 'glibc' # R
depends_on 'libedit' # R
depends_on 'libffi' # R
depends_on 'libxml2' # R
depends_on 'llvm16_build' => :build
depends_on 'llvm16_lib' # R
depends_on 'ncurses' # R
depends_on 'xzutils' # R
depends_on 'zlibpkg' # R
depends_on 'zstd' # R
def self.install
puts 'Installing llvm16_build to pull files for build...'.lightblue
@filelist_path = File.join(CREW_META_PATH, 'llvm16_build.filelist')
abort 'File list for llvm16_build does not exist!'.lightred unless File.file?(@filelist_path)
@filelist = File.readlines(@filelist_path, chomp: true).sort
@filelist.each do |filename|
if filename.include?('.so') && filename.include?('libLLVM')
next
elsif filename.include?('llvm-strip')
next
end
@destpath = "#{CREW_DEST_DIR.chomp('/')}#{filename}"
@filename_target = File.realpath(filename)
FileUtils.install @filename_target, @destpath
end
end
end

51
packages/llvm16_lib.rb Normal file
View File

@@ -0,0 +1,51 @@
require 'package'
require_relative 'llvm16_build'
class Llvm16_lib < Package
description 'LibLLVM and llvm-strip'
homepage Llvm16_build.homepage
version '16.0.6'
# When upgrading llvm_build*, be sure to upgrade llvm_lib* and llvm_dev* in tandem.
puts "#{self} version differs from llvm version #{Llvm16_build.version}".orange if version != Llvm16_build.version.to_s
license Llvm16_build.license
compatibility 'all'
source_url 'SKIP'
binary_url({
aarch64: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/llvm16_lib/16.0.6_armv7l/llvm16_lib-16.0.6-chromeos-armv7l.tar.zst',
armv7l: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/llvm16_lib/16.0.6_armv7l/llvm16_lib-16.0.6-chromeos-armv7l.tar.zst',
i686: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/llvm16_lib/16.0.6_i686/llvm16_lib-16.0.6-chromeos-i686.tar.zst',
x86_64: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/llvm16_lib/16.0.6_x86_64/llvm16_lib-16.0.6-chromeos-x86_64.tar.zst'
})
binary_sha256({
aarch64: '996924278cd5695a0fee50649498a95b30417af629eb3b0edad66b4805fc5e9c',
armv7l: '996924278cd5695a0fee50649498a95b30417af629eb3b0edad66b4805fc5e9c',
i686: 'd7796f4b22c14c73cab97265fa0b94305fb10de2764a11e857e2049287afdc8e',
x86_64: '76eb8ce408c2260479fb73f82ec5a9e1f895e34b4bcc77a88a8f46eed38c2ba0'
})
depends_on 'gcc_lib' # R
depends_on 'glibc' # R
depends_on 'libedit' # R
depends_on 'libffi' # R
depends_on 'libxml2' # R
depends_on 'llvm16_build' => :build
depends_on 'ncurses' # R
depends_on 'zlibpkg' # R
depends_on 'zstd' # R
def self.install
puts 'Installing llvm16_build to pull files for build...'.lightblue
@filelist_path = File.join(CREW_META_PATH, 'llvm16_build.filelist')
abort 'File list for llvm16_build does not exist!'.lightred unless File.file?(@filelist_path)
@filelist = File.readlines(@filelist_path, chomp: true).sort
@filelist.each do |filename|
next unless (filename.include?('.so') && filename.include?('libLLVM')) || filename.include?('llvm-strip')
@destpath = "#{CREW_DEST_DIR.chomp('/')}#{filename}"
@filename_target = File.realpath(filename)
FileUtils.install @filename_target, @destpath
end
end
end

View File

@@ -1,218 +1,15 @@
require 'package'
require_relative 'llvm16_build'
class Llvm_build16 < Package
description 'The LLVM Project is a collection of modular and reusable compiler and toolchain technologies. The optional packages clang, lld, lldb, polly, compiler-rt, libcxx, and libcxxabi are included.'
homepage 'http://llvm.org/'
version '16.0.5'
license 'Apache-2.0-with-LLVM-exceptions, UoI-NCSA, BSD, public-domain, rc, Apache-2.0 and MIT'
compatibility 'all'
source_url 'https://github.com/llvm/llvm-project.git'
git_hashtag "llvmorg-#{version}"
homepage Llvm16_build.homepage.to_s
version Llvm16_build.version.to_s
license Llvm16_build.license
compatibility Llvm16_build.compatibility.to_s
binary_url({
aarch64: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/llvm_build16/16.0.5_armv7l/llvm_build16-16.0.5-chromeos-armv7l.tar.zst',
armv7l: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/llvm_build16/16.0.5_armv7l/llvm_build16-16.0.5-chromeos-armv7l.tar.zst',
i686: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/llvm_build16/16.0.5_i686/llvm_build16-16.0.5-chromeos-i686.tar.zst',
x86_64: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/llvm_build16/16.0.5_x86_64/llvm_build16-16.0.5-chromeos-x86_64.tar.zst'
})
binary_sha256({
aarch64: '9c2cf4b212a6db1175945d98beeae7b7e7cee8b270570651261fcde7818444ce',
armv7l: '9c2cf4b212a6db1175945d98beeae7b7e7cee8b270570651261fcde7818444ce',
i686: '7eeb97b5675712423c091ac84b8f0bf753a8ae7789857c1b8f17f88b5bb5df7d',
x86_64: '54b646b81f76a6c8f7e2593fb1cfe002502ca433a52a4ec85cfe6924b3ad2895'
})
is_fake
depends_on 'ocaml' => :build
depends_on 'py3_pygments' => :build
depends_on 'ccache' => :build
depends_on 'elfutils' # R
depends_on 'gcc_lib' # R
depends_on 'glibc' # R
depends_on 'libedit' # R
depends_on 'libffi' # R
depends_on 'libxml2' # R
depends_on 'ncurses' # R
depends_on 'py3_pyyaml' => :build
depends_on 'xzutils' # R
depends_on 'zlibpkg' # R
depends_on 'zstd' # R
no_env_options
conflicts_ok
case ARCH
when 'aarch64', 'armv7l'
# LLVM_TARGETS_TO_BUILD = 'ARM;AArch64;AMDGPU'
# LLVM_TARGETS_TO_BUILD = 'all'.freeze
@ARCH_C_FLAGS = "-fPIC -mfloat-abi=hard -mthumb -mfpu=vfpv3-d16 -march=armv7-a+fp -ccc-gcc-name #{CREW_BUILD}"
@ARCH_CXX_FLAGS = "-fPIC -mfloat-abi=hard -mthumb -mfpu=vfpv3-d16 -march=armv7-a+fp -ccc-gcc-name #{CREW_BUILD}"
@ARCH_LDFLAGS = ''
@ARCH_LTO_LDFLAGS = "#{@ARCH_LDFLAGS} -flto=thin"
LLVM_PROJECTS_TO_BUILD = 'clang;clang-tools-extra;compiler-rt;libclc;lld;lldb;polly;pstl'.freeze
when 'i686'
# LLVM_TARGETS_TO_BUILD = 'X86'.freeze
# Because ld.lld: error: undefinler-rt;libc;libcxx;libcxxabi;libunwind;openmped symbol: __atomic_store
# Polly demands fPIC
@ARCH_C_FLAGS = '-latomic -fPIC'
@ARCH_CXX_FLAGS = '-latomic -fPIC'
# Because getting this error:
# ld.lld: error: relocation R_386_PC32 cannot be used against symbol isl_map_fix_si; recompile with -fPIC
# So as per https://github.com/openssl/openssl/issues/11305#issuecomment-602003528
@ARCH_LDFLAGS = '-Wl,-znotext'
@ARCH_LTO_LDFLAGS = "#{@ARCH_LDFLAGS} -flto=thin"
# lldb fails on i686 due to requirement for a kernel > 4.1.
# See https://github.com/llvm/llvm-project/issues/57594
LLVM_PROJECTS_TO_BUILD = 'clang;clang-tools-extra;compiler-rt;libclc;lld;lldb;polly;pstl'.freeze
when 'x86_64'
# LLVM_TARGETS_TO_BUILD = 'X86;AMDGPU'
# LLVM_TARGETS_TO_BUILD = 'all'.freeze
@ARCH_C_FLAGS = '-fPIC'
@ARCH_CXX_FLAGS = '-fPIC'
@ARCH_LDFLAGS = ''
@ARCH_LTO_LDFLAGS = "#{@ARCH_LDFLAGS} -flto=thin"
LLVM_PROJECTS_TO_BUILD = 'clang;clang-tools-extra;compiler-rt;libclc;lld;lldb;polly;pstl'.freeze
end
@ARCH_C_LTO_FLAGS = "#{@ARCH_C_FLAGS} -flto=thin"
@ARCH_CXX_LTO_FLAGS = "#{@ARCH_CXX_FLAGS} -flto=thin"
# flang isn't supported on 32-bit architectures.
# openmp is its own package.
# LLVM_PROJECTS_TO_BUILD = 'clang;clang-tools-extra;libcxx;libcxxabi;libunwind;lldb;compiler-rt;lld;polly;openmp'.freeze
# Using Targets 'all' for non-i686 because otherwise mesa complains.
# This may be patched upstream as per
# https://reviews.llvm.org/rG1de56d6d13c083c996dfd44a32041dacae037d66
LLVM_TARGETS_TO_BUILD = 'all'.freeze
def self.patch
return unless ARCH == 'i686'
# Patch for LLVM 15 because of https://github.com/llvm/llvm-project/issues/58851
File.write 'llvm_i686.patch', <<~LLVM_PATCH_EOF
--- a/clang/lib/Driver/ToolChains/Linux.cpp 2022-11-30 15:50:36.777754608 -0500
+++ b/clang/lib/Driver/ToolChains/Linux.cpp 2022-11-30 15:51:57.004417484 -0500
@@ -314,6 +314,7 @@ Linux::Linux(const Driver &D, const llvm
D.getVFS().exists(D.Dir + "/../lib/libc++.so"))
addPathIfExists(D, D.Dir + "/../lib", Paths);
+ addPathIfExists(D, concat(SysRoot, "#{CREW_LIB_PREFIX}"), Paths);
addPathIfExists(D, concat(SysRoot, "/lib"), Paths);
addPathIfExists(D, concat(SysRoot, "/usr/lib"), Paths);
}
LLVM_PATCH_EOF
system 'patch -Np1 -i llvm_i686.patch'
end
def self.build
############################################################
puts "Building LLVM Targets: #{LLVM_TARGETS_TO_BUILD}".lightgreen
puts "Building LLVM Projects: #{LLVM_PROJECTS_TO_BUILD}".lightgreen
############################################################
unless Dir.exist?('builddir')
FileUtils.mkdir_p 'builddir'
File.write 'builddir/clc', <<~CLC_EOF
#!/bin/bash
machine=$(gcc -dumpmachine)
version=$(gcc -dumpversion)
gnuc_lib=#{CREW_LIB_PREFIX}/gcc/${machine}/${version}
clang -B ${gnuc_lib} -L ${gnuc_lib} "$@"
CLC_EOF
File.write 'builddir/clc++', <<~CLCPLUSPLUS_EOF
#!/bin/bash
machine=$(gcc -dumpmachine)
version=$(gcc -dumpversion)
cxx_sys=#{CREW_PREFIX}/include/c++/${version}
cxx_inc=#{CREW_PREFIX}/include/c++/${version}/${machine}
gnuc_lib=#{CREW_LIB_PREFIX}/gcc/${machine}/${version}
clang++ -fPIC -rtlib=compiler-rt -stdlib=libc++ -cxx-isystem ${cxx_sys} -I ${cxx_inc} -B ${gnuc_lib} -L ${gnuc_lib} "$@"
CLCPLUSPLUS_EOF
system "cmake -B builddir -G Ninja llvm \
-DCMAKE_ASM_COMPILER_TARGET=#{CREW_BUILD} \
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_C_COMPILER=$(which clang) \
-DCMAKE_C_COMPILER_LAUNCHER=ccache \
-DCMAKE_C_COMPILER_TARGET=#{CREW_BUILD} \
-DCMAKE_C_FLAGS='#{@ARCH_C_LTO_FLAGS}' \
-DCMAKE_CXX_COMPILER=$(which clang++) \
-DCMAKE_CXX_COMPILER_LAUNCHER=ccache \
-DCMAKE_CXX_FLAGS='#{@ARCH_CXX_LTO_FLAGS}' \
-DCMAKE_EXE_LINKER_FLAGS='#{@ARCH_LTO_LDFLAGS}' \
-DCMAKE_INSTALL_PREFIX=#{CREW_PREFIX} \
-DCMAKE_LINKER=$(which ld.lld) \
-D_CMAKE_TOOLCHAIN_PREFIX=llvm- \
-DCOMPILER_RT_BUILD_BUILTINS=ON \
-DCOMPILER_RT_BUILD_LIBFUZZER=OFF \
-DCOMPILER_RT_BUILD_SANITIZERS=OFF \
-DCOMPILER_RT_DEFAULT_TARGET_ONLY=ON \
-DLIBOMP_ENABLE_SHARED=ON \
-DLIBOMP_INSTALL_ALIASES=OFF \
-DLIBUNWIND_C_FLAGS='-fno-exceptions -funwind-tables' \
-DLIBUNWIND_CXX_FLAGS='-fno-exceptions -funwind-tables' \
-DLIBUNWIND_SUPPORTS_FNO_EXCEPTIONS_FLAG=ON \
-DLIBUNWIND_SUPPORTS_FUNWIND_TABLES_FLAG=ON \
-DLLVM_BINUTILS_INCDIR='#{CREW_PREFIX}/include' \
-DLLVM_BUILD_LLVM_DYLIB=ON \
-DLLVM_CCACHE_BUILD=ON \
-DLLVM_DEFAULT_TARGET_TRIPLE=#{CREW_BUILD} \
-DLLVM_ENABLE_FFI=ON \
-DLLVM_ENABLE_LTO=Thin \
-DLLVM_ENABLE_PROJECTS='#{LLVM_PROJECTS_TO_BUILD}' \
-DLLVM_ENABLE_RTTI=ON \
-DLLVM_ENABLE_RUNTIME=all \
-DLLVM_ENABLE_TERMINFO=ON \
-DLLVM_INCLUDE_BENCHMARKS=OFF \
-DLLVM_INSTALL_UTILS=ON \
-DLLVM_LIBDIR_SUFFIX='#{CREW_LIB_SUFFIX}' \
-DLLVM_LINK_LLVM_DYLIB=ON \
-DLLVM_OPTIMIZED_TABLEGEN=ON \
-DLLVM_TARGETS_TO_BUILD='#{LLVM_TARGETS_TO_BUILD}' \
-DOPENMP_ENABLE_LIBOMPTARGET=OFF \
-DPYTHON_EXECUTABLE=$(which python3) \
-Wno-dev"
end
@counter = 1
@counter_max = 20
loop do
break if Kernel.system "#{CREW_NINJA} -C builddir -j #{CREW_NPROC}"
puts "Make iteration #{@counter} of #{@counter_max}...".orange
@counter += 1
break if @counter > @counter_max
end
end
def self.install
system "DESTDIR=#{CREW_DEST_DIR} #{CREW_NINJA} -C builddir install"
Dir.chdir('builddir') do
FileUtils.install 'clc', "#{CREW_DEST_PREFIX}/bin/clc", mode: 0o755
FileUtils.install 'clc++', "#{CREW_DEST_PREFIX}/bin/clc++", mode: 0o755
FileUtils.mkdir_p "#{CREW_DEST_LIB_PREFIX}/bfd-plugins"
Dir.chdir("#{CREW_DEST_LIB_PREFIX}/bfd-plugins") do
FileUtils.ln_s "../../lib#{CREW_LIB_SUFFIX}/LLVMgold.so", 'LLVMgold.so'
end
# libunwind.* conflicts with libunwind package
FileUtils.rm Dir.glob("#{CREW_DEST_LIB_PREFIX}/libunwind.*")
end
end
# preserve for check, skip check for current version
def self.check
# Dir.chdir('builddir') do
# system 'samu check-llvm || true'
# system 'samu check-clang || true'
# system 'samu check-lld || true'
# end
end
def self.postinstall
puts
puts "To compile programs, use 'clang' or 'clang++'.".lightblue
puts
puts 'To avoid the repeated use of switch options,'.lightblue
puts "try the wrapper scripts 'clc' or 'clc++'.".lightblue
puts
puts 'For more information, see http://llvm.org/pubs/2008-10-04-ACAT-LLVM-Intro.pdf'.lightblue
puts
end
depends_on 'llvm16_lib'
depends_on 'llvm16_dev'
end

View File

@@ -1,57 +1,14 @@
require 'package'
require_relative 'llvm_build16'
require_relative 'llvm16_build'
class Llvm_dev16 < Package
description 'LLVM: Everything except libLLVM & llvm-strip'
homepage Llvm_build16.homepage
version '16.0.5'
# When upgrading llvm_build*, be sure to upgrade llvm_lib* and llvm_dev* in tandem.
puts "#{self} version differs from llvm version #{Llvm_build16.version}".orange if version != Llvm_build16.version.to_s
license Llvm_build16.license
compatibility 'all'
source_url 'SKIP'
description 'The LLVM Project is a collection of modular and reusable compiler and toolchain technologies. The optional packages clang, lld, lldb, polly, compiler-rt, libcxx, and libcxxabi are included.'
homepage Llvm16_build.homepage.to_s
version Llvm16_build.version.to_s
license Llvm16_build.license
compatibility Llvm16_build.compatibility.to_s
binary_url({
aarch64: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/llvm_dev16/16.0.5_armv7l/llvm_dev16-16.0.5-chromeos-armv7l.tar.zst',
armv7l: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/llvm_dev16/16.0.5_armv7l/llvm_dev16-16.0.5-chromeos-armv7l.tar.zst',
i686: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/llvm_dev16/16.0.5_i686/llvm_dev16-16.0.5-chromeos-i686.tar.zst',
x86_64: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/llvm_dev16/16.0.5_x86_64/llvm_dev16-16.0.5-chromeos-x86_64.tar.zst'
})
binary_sha256({
aarch64: 'f4a2ccdb3366661c1ac733a317fe1853e5a5257fb7060610881ec34569cb3317',
armv7l: 'f4a2ccdb3366661c1ac733a317fe1853e5a5257fb7060610881ec34569cb3317',
i686: 'a14b1808ff4d03b0fd5431c86d84ddb0a1d435bef96ae0c347b623bb34aa5206',
x86_64: 'eba6acd9fd5192ac826cdc4491cb442bb1cb3a1317368929b1c622ae58a361c9'
})
is_fake
depends_on 'gcc_lib' # R
depends_on 'glibc' # R
depends_on 'libedit' # R
depends_on 'libffi' # R
depends_on 'libxml2' # R
depends_on 'llvm_build16' => :build
depends_on 'llvm_lib16' # R
depends_on 'ncurses' # R
depends_on 'xzutils' # R
depends_on 'zlibpkg' # R
depends_on 'zstd' # R
def self.install
puts 'Installing llvm_build16 to pull files for build...'.lightblue
@filelist_path = File.join(CREW_META_PATH, 'llvm_build16.filelist')
abort 'File list for llvm_build16 does not exist!'.lightred unless File.file?(@filelist_path)
@filelist = File.readlines(@filelist_path, chomp: true).sort
@filelist.each do |filename|
if filename.include?('.so') && filename.include?('libLLVM')
next
elsif filename.include?('llvm-strip')
next
end
@destpath = "#{CREW_DEST_DIR.chomp('/')}#{filename}"
@filename_target = File.realpath(filename)
FileUtils.install @filename_target, @destpath
end
end
depends_on 'llvm16_dev'
end

View File

@@ -1,51 +1,14 @@
require 'package'
require_relative 'llvm_build16'
require_relative 'llvm16_build'
class Llvm_lib16 < Package
description 'LibLLVM and llvm-strip'
homepage Llvm_build16.homepage
version '16.0.5'
# When upgrading llvm_build*, be sure to upgrade llvm_lib* and llvm_dev* in tandem.
puts "#{self} version differs from llvm version #{Llvm_build16.version}".orange if version != Llvm_build16.version.to_s
license Llvm_build16.license
compatibility 'all'
source_url 'SKIP'
description 'The LLVM Project is a collection of modular and reusable compiler and toolchain technologies. The optional packages clang, lld, lldb, polly, compiler-rt, libcxx, and libcxxabi are included.'
homepage Llvm16_build.homepage.to_s
version Llvm16_build.version.to_s
license Llvm16_build.license
compatibility Llvm16_build.compatibility.to_s
binary_url({
aarch64: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/llvm_lib16/16.0.5_armv7l/llvm_lib16-16.0.5-chromeos-armv7l.tar.zst',
armv7l: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/llvm_lib16/16.0.5_armv7l/llvm_lib16-16.0.5-chromeos-armv7l.tar.zst',
i686: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/llvm_lib16/16.0.5_i686/llvm_lib16-16.0.5-chromeos-i686.tar.zst',
x86_64: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/llvm_lib16/16.0.5_x86_64/llvm_lib16-16.0.5-chromeos-x86_64.tar.zst'
})
binary_sha256({
aarch64: 'ac8284a2e2f2c21b330d8f3ebfbd9e93fb023710ce44e702df97d32117d76b60',
armv7l: 'ac8284a2e2f2c21b330d8f3ebfbd9e93fb023710ce44e702df97d32117d76b60',
i686: '96143e8c99aec50b417bfa31b8b34adb645def08b9957cfa7417fcb1e56d0073',
x86_64: '5cde03339bf1b972d926cfb81daa825b5814f387ba02fc729b31b95818b122e2'
})
is_fake
depends_on 'llvm_build16' => :build
depends_on 'gcc_lib' # R
depends_on 'glibc' # R
depends_on 'libedit' # R
depends_on 'libffi' # R
depends_on 'libxml2' # R
depends_on 'ncurses' # R
depends_on 'zlibpkg' # R
depends_on 'zstd' # R
def self.install
puts 'Installing llvm_build16 to pull files for build...'.lightblue
@filelist_path = File.join(CREW_META_PATH, 'llvm_build16.filelist')
abort 'File list for llvm_build16 does not exist!'.lightred unless File.file?(@filelist_path)
@filelist = File.readlines(@filelist_path, chomp: true).sort
@filelist.each do |filename|
next unless (filename.include?('.so') && filename.include?('libLLVM')) || filename.include?('llvm-strip')
@destpath = "#{CREW_DEST_DIR.chomp('/')}#{filename}"
@filename_target = File.realpath(filename)
FileUtils.install @filename_target, @destpath
end
end
depends_on 'llvm16_lib'
end

View File

@@ -46,8 +46,8 @@ class Mesa < Package
depends_on 'libxvmc' # R
depends_on 'libxv' # R
depends_on 'libxxf86vm' # R
depends_on 'llvm_dev16' => :build
depends_on 'llvm_lib16' # R
depends_on 'llvm16_dev' => :build
depends_on 'llvm16_lib' # R
depends_on 'lm_sensors' # R
depends_on 'py3_mako'
depends_on 'valgrind' => :build

View File

@@ -2,36 +2,37 @@
# https://github.com/archlinux/svntogit-packages/raw/packages/openmp/trunk/PKGBUILD
require 'package'
require_relative 'llvm_build16'
require_relative 'llvm16_build'
class Openmp < Package
description 'LLVM OpenMP Runtime Library'
homepage 'https://openmp.llvm.org/'
version '16.0.5'
version '16.0.6'
# When upgrading llvm_build*, be sure to upgrade openmp in tandem.
puts "#{self} version differs from llvm version #{Llvm_build16.version}".orange if version != Llvm_build16.version.to_s
puts "#{self} version differs from llvm version #{Llvm16_build.version}".orange if version != Llvm16_build.version.to_s
license 'Apache-2.0-with-LLVM-exceptions, UoI-NCSA, BSD, public-domain, rc, Apache-2.0 and MIT'
compatibility 'all'
source_url 'https://github.com/llvm/llvm-project.git'
git_hashtag Llvm_build16.git_hashtag.to_s
git_hashtag Llvm16_build.git_hashtag.to_s
binary_url({
aarch64: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/openmp/16.0.5_armv7l/openmp-16.0.5-chromeos-armv7l.tar.zst',
armv7l: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/openmp/16.0.5_armv7l/openmp-16.0.5-chromeos-armv7l.tar.zst',
i686: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/openmp/16.0.5_i686/openmp-16.0.5-chromeos-i686.tar.zst',
x86_64: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/openmp/16.0.5_x86_64/openmp-16.0.5-chromeos-x86_64.tar.zst'
aarch64: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/openmp/16.0.6_armv7l/openmp-16.0.6-chromeos-armv7l.tar.zst',
armv7l: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/openmp/16.0.6_armv7l/openmp-16.0.6-chromeos-armv7l.tar.zst',
i686: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/openmp/16.0.6_i686/openmp-16.0.6-chromeos-i686.tar.zst',
x86_64: 'https://gitlab.com/api/v4/projects/26210301/packages/generic/openmp/16.0.6_x86_64/openmp-16.0.6-chromeos-x86_64.tar.zst'
})
binary_sha256({
aarch64: 'd667cec638ae62c4dc55e11f806948aca950bd365700cf8154e446fc843ed597',
armv7l: 'd667cec638ae62c4dc55e11f806948aca950bd365700cf8154e446fc843ed597',
i686: '0b88daf871a13bf1eab3216ecce5e13e881e69aea6d96296c1d08dd2fe08fc87',
x86_64: '99e5bec3bb7c1704c1002c7abdb9dc3764a8cae950229bf589f475163f23e905'
aarch64: '318372b574bac4b1918d6226b6e6aa2b10817f20d606e0f4237a3ef8442dd2e3',
armv7l: '318372b574bac4b1918d6226b6e6aa2b10817f20d606e0f4237a3ef8442dd2e3',
i686: 'b3437c89a735000b99c6f2af18cd95aaa57bf23d9c215f3fa61f378e5db60efd',
x86_64: 'b2a2215a2c61c383438d73325cd4dfca07617ab7c93ed86eaedb4bd43b80f879'
})
depends_on 'gcc_lib' # R
depends_on 'glibc' # R
depends_on 'libffi'
depends_on 'llvm_lib16' # R
depends_on 'llvm16_dev' => :build
depends_on 'llvm16_lib' # R
depends_on 'python3' # R
no_env_options

View File

@@ -29,7 +29,7 @@ class Postgres < Package
depends_on 'libcyrussasl'
depends_on 'libxml2'
depends_on 'linux_pam'
depends_on 'llvm_lib16'
depends_on 'llvm16_lib'
depends_on 'lz4'
depends_on 'openldap'
depends_on 'perl'

View File

@@ -26,7 +26,7 @@ class Qttools < Package
depends_on 'qtbase' # R
depends_on 'libtinfo' => :build
depends_on 'libglvnd' # R
depends_on 'llvm_lib16' # R
depends_on 'llvm16_lib' # R
depends_on 'qtdeclarative' # R
def self.build

View File

@@ -6,10 +6,10 @@ require 'package'
class Ruby_rubocop < Package
description 'A Ruby static code analyzer and formatter'
homepage 'https://rubocop.org'
version '1.49.0-ruby-3.2'
version '1.52.1-ruby-3.2'
compatibility 'all'
source_url 'https://github.com/chromebrew/chromebrew/raw/master/.rubocop.yml'
source_sha256 'cb65065787f428b6872637fcd2d5b7bc59d25f2a11ffc88834007646148f8af8'
source_sha256 'c25faeecdbc465ef97e5a9d94ca46a64af5a68c2d17d8de7ba622377d22b805c'
depends_on 'libyaml'
depends_on 'ruby'

View File

@@ -28,7 +28,7 @@ class Sommelier < Package
depends_on 'libxcvt'
depends_on 'libxfixes' => :build
depends_on 'libxkbcommon' # R
depends_on 'llvm_lib16' # R Note that this may need rebuilds for newer llvm versions.
depends_on 'llvm16_lib' # R Note that this may need rebuilds for newer llvm versions.
depends_on 'mesa' # R
depends_on 'pixman' # R
depends_on 'procps' # for pgrep in wrapper script

View File

@@ -48,7 +48,7 @@ class Weston < Package
depends_on 'libxkbcommon' # R
depends_on 'libxxf86vm'
depends_on 'linux_pam' # R
depends_on 'llvm_lib16' => :build
depends_on 'llvm16_lib' => :build
depends_on 'mesa' # R
depends_on 'pango' # R
depends_on 'pipewire' # R

View File

@@ -2,6 +2,7 @@
# getrealdeps for Chromebrew version 1.1
# Author: Satadru Pramanik (satmandu) satadru at gmail dot com
# set -x
# export PS4='+(${LINENO}): ${FUNCNAME[0]:+${FUNCNAME[0]}(): }'
pkg="${1%.rb}"
# Exit quickly if an invalid package name is given.
@@ -73,9 +74,9 @@ whatprovidesfxn() {
pkgdepslcl="${1}"
# Handle patchelf inserted full library paths.
if [[ "${pkgdepslcl}" == *"${CREW_LIB_PREFIX}"* ]]; then
filelcl=$($GREP --exclude "${pkg}.filelist" --exclude "${CREW_PREFIX}"/etc/crew/meta/*_build.filelist "${pkgdepslcl}$" "${CREW_PREFIX}"/etc/crew/meta/*.filelist)
filelcl=$($GREP --exclude "${pkg}.filelist" --exclude={"${CREW_PREFIX}/etc/crew/meta/\*_build.filelist"} "${pkgdepslcl}$" "${CREW_PREFIX}"/etc/crew/meta/*.filelist)
else
filelcl=$($GREP --exclude "${pkg}.filelist" --exclude "${CREW_PREFIX}"/etc/crew/meta/*_build.filelist "^${CREW_LIB_PREFIX}.*${pkgdepslcl}$" "${CREW_PREFIX}"/etc/crew/meta/*.filelist)
filelcl=$($GREP --exclude "${pkg}.filelist" --exclude={"${CREW_PREFIX}/etc/crew/meta/\*_build.filelist"} "^${CREW_LIB_PREFIX}.*${pkgdepslcl}$" "${CREW_PREFIX}"/etc/crew/meta/*.filelist)
fi
packagelcl=$(echo "$filelcl" | \
sed 's/.filelist.*//g' | sed 's:.*/::' | awk '!x[$0]++' | sed s/://g)
@@ -121,6 +122,8 @@ echo "$lines" | tr " " "\n" | awk '!x[$0]++')
# Remove original package from list.
pkgdeps=$(tr " " "\n" <<< "$pkgdeps" | sed "/${pkg}/d" | sort -u )
# Replace glibc_build packages with glibc
pkgdeps=$(tr " " "\n" <<< "$pkgdeps" | sed 's/glibc_build.*/glibc/' | sort -u )
# Note which dependencies are missing, but ignore :build lines, since
# build depenencies may still be runtime dependencies.