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
1c859c6d
Commit
1c859c6d
authored
May 09, 2017
by
Matthew Downey
Committed by
GitHub
May 09, 2017
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' into naming
parents
476918d5
d2661c66
Changes
10
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
120 additions
and
33 deletions
+120
-33
crew
crew
+14
-7
lib/package.rb
lib/package.rb
+24
-4
packages/bc.rb
packages/bc.rb
+6
-4
packages/ed.rb
packages/ed.rb
+23
-0
packages/libffi.rb
packages/libffi.rb
+7
-5
packages/libpipeline.rb
packages/libpipeline.rb
+2
-2
packages/libtasn1.rb
packages/libtasn1.rb
+7
-3
packages/lzip.rb
packages/lzip.rb
+21
-0
packages/p11kit.rb
packages/p11kit.rb
+8
-2
packages/xzutils.rb
packages/xzutils.rb
+8
-6
No files found.
crew
View file @
1c859c6d
...
...
@@ -173,7 +173,9 @@ def download
url
=
@pkg
.
get_url
(
@device
[
:architecture
])
source
=
@pkg
.
is_source?
(
@device
[
:architecture
])
if
!
source
if
!
url
abort
"No precompiled binary for
#{
@device
[
:architecture
]
}
nor source is available."
elsif
!
source
puts
"Precompiled binary available, downloading..."
elsif
@pkg
.
build_from_source
puts
"Downloading source..."
...
...
@@ -297,17 +299,22 @@ def resolveDependencies
@source_package
=
0
def
push_dependencies
if
@pkg
.
binary_url
&&
@pkg
.
binary_url
.
has_key?
(
@device
[
:architecture
])
@check_deps
=
@pkg
.
dependencies
if
@pkg
.
is_binary?
(
@device
[
:architecture
])
# retrieve name of dependencies that doesn't contain :build tag
@check_deps
=
@pkg
.
dependencies
.
select
{
|
k
,
v
|
!
v
.
include?
(
:build
)}.
map
{
|
k
,
v
|
k
}
elsif
@pkg
.
is_fake?
# retrieve name of all dependencies
@check_deps
=
@pkg
.
dependencies
.
map
{
|
k
,
v
|
k
}
else
# Use source dependencies
@check_deps
=
@pkg
.
dependencies
# retrieve name of all dependencies
@check_deps
=
@pkg
.
dependencies
.
map
{
|
k
,
v
|
k
}
# count the number of source packages to add buildessential into dependencies later
@source_package
+=
1
end
if
@check_deps
&&
!
@check_deps
.
empty?
@dependencies
.
unshift
@check_deps
@
pkg
.
dependencie
s
.
each
do
|
dep
|
@
check_dep
s
.
each
do
|
dep
|
search
dep
,
true
push_dependencies
end
...
...
lib/package.rb
View file @
1c859c6d
...
...
@@ -2,16 +2,36 @@ require 'package_helpers'
class
Package
property
:version
,
:binary_url
,
:binary_sha1
,
:source_url
,
:source_sha1
,
:is_fake
class
<<
self
attr_reader
:
dependencies
,
:
is_fake
attr_reader
:is_fake
attr_accessor
:name
,
:in_build
,
:build_from_source
attr_accessor
:in_upgrade
end
def
self
.
dependencies
# Not sure how to initialize instance variable of not constructed class.
# Therefore, initialize it in reader function.
@dependencies
=
Hash
.
new
unless
@dependencies
@dependencies
end
def
self
.
depends_on
(
dependency
=
nil
)
@dependencies
=
[]
unless
@dependencies
@dependencies
=
Hash
.
new
unless
@dependencies
if
dependency
@dependencies
<<
dependency
# add element in "[ name, [ tag1, tag2, ... ] ]" format
if
dependency
.
is_a?
(
Hash
)
if
dependency
.
first
[
1
].
is_a?
(
Array
)
# parse "depends_on name => [ tag1, tag2 ]"
@dependencies
.
store
(
dependency
.
first
[
0
],
dependency
.
first
[
1
])
else
# parse "depends_on name => tag"
@dependencies
.
store
(
dependency
.
first
[
0
],
[
dependency
.
first
[
1
]
])
end
else
# parse "depends_on name"
@dependencies
.
store
(
dependency
,
[])
end
end
@dependencies
end
...
...
packages/bc.rb
View file @
1c859c6d
require
'package'
class
Bc
<
Package
version
'1.0
6-
1'
source_url
'http
://ftp.gnu.org/gnu/bc/bc-1.06
.tar.gz'
source_sha1
'
c8f258a7355b40a485007c40865480349c157292
'
version
'1.0
7.
1'
source_url
'http
s://ftp.gnu.org/gnu/bc/bc-1.07.1
.tar.gz'
source_sha1
'
b4475c6d66590a5911d30f9747361db47231640a
'
depends_on
'readline'
depends_on
'flex'
depends_on
'ed'
def
self
.
build
system
"./configure"
system
"./configure"
,
"--with-readline"
system
"make"
end
...
...
packages/ed.rb
0 → 100644
View file @
1c859c6d
require
'package'
class
Ed
<
Package
version
'1.14.2'
source_url
'http://ftpmirror.gnu.org/ed/ed-1.14.2.tar.lz'
source_sha1
'3e8aa331ffbc929884107ff3f8fbd76d01252277'
# only lz archive is available for ed and it requires lzip.
depends_on
'lzip'
def
self
.
build
system
"./configure"
system
"make"
end
def
self
.
install
system
"make"
,
"DESTDIR=
#{
CREW_DEST_DIR
}
"
,
"install"
end
def
self
.
check
system
"make"
,
"check"
end
end
packages/libffi.rb
View file @
1c859c6d
require
'package'
class
Libffi
<
Package
version
'3.2.1'
version
'3.2.1
-1
'
source_url
'ftp://sourceware.org/pub/libffi/libffi-3.2.1.tar.gz'
source_sha1
'280c265b789e041c02e5c97815793dfc283fb1e6'
depends_on
'autoconf'
depends_on
'automake'
def
self
.
build
system
"./configure"
,
"--disable-debug"
,
"--disable-dependency-tracking"
system
"./configure"
,
"--enable-shared"
,
"--disable-static"
,
"--with-pic"
,
"--disable-debug"
,
"--disable-dependency-tracking"
system
"make"
end
def
self
.
install
system
"make"
,
"DESTDIR=
#{
CREW_DEST_DIR
}
"
,
"install"
end
def
self
.
check
# system "make check" # DejaGNU required
end
end
packages/libpipeline.rb
View file @
1c859c6d
require
'package'
class
Libpipeline
<
Package
version
'1.4.1'
version
'1.4.1
-1
'
source_url
'https://download.savannah.gnu.org/releases/libpipeline/libpipeline-1.4.1.tar.gz'
source_sha1
'b31cc955f22b1aa4545dc8d00ddbde831936594f'
def
self
.
build
system
'./configure'
system
'./configure'
,
'--disable-static'
,
'--enable-shared'
,
'--with-pic'
system
'make'
end
...
...
packages/libtasn1.rb
View file @
1c859c6d
require
'package'
class
Libtasn1
<
Package
version
'4.10'
source_url
'http://ftp
.snt.utwente.nl/pub/software/gnu
/libtasn1/libtasn1-4.10.tar.gz'
version
'4.10
-1
'
source_url
'http://ftp
mirror.gnu.org
/libtasn1/libtasn1-4.10.tar.gz'
source_sha1
'c7b36fa50866bbc889f7503c7fd1e9f9d7c52a64'
def
self
.
build
system
'./configure --prefix=/usr/local'
system
"./configure"
,
"--enable-shared"
,
"--disable-static"
,
"--with-pic"
,
"--prefix=/usr/local"
system
"make"
end
def
self
.
install
system
"make"
,
"DESTDIR=
#{
CREW_DEST_DIR
}
"
,
"install"
end
def
self
.
check
system
"make"
,
"check"
end
end
packages/lzip.rb
0 → 100644
View file @
1c859c6d
require
'package'
class
Lzip
<
Package
version
'1.19'
source_url
'http://download.savannah.gnu.org/releases/lzip/lzip-1.19.tar.gz'
source_sha1
'c6042a786b69e3209112fa991806e2e7e0ba5f07'
def
self
.
build
# default -O2 cause run-time segmentation fault on armv7l
system
"./configure"
,
"CXXFLAGS=-Wall -W -O1"
system
"make"
end
def
self
.
install
system
"make"
,
"DESTDIR=
#{
CREW_DEST_DIR
}
"
,
"install"
end
def
self
.
check
system
"make"
,
"check"
end
end
packages/p11kit.rb
View file @
1c859c6d
require
'package'
class
P11kit
<
Package
version
'0.23.2'
version
'0.23.2
-1
'
source_url
'https://p11-glue.freedesktop.org/releases/p11-kit-0.23.2.tar.gz'
source_sha1
'4da0d7b47935b6cb0f321dd00358b063ae42df71'
...
...
@@ -9,11 +9,17 @@ class P11kit < Package
depends_on
'libtasn1'
def
self
.
build
system
'./configure --prefix=/usr/local'
system
"./configure"
,
"--enable-shared"
,
"--disable-static"
,
"--with-pic"
,
"--prefix=/usr/local"
system
"make"
end
def
self
.
install
system
"make"
,
"DESTDIR=
#{
CREW_DEST_DIR
}
"
,
"install"
end
def
self
.
check
# Doesn't perform tests since 2 out of 45 fail as
# reported in https://bugs.freedesktop.org/show_bug.cgi?id=95366
# system "make", "check"
end
end
packages/xzutils.rb
View file @
1c859c6d
require
'package'
class
Xzutils
<
Package
version
'5.2.3
'
source_url
'http://tukaani.org/xz/xz-5.2.3.tar.gz'
source_sha1
'529638eec3597e429cc54c74551ac0a89169e841'
version
'5.2.3
-1'
source_url
'http://tukaani.org/xz/xz-5.2.3.tar.gz'
source_sha1
'529638eec3597e429cc54c74551ac0a89169e841'
def
self
.
build
system
"./configure"
,
"--prefix=/usr/local"
,
"--disable-docs"
system
"./configure"
,
"--prefix=/usr/local"
,
"--disable-docs"
,
"--enable-shared"
,
"--disable-static"
,
"--with-pic"
system
"make"
end
def
self
.
install
system
"make"
,
"DESTDIR=
#{
CREW_DEST_DIR
}
"
,
"install"
end
def
self
.
check
system
"make"
,
"check"
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