diff options
author | Eric Wong <normalperson@yhbt.net> | 2009-09-03 19:23:43 -0700 |
---|---|---|
committer | Eric Wong <normalperson@yhbt.net> | 2009-09-03 19:23:43 -0700 |
commit | af12d387069d017494daa23534fa7f87aea9ff3b (patch) | |
tree | d0577fe7486f711d7286595c0ebd4494ef6152f4 | |
parent | b7c6846e317b0f2bfe4807aab34524c2a633947c (diff) | |
download | clogger-af12d387069d017494daa23534fa7f87aea9ff3b.tar.gz |
This is useful for testing the pure Ruby version in case clogger_ext is already installed on your system.
-rw-r--r-- | GNUmakefile | 2 | ||||
-rw-r--r-- | lib/clogger.rb | 1 |
2 files changed, 2 insertions, 1 deletions
diff --git a/GNUmakefile b/GNUmakefile index a9bf2d8..b57c947 100644 --- a/GNUmakefile +++ b/GNUmakefile @@ -25,7 +25,7 @@ test-ext: ext/clogger_ext/clogger.$(DLEXT) $(ruby) -Iext/clogger_ext:lib test/test_clogger.rb test-pure: - $(ruby) -Ilib test/test_clogger.rb + CLOGGER_PURE=t $(ruby) -Ilib test/test_clogger.rb test: test-ext test-pure diff --git a/lib/clogger.rb b/lib/clogger.rb index 7665992..fbcd220 100644 --- a/lib/clogger.rb +++ b/lib/clogger.rb @@ -131,6 +131,7 @@ end require 'clogger/format' begin + raise LoadError if ENV['CLOGGER_PURE'] require 'clogger_ext' rescue LoadError require 'clogger/pure' |