mirror of
https://github.com/chromebrew/chromebrew.git
synced 2026-01-08 23:18:10 -05:00
* Python => 3.13 Signed-off-by: Satadru Pramanik <satadru@gmail.com> * fix VER variables in const.rb Signed-off-by: Satadru Pramanik <satadru@gmail.com> * bugfixes Signed-off-by: Satadru Pramanik <satadru@gmail.com> * More plumbing changes... Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Adjust py3_pip and py3_setuptools to not error during python3 preinstall. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * fix hash error Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Add no_binaries_needed Signed-off-by: Satadru Pramanik <satadru@gmail.com> * bugfixes... Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Add PYO3_USE_ABI3_FORWARD_COMPATIBILITY=1 to pip.rb to fix python 3.13 builds. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Add workaround for missing binaries... Signed-off-by: Satadru Pramanik <satadru@gmail.com> * update cmake Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Add lots of package updates. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Add py3_bcrypt, rename asciidoc, add more package builds. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * More updates Signed-off-by: Satadru Pramanik <satadru@gmail.com> * revert postgresql update Signed-off-by: Satadru Pramanik <satadru@gmail.com> * final updates? Signed-off-by: Satadru Pramanik <satadru@gmail.com> * update curl Signed-off-by: Satadru Pramanik <satadru@gmail.com> * lint Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Add curl to essential packages to try to prevent unit test failure on i686. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * updates Signed-off-by: Satadru Pramanik <satadru@gmail.com> * lint Signed-off-by: Satadru Pramanik <satadru@gmail.com> * fix accidental change to docker package. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Fiz condition of no new updates leavimg a message with CREW_UNATTENDED set. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * more updates, add missing libabigail binaries Signed-off-by: Satadru Pramanik <satadru@gmail.com> * rebuild py3_dbus_python Signed-off-by: Satadru Pramanik <satadru@gmail.com> * add arm build for 5.10 musl_linuxheaders Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Add builds for openimageio. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Adjust ruby buildsystem slightly to use cache more, adjust unit tests to properly invoke setarch, add py3_pynacl, update libsodium. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Ruby adjustments... Signed-off-by: Satadru Pramanik <satadru@gmail.com> * unit test adjustments... Signed-off-by: Satadru Pramanik <satadru@gmail.com> * unit test adjustments... Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Add error message to pip install... Signed-off-by: Satadru Pramanik <satadru@gmail.com> * expand pip error reporting Signed-off-by: Satadru Pramanik <satadru@gmail.com> * More pip adjustments. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Add more pip verbose error reporting. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Add new workaround for pip failure on i686... Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Refactor pip again... Signed-off-by: Satadru Pramanik <satadru@gmail.com> * more refactoring... Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Adjust py3_pip version restriction. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * Avoid container jdk dependency in snowflake. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * update trove classifiers. Signed-off-by: Satadru Pramanik <satadru@gmail.com> * adjust package fxn exit Signed-off-by: Satadru Pramanik <satadru@gmail.com> * adjust more jdk deps Signed-off-by: Satadru Pramanik <satadru@gmail.com> --------- Signed-off-by: Satadru Pramanik <satadru@gmail.com>
94 lines
3.4 KiB
Ruby
94 lines
3.4 KiB
Ruby
require 'package'
|
|
|
|
class Dmd < Package
|
|
description 'D Programming Language compiler'
|
|
homepage 'https://dlang.org/'
|
|
version '2.102.1'
|
|
license 'BSL-1.0'
|
|
compatibility 'x86_64'
|
|
source_url 'SKIP'
|
|
binary_compression 'tar.zst'
|
|
|
|
binary_sha256({
|
|
x86_64: '4a32b8ae822fc66fc26d6399d9d7db872ae72d8c97f2dde8606bc4defbbe760a'
|
|
})
|
|
|
|
depends_on 'ldc' => :build # For running dub in tests.
|
|
|
|
def self.build
|
|
system "git clone -b v#{version} https://github.com/dlang/dmd.git"
|
|
Dir.chdir 'dmd' do
|
|
system 'make -f posix.mak AUTO_BOOTSTRAP=1'
|
|
end
|
|
system "git clone -b v#{version} https://github.com/dlang/phobos.git"
|
|
Dir.chdir 'phobos' do
|
|
system 'make -f posix.mak'
|
|
end
|
|
system "git clone -b v#{version} https://github.com/dlang/tools.git"
|
|
Dir.chdir 'tools' do
|
|
system 'make -f posix.mak all'
|
|
end
|
|
conf = <<~EOF
|
|
;
|
|
; dmd.conf file for dmd
|
|
;
|
|
; dmd will look for dmd.conf in the following sequence of directories:
|
|
; - current working directory
|
|
; - directory specified by the HOME environment variable
|
|
; - directory dmd resides in
|
|
; - /etc directory
|
|
;
|
|
; Names enclosed by %% are searched for in the existing environment and inserted
|
|
;
|
|
; The special name %@P% is replaced with the path to this file
|
|
;
|
|
|
|
[Environment32]
|
|
DFLAGS=-I#{CREW_PREFIX}/include/phobos -I#{CREW_PREFIX}/include/dmd/druntime/import -L#{CREW_LIB_PREFIX}/i386-linux-gnu --export-dynamic -fPIC
|
|
|
|
[Environment64]
|
|
DFLAGS=-I#{CREW_PREFIX}/include/phobos -I#{CREW_PREFIX}/include/dmd/druntime/import -L#{CREW_LIB_PREFIX}/x86_64-linux-gnu --export-dynamic -fPIC
|
|
EOF
|
|
File.write('dmd.conf', conf)
|
|
end
|
|
|
|
def self.check
|
|
# These tests take a LONG time to run.
|
|
# Dir.chdir 'dmd' do
|
|
# system 'make -f posix.mak test AUTO_BOOTSTRAP=1'
|
|
# end
|
|
# Dir.chdir 'phobos' do
|
|
# system 'make -f posix.mak unittest AUTO_BOOTSTRAP=1'
|
|
# end
|
|
# Tests fail with Error: cannot find input file `/bin/sh.d`
|
|
# Dir.chdir 'tools' do
|
|
# system 'make -f posix.mak test AUTO_BOOTSTRAP=1'
|
|
# end
|
|
end
|
|
|
|
def self.install
|
|
FileUtils.mkdir_p "#{CREW_DEST_PREFIX}/bin"
|
|
FileUtils.mkdir_p "#{CREW_DEST_PREFIX}/etc"
|
|
FileUtils.mkdir_p CREW_DEST_LIB_PREFIX
|
|
FileUtils.mkdir_p "#{CREW_DEST_MAN_PREFIX}/man1"
|
|
FileUtils.mkdir_p "#{CREW_DEST_PREFIX}/include/phobos"
|
|
FileUtils.mkdir_p "#{CREW_DEST_PREFIX}/include/dmd/druntime"
|
|
FileUtils.install 'dmd/generated/linux/release/64/dmd', "#{CREW_DEST_PREFIX}/bin", mode: 0o755
|
|
FileUtils.cp_r 'dmd/druntime/import', "#{CREW_DEST_PREFIX}/include/dmd/druntime"
|
|
FileUtils.install 'dmd.conf', "#{CREW_DEST_PREFIX}/etc", mode: 0o644
|
|
FileUtils.cp_r 'dmd/compiler/docs/man/man5', CREW_DEST_MAN_PREFIX
|
|
Dir.chdir 'dmd/generated/linux/release/64/host_dmd-2.095.0/dmd2/man/man1' do
|
|
FileUtils.install 'dmd.1', "#{CREW_DEST_MAN_PREFIX}/man1", mode: 0o644
|
|
end
|
|
Dir.chdir 'phobos/generated/linux/release/64' do
|
|
libraries = %w[libphobos2.a libphobos2.so libphobos2.so.0.102 libphobos2.so.0.102.1]
|
|
FileUtils.install libraries, CREW_DEST_LIB_PREFIX, mode: 0o644
|
|
end
|
|
FileUtils.cp_r ['phobos/etc', 'phobos/std'], "#{CREW_DEST_PREFIX}/include/phobos"
|
|
Dir.chdir 'tools/generated/linux/64' do
|
|
executables = %w[catdoc changed checkwhitespace contributors detab dget tolf updatecopyright]
|
|
FileUtils.install executables, "#{CREW_DEST_PREFIX}/bin", mode: 0o755
|
|
end
|
|
end
|
|
end
|