summaryrefslogtreecommitdiffstats
path: root/extconf.rb
diff options
context:
space:
mode:
authorguy Decoux <ts@moulon.inra.fr>2009-02-28 20:08:24 +0100
committerguy Decoux <ts@moulon.inra.fr>2009-02-28 20:08:24 +0100
commita181d44ee4b78d7e016cf5b9e8fd5591723615bd (patch)
treeb78f0d2b978a9df55acd5dfd222ceebfcbc50c03 /extconf.rb
parentddd4bfbddf5d2972f5eaf47bc6b89d154203f45f (diff)
downloadmmap-ruby-a181d44ee4b78d7e016cf5b9e8fd5591723615bd.zip
mmap-ruby-a181d44ee4b78d7e016cf5b9e8fd5591723615bd.tar.gz
mmap-0.1.8
Diffstat (limited to 'extconf.rb')
-rw-r--r--extconf.rb22
1 files changed, 22 insertions, 0 deletions
diff --git a/extconf.rb b/extconf.rb
index 73d0ce7..07c59ad 100644
--- a/extconf.rb
+++ b/extconf.rb
@@ -14,7 +14,29 @@ unknown: $(DLLIB)
\t@echo "main() {}" > /tmp/a.c
\t$(CC) -static /tmp/a.c $(OBJS) $(CPPFLAGS) $(DLDFLAGS) -lruby #{CONFIG["LIBS"]} $(LIBS) $(LOCAL_LIBS)
\t@-rm /tmp/a.c a.out
+
+%.html: %.rd
+\trd2 $< > ${<:%.rd=%.html}
+
EOT
+ make.print "HTML = mmap.html"
+ docs = Dir['docs/*.rd']
+ docs.each {|x| make.print " \\\n\t#{x.sub(/\.rd$/, '.html')}" }
+ make.print "\n\nRDOC = mmap.rd"
+ docs.each {|x| make.print " \\\n\t#{x}" }
+ make.puts
+ make.print <<-EOF
+
+rdoc: docs/doc/index.html
+
+docs/doc/index.html: $(RDOC)
+\t@-(cd docs; b.rb mmap; rdoc mmap.rb)
+
+rd2: html
+
+html: $(HTML)
+
+ EOF
ensure
make.close
end