-
Notifications
You must be signed in to change notification settings - Fork 6
/
bson_ext.patch
29 lines (27 loc) · 986 Bytes
/
bson_ext.patch
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
--- bson_ext/Rakefile.mitre Fri Feb 03 16:00:52 2012
+++ bson_ext/Rakefile Fri Feb 03 17:19:40 2012
@@ -6,6 +6,7 @@ require 'rake'
require 'rake/testtask'
require 'rake/gempackagetask'
require 'rbconfig'
+require 'rake/extensiontask'
include Config
ENV['TEST_MODE'] = 'TRUE'
@@ -13,6 +14,18 @@ task :java do
Rake::Task['build:java'].invoke
Rake::Task['test:ruby'].invoke
end
+
+# TLT: Add tasks for rake-compiler to be able to build native gem.
+bson_ext_spec = Gem::Specification.load('bson_ext.gemspec')
+Gem::PackageTask.new(bson_ext_spec) do |pkg|
+end
+Rake::ExtensionTask.new do |ext|
+ ext.name = 'cbson' # name of the extension
+ ext.ext_dir = 'ext/cbson' # location of extension files
+ ext.lib_dir = 'ext/bson_ext' # put binaries into this folder
+ ext.gem_spec = bson_ext_spec # specify which gem specification to use
+end
+# TLT: End of tasks added for popHealth
namespace :build do
desc "Build the java extensions."