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 30 31 32 33 34 35 36 37 38
|
#!/usr/bin/make -f
RUBY_ARCHDIR=$(strip $(shell ruby -rrbconfig -e 'puts Config::CONFIG["archdir"]'))
build:
dh build --until dh_auto_configure
(cd ext && ruby extconf.rb)
make -C ext
dh build --after dh_auto_build
clean:
([ -f ext/Makefile ] && make -C ext clean) || true
rm -f ext/ruby_prof.so
rm -f ext/ruby_prof.o
rm -f ext/Makefile ext/mkmf.log
dh clean
install: build
dh install --until dh_auto_install
mkdir -p debian/ruby-prof/$(RUBY_ARCHDIR)
mkdir -p debian/ruby-prof/usr/bin
cp -r lib/ruby-prof debian/ruby-prof/usr/lib/ruby/1.8
cp lib/*.rb debian/ruby-prof/usr/lib/ruby/1.8
chmod a-x debian/ruby-prof/usr/lib/ruby/1.8/ruby-prof/*.rb
cp bin/ruby-prof debian/ruby-prof/usr/bin
cp ext/ruby_prof.so debian/ruby-prof/$(RUBY_ARCHDIR)
mkdir -p debian/ruby-prof/usr/share/doc/ruby-prof
cp CHANGES debian/ruby-prof/usr/share/doc/ruby-prof/changelog
dh install --after dh_auto_install
binary-arch: install
dh binary-arch
binary-indep: install
dh binary-indep
binary: binary-arch binary-indep
|