Skip to content

Commit 83fd80f

Browse files
committed
Generalize the FFI import script to also import lib/truffle/ffi
1 parent 0271493 commit 83fd80f

File tree

2 files changed

+25
-12
lines changed

2 files changed

+25
-12
lines changed

tool/import-ffi-spec.sh

Lines changed: 0 additions & 12 deletions
This file was deleted.

tool/import-ffi.sh

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
#!/usr/bin/env bash
2+
3+
set -x
4+
set -e
5+
6+
repo="../../ffi"
7+
8+
# lib/
9+
rm -rf lib/truffle/ffi
10+
cp -R ../../ffi/lib/ffi lib/truffle
11+
12+
# Keep the empty pointer.rb file, these methods are already defined in core
13+
# and they need to be in core as there are usages in core.
14+
git checkout lib/truffle/ffi/pointer.rb
15+
16+
# spec/
17+
rm -rf spec/ffi
18+
cp -R "$repo/spec/ffi" spec
19+
20+
# Keep the Gemfile files
21+
git checkout spec/ffi/Gemfile spec/ffi/Gemfile.lock
22+
23+
24+
# Remove unused files
25+
rm -rf spec/ffi/embed-test

0 commit comments

Comments
 (0)