ext/congruence_solver/extconf.rb in congruence_solver-0.2.0 vs ext/congruence_solver/extconf.rb in congruence_solver-0.3.0
- old
+ new
@@ -1,4 +1,29 @@
require "mkmf"
+EXT_H = %w[
+ arith_utils.h
+ congruences.h
+ prime_gen.h
+]
-create_makefile "congruence_solver"
+EXT_C = %w[
+ arith_utils.c
+ congruence_solver.c
+ congruences.c
+ prime_gen.c
+]
+
+
+EXT_H.each do |fname|
+ unless File::exist? fname
+ raise "Ext header #{fname} does not exist in #{Dir::pwd}"
+ end
+end
+
+EXT_C.each do |fname|
+ unless File::exist? fname
+ raise "Ext file #{fname} does not exist in #{Dir::pwd}"
+ end
+end
+
+create_makefile "congruence_solver/congruence_solver"
\ No newline at end of file