Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
chromebrew
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
chromebrew
Commits
ae8752e6
Commit
ae8752e6
authored
Feb 03, 2018
by
Daniel Kozak
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add dlang support (ldc2,ldmd2,dub)
parent
66b6eebd
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
89 additions
and
0 deletions
+89
-0
packages/dub.rb
packages/dub.rb
+26
-0
packages/ldc.rb
packages/ldc.rb
+40
-0
packages/libconfig.rb
packages/libconfig.rb
+23
-0
No files found.
packages/dub.rb
0 → 100644
View file @
ae8752e6
require
'package'
class
Dub
<
Package
description
'Developer package manager for D programming language'
homepage
'https://github.com/D-Programming-Language/dub'
version
'1.7.1'
source_url
'https://github.com/dlang/dub/archive/v1.7.1.tar.gz'
source_sha256
'baa8c533f59d83f74e89c06f5ec7e52daf3becb227c7177a9eeab7159ba86dbc'
binary_url
({
})
binary_sha256
({
})
depends_on
'ldc'
def
self
.
build
system
"echo
\"
module dub.version_;
\"
> source/dub/version_.d"
system
"echo 'enum dubVersion =
\"
1.7.1
\"
;' >> source/dub/version_.d"
system
"ldmd2 -ofbin/dub -w -O -g -version=DubUseCurl -Isource -L-lcurl @build-files.txt"
end
def
self
.
install
system
"install"
,
"-Dm755"
,
"bin/dub"
,
"
#{
CREW_DEST_PREFIX
}
/bin/dub"
end
end
packages/ldc.rb
0 → 100644
View file @
ae8752e6
require
'package'
class
Ldc
<
Package
# The first character of the class name must be upper case
description
'D language compiler using LLVM.'
homepage
'https://github.com/ldc-developers/ldc'
version
'1.7.0'
source_url
'https://github.com/ldc-developers/ldc/releases/download/v1.7.0/ldc-1.7.0-src.tar.gz'
source_sha256
'7cd46140ca3e4ca0d52c352e5b694d4d5336898ed4f02c3e18e0eafd69dd18bd'
binary_url
({
})
binary_sha256
({
})
depends_on
'llvm'
depends_on
'curl'
depends_on
'gcc'
depends_on
'ncurses'
depends_on
'zlibpkg'
depends_on
'libconfig'
=>
:build
depends_on
'cmake'
=>
:build
depends_on
'libedit'
=>
:build
def
self
.
build
# the steps required to build the package
system
"mkdir"
,
"build"
system
"curl -L https://github.com/ldc-developers/ldc/releases/download/v0.17.5/{ldc-0.17.5-src.tar.gz} -o
\"
#1
\"
"
abort
'Checksum mismatch. :/ Try again.'
.
lightred
unless
Digest
::
SHA256
.
hexdigest
(
File
.
read
(
'ldc-0.17.5-src.tar.gz'
)
)
==
'7aa540a135f9fa1ee9722cad73100a8f3600a07f9a11d199d8be68887cc90008'
system
"tar xzf ldc-0.17.5-src.tar.gz -C build"
system
"cmake"
,
"-Bbuild/ldc-0.17.5-src"
,
"-Hbuild/ldc-0.17.5-src"
system
"make"
,
"-C"
,
"build/ldc-0.17.5-src"
,
"-j
#{
CREW_NPROC
}
"
system
"cmake"
,
"-DCMAKE_BUILD_TYPE=Release"
,
"-DCMAKE_SKIP_RPATH=ON"
,
"-DBUILD_SHARED_LIBS=BOTH"
,
"-DLDC_WITH_LLD=OFF"
,
"-DD_COMPILER=build/ldc-0.17.5-src/bin/ldmd2"
,
"-DCMAKE_INSTALL_PREFIX=
#{
CREW_PREFIX
}
"
,
"-Bbuild"
,
"-H."
system
"make"
,
"-C"
,
"build"
,
"-j
#{
CREW_NPROC
}
"
end
def
self
.
install
# the steps required to install the package
system
"make"
,
"-C"
,
"build"
,
"DESTDIR=
#{
CREW_DEST_DIR
}
"
,
"install"
end
end
packages/libconfig.rb
0 → 100644
View file @
ae8752e6
require
'package'
class
Libconfig
<
Package
description
'C/C++ Configuration File Library.'
homepage
'https://hyperrealm.github.io/libconfig/'
version
'1.7.2'
source_url
'https://hyperrealm.github.io/libconfig/dist/libconfig-1.7.2.tar.gz'
source_sha256
'7c3c7a9c73ff3302084386e96f903eb62ce06953bb1666235fac74363a16fad9'
binary_url
({
})
binary_sha256
({
})
def
self
.
build
system
"./configure --prefix=
#{
CREW_PREFIX
}
--libdir=
#{
CREW_LIB_PREFIX
}
"
system
"make"
end
def
self
.
install
system
"make"
,
"DESTDIR=
#{
CREW_DEST_DIR
}
"
,
"install"
end
end
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment