]> git.mdlowis.com Git - projs/libcds.git/commitdiff
hopefully fix CI?
authorMichael D. Lowis <mike@mdlowis.com>
Sat, 30 Aug 2014 00:11:10 +0000 (20:11 -0400)
committerMichael D. Lowis <mike@mdlowis.com>
Sat, 30 Aug 2014 00:11:10 +0000 (20:11 -0400)
Rakefile

index 1d4d432ac1477ccb40c39253e1c3da668ad00153..92c01032dd6ae4bab61f1d9464bab28529df2c2e 100644 (file)
--- a/Rakefile
+++ b/Rakefile
@@ -35,7 +35,7 @@ at_exit { Env.process; TestEnv.process}
 #------------------------------------------------------------------------------
 # Main Build Targets
 #------------------------------------------------------------------------------
-task :default => [:test, :build]
+task :default => [:test, :coverage, :build]
 
 desc "Build the C Data Structures static library"
 task :build do
@@ -59,9 +59,10 @@ task :coverage => [:test] do
         obj  = gcno.ext('o')
         path = File.dirname(obj)
         gcov = File.basename(obj).ext('c.gcov')
-        sh *['gcov', '-abc', obj]
-        FileUtils.cp("./#{gcov}","#{path}/#{gcov}")
-        FileUtils.rm(gcov)
+        if File.exist?(gcno.ext('gcda'))
+            sh *['gcov', '-a', '-b', '-c', obj]
+            FileUtils.mv("./#{gcov}","#{path}/#{gcov}")
+        end
     end
 end