Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
R
ruby-build
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
OpenEdx
ruby-build
Commits
953225e8
Commit
953225e8
authored
Apr 05, 2014
by
Mislav Marohnić
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'avoid-sed-regexp'
parents
bd8692af
a4c3dbc5
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
54 additions
and
1 deletions
+54
-1
bin/ruby-build
+3
-1
test/build.bats
+51
-0
No files found.
bin/ruby-build
View file @
953225e8
...
@@ -592,7 +592,9 @@ fix_rbx_gem_binstubs() {
...
@@ -592,7 +592,9 @@ fix_rbx_gem_binstubs() {
for
file
in
"
$gemdir
"
/
*
;
do
for
file
in
"
$gemdir
"
/
*
;
do
binstub
=
"
${
bindir
}
/
${
file
##*/
}
"
binstub
=
"
${
bindir
}
/
${
file
##*/
}
"
rm
-f
"
$binstub
"
rm
-f
"
$binstub
"
sed
-E
"s:^#
\!
.+:#
\!
${
bindir
}
/ruby:"
<
"
$file
"
>
"
$binstub
"
{
echo
"#!
${
bindir
}
/ruby"
cat
"
$file
"
}
>
"
$binstub
"
chmod +x
"
$binstub
"
chmod +x
"
$binstub
"
done
done
rm
-rf
"
$gemdir
"
rm
-rf
"
$gemdir
"
...
...
test/build.bats
View file @
953225e8
...
@@ -386,6 +386,57 @@ bundle exec rake install
...
@@ -386,6 +386,57 @@ bundle exec rake install
OUT
OUT
}
}
@test "fixes rbx binstubs" {
executable "${RUBY_BUILD_CACHE_PATH}/rubinius-2.0.0/gems/bin/rake" <<OUT
#!rbx
puts 'rake'
OUT
executable "${RUBY_BUILD_CACHE_PATH}/rubinius-2.0.0/gems/bin/irb" <<OUT
#!rbx
print '>>'
OUT
cached_tarball "rubinius-2.0.0" bin/ruby
stub bundle '--version : echo 1' true
stub rake \
'--version : echo 1' \
"install : mkdir -p '$INSTALL_ROOT'; cp -fR . '$INSTALL_ROOT'"
run_inline_definition <<DEF
install_package "rubinius-2.0.0" "http://releases.rubini.us/rubinius-2.0.0.tar.gz" rbx
DEF
assert_success
unstub bundle
unstub rake
run ls "${INSTALL_ROOT}/bin"
assert_output <<OUT
irb
rake
ruby
OUT
run $(type -p greadlink readlink | head -1) "${INSTALL_ROOT}/gems/bin"
assert_success '../bin'
assert [ -x "${INSTALL_ROOT}/bin/rake" ]
run cat "${INSTALL_ROOT}/bin/rake"
assert_output <<OUT
#!${INSTALL_ROOT}/bin/ruby
#!rbx
puts 'rake'
OUT
assert [ -x "${INSTALL_ROOT}/bin/irb" ]
run cat "${INSTALL_ROOT}/bin/irb"
assert_output <<OUT
#!${INSTALL_ROOT}/bin/ruby
#!rbx
print '>>'
OUT
}
@test "JRuby build" {
@test "JRuby build" {
executable "${RUBY_BUILD_CACHE_PATH}/jruby-1.7.9/bin/jruby" <<OUT
executable "${RUBY_BUILD_CACHE_PATH}/jruby-1.7.9/bin/jruby" <<OUT
#!${BASH}
#!${BASH}
...
...
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