summaryrefslogtreecommitdiff
path: root/ext/dl/callback/extconf.rb
diff options
context:
space:
mode:
authornaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2010-02-25 22:49:20 +0000
committernaruse <naruse@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2010-02-25 22:49:20 +0000
commit59e4e93ef7b6b7f1536e3c56374cc6b8d74b5d28 (patch)
tree8ef0ee021c12e0ff884aaa2cc963845ab61fa41e /ext/dl/callback/extconf.rb
parent9d818a221ec86fb15bfe696995829807be49a1da (diff)
* ext/dl: revert dl with libffi because it can't run on mswin now.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@26764 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/dl/callback/extconf.rb')
-rw-r--r--ext/dl/callback/extconf.rb14
1 files changed, 14 insertions, 0 deletions
diff --git a/ext/dl/callback/extconf.rb b/ext/dl/callback/extconf.rb
new file mode 100644
index 00000000000..6c3387670d6
--- /dev/null
+++ b/ext/dl/callback/extconf.rb
@@ -0,0 +1,14 @@
+require 'mkmf'
+
+if compiled?("dl")
+ callbacks = (0..8).map{|i| "callback-#{i}"}.unshift("callback")
+ callback_srcs = callbacks.map{|basename| "#{basename}.c"}
+ callback_objs = callbacks.map{|basename| "#{basename}.o"}
+
+ $distcleanfiles << '$(SRCS)'
+ $srcs = callback_srcs
+ $objs = callback_objs
+ $INCFLAGS << " -I$(srcdir)/.."
+
+ create_makefile("dl/callback")
+end