Sha256: 5187855594ee4357ba529e4f70659fd935d490bee2af728ea3988cf9efabf4aa

Contents?: true

Size: 1.38 KB

Versions: 7

Compression:

Stored size: 1.38 KB

Contents

#!rake

# C extension constants
EXT_MAKEFILE       = EXTDIR + 'Makefile'
EXT_SOURCES        = FileList[ EXTDIR + '*.c' ]
EXT_SO             = EXTDIR + "bluecloth_ext.#{CONFIG['DLEXT']}"

GEMSPEC.extra_rdoc_files << 'LICENSE.discount'
DOCFILES << 'LICENSE.discount'


#####################################################################
###	T A S K S
#####################################################################

# Make both the default task and the spec task depend on building the extension
task :local => :build
task :spec => :build
namespace :spec do
	task :doc   => [ :build ]
	task :quiet => [ :build ]
	task :html  => [ :build ]
	task :text  => [ :build ]
end

desc "Make the Makefile for the C extension"
file EXT_MAKEFILE.to_s => EXT_SOURCES do
	log "Configuring BlueCloth C extension"
	in_subdirectory( EXTDIR ) do
		ruby 'extconf.rb'
	end
end
CLOBBER.include( EXTDIR + 'mkmf.log', EXTDIR + 'conftest.dSYM', EXT_SO )

desc "Build the C extension"
task :build => EXT_SO
file EXT_SO => [ EXT_MAKEFILE.to_s, *EXT_SOURCES ] do
	in_subdirectory( EXTDIR ) do
		sh 'make'
	end
end

desc "Rebuild the C extension"
task :rebuild => [ :clobber, :build ]


task :clean do
	if EXT_MAKEFILE.exist?
		in_subdirectory( EXTDIR ) do
			sh 'make clean'
		end
	end
end	

task :clobber do
	if EXT_MAKEFILE.exist?
		in_subdirectory( EXTDIR ) do
			sh 'make distclean'
		end
	end
end	
CLOBBER.include( EXT_MAKEFILE )

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
bluecloth-2.0.5-x86-mingw32 Rakefile.local
bluecloth-2.0.0 Rakefile.local
bluecloth-2.0.1 Rakefile.local
bluecloth-2.0.2 Rakefile.local
bluecloth-2.0.3 Rakefile.local
bluecloth-2.0.4 Rakefile.local
bluecloth-2.0.5 Rakefile.local