diff --git a/.gitignore b/.gitignore index bcc4e76..15fbfa9 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1 @@ -4ti2-1.3.2.tar.gz -4ti2_manual.pdf +4ti2-*.tar.gz diff --git a/4ti2-1.3.2-gcc47.patch b/4ti2-1.3.2-gcc47.patch deleted file mode 100644 index faedd2a..0000000 --- a/4ti2-1.3.2-gcc47.patch +++ /dev/null @@ -1,631 +0,0 @@ -diff -up 4ti2-1.3.2/src/groebner/CircuitMatrixAlgorithm.tpp.gcc47 4ti2-1.3.2/src/groebner/CircuitMatrixAlgorithm.tpp ---- 4ti2-1.3.2/src/groebner/CircuitMatrixAlgorithm.tpp.gcc47 2012-03-05 14:25:16.459407811 -0500 -+++ 4ti2-1.3.2/src/groebner/CircuitMatrixAlgorithm.tpp 2012-03-05 14:32:14.090831152 -0500 -@@ -152,23 +152,23 @@ CircuitMatrixAlgorithm::comput - ) - - // Find the next column. -- Index next_col = next_column(vs, remaining); -+ Index next_col = this->next_column(vs, remaining); - - int start = 0; int end = vs.get_number(); int middle; - // We sort the vectors into nonzeros and then zeros. -- sort_nonzeros(vs, start, end, rays, supps, pos_supps, neg_supps, next_col, middle); -+ this->sort_nonzeros(vs, start, end, rays, supps, pos_supps, neg_supps, next_col, middle); - int nonzero_start = start, nonzero_end = middle; - //int zero_start = middle, zero_end = end; - // We sort the nonzeros into rays and circuits. -- sort_rays(vs, nonzero_start, nonzero_end, rays, supps, pos_supps, neg_supps, middle); -+ this->sort_rays(vs, nonzero_start, nonzero_end, rays, supps, pos_supps, neg_supps, middle); - int ray_start = nonzero_start, ray_end = middle; - int cir_start = middle, cir_end = nonzero_end; - // We sort the rays into positives and then negatives. -- sort_positives(vs, ray_start, ray_end, supps, pos_supps, neg_supps, next_col, middle); -+ this->sort_positives(vs, ray_start, ray_end, supps, pos_supps, neg_supps, next_col, middle); - int pos_ray_start = ray_start, pos_ray_end = middle; - int neg_ray_start = middle, neg_ray_end = ray_end; - // We sort the circuits into positives and then negatives. -- sort_positives(vs, cir_start, cir_end, supps, pos_supps, neg_supps, next_col, middle); -+ this->sort_positives(vs, cir_start, cir_end, supps, pos_supps, neg_supps, next_col, middle); - int pos_cir_start = cir_start, pos_cir_end = middle; - int neg_cir_start = middle, neg_cir_end = cir_end; - -@@ -185,8 +185,8 @@ CircuitMatrixAlgorithm::comput - - // Switch the positive and negative supports, so that it is as if all - // vectors have a positive entry in the next column. -- switch_supports(neg_ray_start, neg_ray_end, pos_supps, neg_supps); -- switch_supports(neg_cir_start, neg_cir_end, pos_supps, neg_supps); -+ this->switch_supports(neg_ray_start, neg_ray_end, pos_supps, neg_supps); -+ this->switch_supports(neg_cir_start, neg_cir_end, pos_supps, neg_supps); - - matrix = orig_matrix; - int remaining_row = upper_triangle(matrix, remaining, 0); -@@ -212,15 +212,15 @@ CircuitMatrixAlgorithm::comput - rays.insert(rays.end(), vs.get_number()-previous_size, false); - - // Switch back the positive and negative supports. -- switch_supports(neg_ray_start, neg_ray_end, pos_supps, neg_supps); -- switch_supports(neg_cir_start, neg_cir_end, pos_supps, neg_supps); -+ this->switch_supports(neg_ray_start, neg_ray_end, pos_supps, neg_supps); -+ this->switch_supports(neg_cir_start, neg_cir_end, pos_supps, neg_supps); - - // Update the supp vectors for the next_col. -- update_supports(supps, next_col, nonzero_start, nonzero_end); -- update_supports(pos_supps, next_col, pos_ray_start, pos_ray_end); -- update_supports(pos_supps, next_col, pos_cir_start, pos_cir_end); -- update_supports(neg_supps, next_col, neg_ray_start, neg_ray_end); -- update_supports(neg_supps, next_col, neg_cir_start, neg_cir_end); -+ this->update_supports(supps, next_col, nonzero_start, nonzero_end); -+ this->update_supports(pos_supps, next_col, pos_ray_start, pos_ray_end); -+ this->update_supports(pos_supps, next_col, pos_cir_start, pos_cir_end); -+ this->update_supports(neg_supps, next_col, neg_ray_start, neg_ray_end); -+ this->update_supports(neg_supps, next_col, neg_cir_start, neg_cir_end); - - *out << "\r"; - *out << " Left = " << std::setw(3) << num_remaining; -diff -up 4ti2-1.3.2/src/groebner/CircuitSupportAlgorithm.tpp.gcc47 4ti2-1.3.2/src/groebner/CircuitSupportAlgorithm.tpp ---- 4ti2-1.3.2/src/groebner/CircuitSupportAlgorithm.tpp.gcc47 2012-03-05 14:21:20.103997937 -0500 -+++ 4ti2-1.3.2/src/groebner/CircuitSupportAlgorithm.tpp 2012-03-05 14:31:39.629208802 -0500 -@@ -188,23 +188,23 @@ CircuitSupportAlgorithm::compu - ) - - // Find the next column. -- Index next_col = next_column(vs, remaining); -+ Index next_col = this->next_column(vs, remaining); - - int start = 0; int end = vs.get_number(); int middle; - // We sort the vectors into nonzeros and then zeros. -- sort_nonzeros(vs, start, end, rays, supps, pos_supps, neg_supps, next_col, middle); -+ this->sort_nonzeros(vs, start, end, rays, supps, pos_supps, neg_supps, next_col, middle); - int nonzero_start = start, nonzero_end = middle; - //int zero_start = middle, zero_end = end; - // We sort the nonzeros into rays and circuits. -- sort_rays(vs, nonzero_start, nonzero_end, rays, supps, pos_supps, neg_supps, middle); -+ this->sort_rays(vs, nonzero_start, nonzero_end, rays, supps, pos_supps, neg_supps, middle); - int ray_start = nonzero_start, ray_end = middle; - int cir_start = middle, cir_end = nonzero_end; - // We sort the rays into positives and then negatives. -- sort_positives(vs, ray_start, ray_end, supps, pos_supps, neg_supps, next_col, middle); -+ this->sort_positives(vs, ray_start, ray_end, supps, pos_supps, neg_supps, next_col, middle); - int pos_ray_start = ray_start, pos_ray_end = middle; - int neg_ray_start = middle, neg_ray_end = ray_end; - // We sort the circuits into positives and the negatives. -- sort_positives(vs, cir_start, cir_end, supps, pos_supps, neg_supps, next_col, middle); -+ this->sort_positives(vs, cir_start, cir_end, supps, pos_supps, neg_supps, next_col, middle); - int pos_cir_start = cir_start, pos_cir_end = middle; - int neg_cir_start = middle, neg_cir_end = cir_end; - -@@ -233,8 +233,8 @@ CircuitSupportAlgorithm::compu - - // Switch the positive and negative supports, so that it is as if all - // vectors have a positive entry in the next column. -- switch_supports(neg_ray_start, neg_ray_end, pos_supps, neg_supps); -- switch_supports(neg_cir_start, neg_cir_end, pos_supps, neg_supps); -+ this->switch_supports(neg_ray_start, neg_ray_end, pos_supps, neg_supps); -+ this->switch_supports(neg_cir_start, neg_cir_end, pos_supps, neg_supps); - - //DEBUG_4ti2(*out << "Remaining row " << remaining_row << "\n";) - int previous_size = vs.get_number(); -@@ -258,19 +258,19 @@ CircuitSupportAlgorithm::compu - rays.insert(rays.end(), vs.get_number()-previous_size, false); - - // Switch back the positive and negative supports. -- switch_supports(neg_ray_start, neg_ray_end, pos_supps, neg_supps); -- switch_supports(neg_cir_start, neg_cir_end, pos_supps, neg_supps); -+ this->switch_supports(neg_ray_start, neg_ray_end, pos_supps, neg_supps); -+ this->switch_supports(neg_cir_start, neg_cir_end, pos_supps, neg_supps); - - // Update the supp vectors for the next_col. -- update_supports(supps, next_col, nonzero_start, nonzero_end); -- update_supports(pos_supps, next_col, pos_ray_start, pos_ray_end); -- update_supports(pos_supps, next_col, pos_cir_start, pos_cir_end); -- update_supports(pos_supps, col_map[next_col], neg_ray_start, neg_ray_end); -- update_supports(pos_supps, col_map[next_col], neg_cir_start, neg_cir_end); -- update_supports(neg_supps, next_col, neg_ray_start, neg_ray_end); -- update_supports(neg_supps, next_col, neg_cir_start, neg_cir_end); -- update_supports(neg_supps, col_map[next_col], pos_ray_start, pos_ray_end); -- update_supports(neg_supps, col_map[next_col], pos_cir_start, pos_cir_end); -+ this->update_supports(supps, next_col, nonzero_start, nonzero_end); -+ this->update_supports(pos_supps, next_col, pos_ray_start, pos_ray_end); -+ this->update_supports(pos_supps, next_col, pos_cir_start, pos_cir_end); -+ this->update_supports(pos_supps, col_map[next_col], neg_ray_start, neg_ray_end); -+ this->update_supports(pos_supps, col_map[next_col], neg_cir_start, neg_cir_end); -+ this->update_supports(neg_supps, next_col, neg_ray_start, neg_ray_end); -+ this->update_supports(neg_supps, next_col, neg_cir_start, neg_cir_end); -+ this->update_supports(neg_supps, col_map[next_col], pos_ray_start, pos_ray_end); -+ this->update_supports(neg_supps, col_map[next_col], pos_cir_start, pos_cir_end); - - *out << "\r"; - *out << " Left = " << std::setw(3) << num_remaining; -diff -up 4ti2-1.3.2/src/groebner/RayMatrixAlgorithm.tpp.gcc47 4ti2-1.3.2/src/groebner/RayMatrixAlgorithm.tpp ---- 4ti2-1.3.2/src/groebner/RayMatrixAlgorithm.tpp.gcc47 2008-11-14 21:08:37.000000000 -0500 -+++ 4ti2-1.3.2/src/groebner/RayMatrixAlgorithm.tpp 2012-03-05 14:28:04.450566861 -0500 -@@ -146,7 +146,7 @@ RayMatrixAlgorithm::compute1( - - // Find the next column. - int next_positive_count, next_negative_count, next_zero_count; -- Index next_col = next_column(vs, remaining, -+ Index next_col = this->next_column(vs, remaining, - next_positive_count, - next_negative_count, - next_zero_count); -@@ -161,7 +161,7 @@ RayMatrixAlgorithm::compute1( - ) - - // We sort the vectors into zeros, positives, then negatives. -- sort(vs, supports, next_col, next_zero_count, next_positive_count, -+ RayImplementation::sort(vs, supports, next_col, next_zero_count, next_positive_count, - next_negative_count); - - matrix = orig_matrix; -@@ -218,7 +218,7 @@ RayMatrixAlgorithm::compute1( - IndexSet::set_difference(supports[r2], r1_supp, temp_diff2); - if (temp_diff2.power_of_2()) - { -- create_new_vector(vs, supports, r1, r2, next_col, -+ this->create_new_vector(vs, supports, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - continue; -@@ -226,14 +226,14 @@ RayMatrixAlgorithm::compute1( - IndexSet::set_difference(r1_supp, supports[r2], temp_diff2); - if (temp_diff2.power_of_2()) - { -- create_new_vector(vs, supports, r1, r2, next_col, -+ this->create_new_vector(vs, supports, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - continue; - } - if (rank_check(matrix, temp_matrix, temp_diff, r1_rows)) - { -- create_new_vector(vs, supports, r1, r2, next_col, -+ this->create_new_vector(vs, supports, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - ++num_added; -@@ -351,7 +351,7 @@ RayMatrixAlgorithm::compute0( - { - // Find the next column. - int next_positive_count, next_negative_count, next_zero_count; -- Index next_col = next_column(vs, remaining, -+ Index next_col = this->next_column(vs, remaining, - next_positive_count, - next_negative_count, - next_zero_count); -@@ -366,7 +366,7 @@ RayMatrixAlgorithm::compute0( - ) - - // We sort the vectors into zeros, positives, then negatives. -- sort(vs, supports, next_col, next_zero_count, next_positive_count, -+ RayImplementation::sort(vs, supports, next_col, next_zero_count, next_positive_count, - next_negative_count); - - matrix = orig_matrix; -@@ -416,7 +416,7 @@ RayMatrixAlgorithm::compute0( - IndexSet::set_difference(supports[r2], r1_supp, temp_diff); - if (temp_diff.power_of_2()) - { -- create_new_vector(vs, supports, r1, r2, next_col, -+ this->create_new_vector(vs, supports, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - ++num_added; -@@ -442,7 +442,7 @@ RayMatrixAlgorithm::compute0( - IndexSet::set_difference(r1_supp, supports[r2], temp_diff2); - if (temp_diff2.power_of_2()) - { -- create_new_vector(vs, supports, r1, r2, next_col, -+ this->create_new_vector(vs, supports, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - ++num_one_diff_added; -@@ -452,7 +452,7 @@ RayMatrixAlgorithm::compute0( - - if (rank_check(matrix, temp_matrix, temp_diff, r1_rows)) - { -- create_new_vector(vs, supports, r1, r2, next_col, -+ this->create_new_vector(vs, supports, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - ++num_added; -@@ -468,7 +468,7 @@ RayMatrixAlgorithm::compute0( - IndexSet::set_difference(supports[r2], r1_supp, temp_diff); - if (temp_diff.power_of_2()) - { -- create_new_vector(vs, supports, r1, r2, next_col, -+ this->create_new_vector(vs, supports, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - ++num_added; -@@ -600,7 +600,7 @@ RayMatrixAlgorithm::compute2( - - // Find the next column. - int next_positive_count, next_negative_count, next_zero_count; -- Index next_col = next_column(vs, remaining, -+ Index next_col = this->next_column(vs, remaining, - next_positive_count, - next_negative_count, - next_zero_count); -@@ -615,7 +615,7 @@ RayMatrixAlgorithm::compute2( - ) - - // We sort the vectors into zeros, positives, then negatives. -- sort(vs, supports, fathers, zeros, next_col, next_zero_count, next_positive_count, -+ RayImplementation::sort(vs, supports, fathers, zeros, next_col, next_zero_count, next_positive_count, - next_negative_count); - - matrix = orig_matrix; -@@ -665,7 +665,7 @@ RayMatrixAlgorithm::compute2( - IndexSet::set_difference(supports[r2], r1_supp, temp_diff); - if (temp_diff.power_of_2()) - { -- create_new_vector(vs, supports, fathers, r1, r2, next_col, -+ this->create_new_vector(vs, supports, fathers, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - ++num_added; -@@ -689,7 +689,7 @@ RayMatrixAlgorithm::compute2( - { - if (fathers[r1] == r2 || fathers[r2] == r1) - { -- create_new_vector(vs, supports, fathers, r1, r2, next_col, -+ this->create_new_vector(vs, supports, fathers, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - //++num_fathers; -@@ -705,7 +705,7 @@ RayMatrixAlgorithm::compute2( - IndexSet::set_difference(r1_supp, supports[r2], temp_diff2); - if (temp_diff2.power_of_2()) - { -- create_new_vector(vs, supports, fathers, r1, r2, next_col, -+ this->create_new_vector(vs, supports, fathers, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - //++num_one_diff_added; -@@ -714,7 +714,7 @@ RayMatrixAlgorithm::compute2( - #endif - if (rank_check(matrix, temp_matrix, temp_diff, r1_rows)) - { -- create_new_vector(vs, supports, fathers, r1, r2, next_col, -+ this->create_new_vector(vs, supports, fathers, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - ++num_added; -@@ -730,7 +730,7 @@ RayMatrixAlgorithm::compute2( - IndexSet::set_difference(supports[r2], r1_supp, temp_diff); - if (temp_diff.power_of_2()) - { -- create_new_vector(vs, supports, fathers, r1, r2, next_col, -+ this->create_new_vector(vs, supports, fathers, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - ++num_added; -@@ -865,7 +865,7 @@ RayMatrixAlgorithm::compute3( - DEBUG_4ti2(unsigned long long int num_checks = 0;) - // Find the next column. - int next_positive_count, next_negative_count, next_zero_count; -- Index next_col = next_column(vs, remaining, -+ Index next_col = this->next_column(vs, remaining, - next_positive_count, - next_negative_count, - next_zero_count); -@@ -880,7 +880,7 @@ RayMatrixAlgorithm::compute3( - ) - - // We sort the vectors into zeros, positives, then negatives. -- sort(vs, supports, next_col, next_zero_count, next_positive_count, -+ RayImplementation::sort(vs, supports, next_col, next_zero_count, next_positive_count, - next_negative_count); - - DEBUG_4ti2(*out << "Rays:\n" << vs << "\n";) -@@ -944,7 +944,7 @@ RayMatrixAlgorithm::compute3( - IndexSet::set_difference(supports[r2], r1_supp, temp_diff); - if (temp_diff.power_of_2()) - { -- create_new_vector(vs, supports, r1, r2, next_col, -+ this->create_new_vector(vs, supports, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - DEBUG_4ti2(++num_one_diff_added;) -@@ -959,7 +959,7 @@ RayMatrixAlgorithm::compute3( - IndexSet::set_difference(r1_supp, supports[r2], temp_diff); - if (temp_diff.power_of_2()) - { -- create_new_vector(vs, supports, r1, r2, next_col, -+ this->create_new_vector(vs, supports, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - DEBUG_4ti2(++num_one_diff_added;) -@@ -984,7 +984,7 @@ RayMatrixAlgorithm::compute3( - IndexSet::set_difference(r1_supp, supports[r2], temp_diff2); - if (temp_diff2.power_of_2()) - { -- create_new_vector(vs, supports, r1, r2, next_col, -+ this->create_new_vector(vs, supports, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - DEBUG_4ti2(++num_one_diff_added;) -@@ -996,7 +996,7 @@ RayMatrixAlgorithm::compute3( - DEBUG_4ti2(++num_checks;) - if (rank_check(matrix, temp_matrix, temp_diff, r1_rows)) - { -- create_new_vector(vs, supports, r1, r2, next_col, -+ this->create_new_vector(vs, supports, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - DEBUG_4ti2(++num_added;) -@@ -1012,7 +1012,7 @@ RayMatrixAlgorithm::compute3( - IndexSet::set_difference(supports[r2], r1_supp, temp_diff); - if (temp_diff.power_of_2()) - { -- create_new_vector(vs, supports, r1, r2, next_col, -+ this->create_new_vector(vs, supports, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - DEBUG_4ti2(++num_one_diff_added;) -diff -up 4ti2-1.3.2/src/groebner/RaySupportAlgorithm.tpp.gcc47 4ti2-1.3.2/src/groebner/RaySupportAlgorithm.tpp ---- 4ti2-1.3.2/src/groebner/RaySupportAlgorithm.tpp.gcc47 2012-03-05 14:23:20.076683203 -0500 -+++ 4ti2-1.3.2/src/groebner/RaySupportAlgorithm.tpp 2012-03-05 14:28:38.437194415 -0500 -@@ -138,7 +138,7 @@ RaySupportAlgorithm::compute0( - - // Find the next column. - int next_positive_count, next_negative_count, next_zero_count; -- Index next_col = next_column(vs, remaining, -+ Index next_col = this->next_column(vs, remaining, - next_positive_count, - next_negative_count, - next_zero_count); -@@ -153,7 +153,7 @@ RaySupportAlgorithm::compute0( - ) - - // We sort the vectors into zeros, positives, then negatives. -- sort(vs, supports, next_col, next_zero_count, next_positive_count, -+ RayImplementation::sort(vs, supports, next_col, next_zero_count, next_positive_count, - next_negative_count); - - // Note that the tree needs the ordering of the current vectors to be -@@ -206,7 +206,7 @@ RaySupportAlgorithm::compute0( - IndexSet::set_difference(supports[r2], r1_supp, temp_diff); - if (temp_diff.power_of_2()) - { -- create_new_vector(vs, supports, r1, r2, next_col, -+ this->create_new_vector(vs, supports, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - ++num_added; -@@ -226,7 +226,7 @@ RaySupportAlgorithm::compute0( - ++num_support_checks; - if (!tree.dominated(temp_supp, r1, r2)) - { -- create_new_vector(vs, supports, r1, r2, next_col, -+ this->create_new_vector(vs, supports, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - ++num_added; -@@ -337,7 +337,7 @@ RaySupportAlgorithm::compute1( - - // Find the next column. - int next_positive_count, next_negative_count, next_zero_count; -- Index next_col = next_column(vs, remaining, -+ Index next_col = this->next_column(vs, remaining, - next_positive_count, - next_negative_count, - next_zero_count); -@@ -352,7 +352,7 @@ RaySupportAlgorithm::compute1( - ) - - // We sort the vectors into zeros, positives, then negatives. -- sort(vs, supports, next_col, next_zero_count, next_positive_count, -+ RayImplementation::sort(vs, supports, next_col, next_zero_count, next_positive_count, - next_negative_count); - - // Note that the tree needs the ordering of the current vectors to be -@@ -404,7 +404,7 @@ RaySupportAlgorithm::compute1( - IndexSet::set_difference(supports[r2], r1_supp, temp_diff); - if (temp_diff.power_of_2()) - { -- create_new_vector(vs, supports, r1, r2, next_col, -+ this->create_new_vector(vs, supports, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - ++num_added; -@@ -424,7 +424,7 @@ RaySupportAlgorithm::compute1( - zero_supp.set_union(supports[index]); - if (index >= r2_start && index < r2_finish) - { -- create_new_vector(vs, supports, r1, index, next_col, -+ this->create_new_vector(vs, supports, r1, index, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - ++num_added; -@@ -443,7 +443,7 @@ RaySupportAlgorithm::compute1( - ++num_support_checks; - if (!tree.dominated(temp_supp, r1, r2)) - { -- create_new_vector(vs, supports, r1, r2, next_col, -+ this->create_new_vector(vs, supports, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - ++num_added; -@@ -550,7 +550,7 @@ RaySupportAlgorithm::compute2( - - // Find the next column. - int next_positive_count, next_negative_count, next_zero_count; -- Index next_col = next_column(vs, remaining, -+ Index next_col = this->next_column(vs, remaining, - next_positive_count, - next_negative_count, - next_zero_count); -@@ -565,7 +565,7 @@ RaySupportAlgorithm::compute2( - ) - - // We sort the vectors into zeros, positives, then negatives. -- sort(vs, supports, next_col, next_zero_count, next_positive_count, -+ RayImplementation::sort(vs, supports, next_col, next_zero_count, next_positive_count, - next_negative_count); - - // Note that the tree needs the ordering of the current vectors to be -@@ -619,7 +619,7 @@ RaySupportAlgorithm::compute2( - IndexSet::set_difference(supports[r2], r1_supp, temp_diff); - if (temp_diff.power_of_2()) - { -- create_new_vector(vs, supports, r1, r2, next_col, -+ this->create_new_vector(vs, supports, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - ++num_added; -@@ -638,7 +638,7 @@ RaySupportAlgorithm::compute2( - zero_supp.set_union(supports[index]); - if (index >= r2_start && index < r2_finish) - { -- create_new_vector(vs, supports, r1, index, next_col, -+ this->create_new_vector(vs, supports, r1, index, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - ++num_added; -@@ -661,7 +661,7 @@ RaySupportAlgorithm::compute2( - ++num_support_checks; - if (!tree.dominated(temp_supp, r1, r2)) - { -- create_new_vector(vs, supports, r1, r2, next_col, -+ this->create_new_vector(vs, supports, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - ++num_added; -@@ -773,7 +773,7 @@ RaySupportAlgorithm::compute3( - - // Find the next column. - int next_positive_count, next_negative_count, next_zero_count; -- Index next_col = next_column(vs, remaining, -+ Index next_col = this->next_column(vs, remaining, - next_positive_count, - next_negative_count, - next_zero_count); -@@ -788,7 +788,7 @@ RaySupportAlgorithm::compute3( - ) - - // We sort the vectors into zeros, positives, then negatives. -- sort(vs, supports, next_col, next_zero_count, next_positive_count, -+ RayImplementation::sort(vs, supports, next_col, next_zero_count, next_positive_count, - next_negative_count); - - int original_size = vs.get_number(); -@@ -852,7 +852,7 @@ RaySupportAlgorithm::compute3( - IndexSet::set_difference(supports[r2], r1_supp, temp_diff); - if (temp_diff.power_of_2()) - { -- create_new_vector(vs, supports, r1, r2, next_col, -+ this->create_new_vector(vs, supports, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - DEBUG_4ti2(++num_added;) -@@ -866,7 +866,7 @@ RaySupportAlgorithm::compute3( - IndexSet::set_difference(r1_supp, supports[r2], temp_diff); - if (temp_diff.power_of_2()) - { -- create_new_vector(vs, supports, r1, r2, next_col, -+ this->create_new_vector(vs, supports, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - DEBUG_4ti2(++num_one_diff_added;) -@@ -885,7 +885,7 @@ RaySupportAlgorithm::compute3( - zero_supp.set_union(supports[index]); - if (index >= r2_index && index < r2_finish) - { -- create_new_vector(vs, supports, r1, index, next_col, -+ this->create_new_vector(vs, supports, r1, index, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - DEBUG_4ti2(++num_added;) -@@ -905,7 +905,7 @@ RaySupportAlgorithm::compute3( - IndexSet::set_difference(r1_supp, supports[r2], temp_diff2); - if (temp_diff2.power_of_2()) - { -- create_new_vector(vs, supports, r1, r2, next_col, -+ this->create_new_vector(vs, supports, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - DEBUG_4ti2(++num_one_diff_added;) -@@ -918,7 +918,7 @@ RaySupportAlgorithm::compute3( - DEBUG_4ti2(++num_checks;) - if (!tree.dominated(temp_supp, r1, r2)) - { -- create_new_vector(vs, supports, r1, r2, next_col, -+ this->create_new_vector(vs, supports, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - DEBUG_4ti2(++num_added;) -@@ -1030,7 +1030,7 @@ RaySupportAlgorithm::compute4( - - // Find the next column. - int next_positive_count, next_negative_count, next_zero_count; -- Index next_col = next_column(vs, remaining, -+ Index next_col = this->next_column(vs, remaining, - next_positive_count, - next_negative_count, - next_zero_count); -@@ -1045,7 +1045,7 @@ RaySupportAlgorithm::compute4( - ) - - // We sort the vectors into zeros, positives, then negatives. -- sort(vs, supports, next_col, next_zero_count, next_positive_count, -+ RayImplementation::sort(vs, supports, next_col, next_zero_count, next_positive_count, - next_negative_count); - - int original_size = vs.get_number(); -@@ -1114,7 +1114,7 @@ RaySupportAlgorithm::compute4( - IndexSet::set_difference(supports[r2], r1_supp, temp_diff); - if (temp_diff.power_of_2()) - { -- create_new_vector(vs, supports, r1, r2, next_col, -+ this->create_new_vector(vs, supports, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - ++num_added; -@@ -1134,7 +1134,7 @@ RaySupportAlgorithm::compute4( - zero_supp.set_union(supports[index]); - if (index >= r2_start && index < r2_finish) - { -- create_new_vector(vs, supports, r1, index, next_col, -+ this->create_new_vector(vs, supports, r1, index, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - ++num_added; -@@ -1148,7 +1148,7 @@ RaySupportAlgorithm::compute4( - IndexSet::set_difference(r1_supp, supports[r2], temp_diff); - if (temp_diff.power_of_2()) - { -- create_new_vector(vs, supports, r1, r2, next_col, -+ this->create_new_vector(vs, supports, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - DEBUG_4ti2(++num_one_diff_added;) -@@ -1168,7 +1168,7 @@ RaySupportAlgorithm::compute4( - IndexSet::set_difference(r1_supp, supports[r2], temp_diff2); - if (temp_diff2.power_of_2()) - { -- create_new_vector(vs, supports, r1, r2, next_col, -+ this->create_new_vector(vs, supports, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - DEBUG_4ti2(++num_one_diff_added;) -@@ -1183,7 +1183,7 @@ RaySupportAlgorithm::compute4( - int count = temp_supp.count(); - next_supports[count].push_back(temp_supp); - next_indices[count].push_back(std::pair(r1,r2)); -- //create_new_vector(vs, supports, r1, r2, next_col, -+ //this->create_new_vector(vs, supports, r1, r2, next_col, - // next_positive_count, next_negative_count, - // temp, temp_supp); - //++num_added; -@@ -1216,7 +1216,7 @@ RaySupportAlgorithm::compute4( - { - int r1 = next_indices[i][j].first; - int r2 = next_indices[i][j].second; -- create_new_vector(vs, supports, r1, r2, next_col, -+ this->create_new_vector(vs, supports, r1, r2, next_col, - next_positive_count, next_negative_count, - temp, temp_supp); - next_tree.insert(next_supports[i][j], vs.get_number()-1); diff --git a/4ti2-maxnorm.patch b/4ti2-maxnorm.patch new file mode 100644 index 0000000..8042b6f --- /dev/null +++ b/4ti2-maxnorm.patch @@ -0,0 +1,49 @@ +--- src/zsolve/Options.cpp.orig 2018-08-19 09:37:54.000000000 -0600 ++++ src/zsolve/Options.cpp 2018-10-09 15:22:30.464345255 -0600 +@@ -70,7 +70,7 @@ Options::set_defaults () + m_loglevel = 0; + m_backup_frequency = 0; + m_resume = false; +- m_maxnorm = false; ++ m_maxnorm = 0; + } + + void +@@ -195,7 +195,7 @@ Options::process_options (int argc, char + m_graver = true; + break; + case 'm': +- m_maxnorm = true; ++ m_maxnorm = 1; + break; + case 'p': + if (optarg == NULL || !strcmp (optarg, "32")) +@@ -381,7 +381,7 @@ bool Options::graver () const + return m_graver; + } + +-bool Options::maxnorm () const ++int Options::maxnorm () const + { + return m_maxnorm; + } +--- src/zsolve/Options.h.orig 2018-08-19 09:37:54.000000000 -0600 ++++ src/zsolve/Options.h 2018-10-09 15:20:13.673783047 -0600 +@@ -39,7 +39,7 @@ protected: + bool m_resume; + bool m_hilbert; + bool m_graver; +- bool m_maxnorm; ++ int m_maxnorm; + _4ti2_precision m_precision; + + public: +@@ -63,7 +63,7 @@ public: + bool resume () const; + bool hilbert () const; + bool graver () const; +- bool maxnorm () const; ++ int maxnorm () const; + _4ti2_precision precision () const; + + friend std::istream& operator>>(std::istream& in, Options& options); diff --git a/4ti2.spec b/4ti2.spec index aa7f94b..c59017e 100644 --- a/4ti2.spec +++ b/4ti2.spec @@ -1,127 +1,134 @@ Name: 4ti2 -Version: 1.3.2 -Release: 13%{?dist} -Summary: A software package for problems on linear spaces +Version: 1.6.9 +Release: 1%{?dist} +Summary: Algebraic, geometric and combinatorial problems on linear spaces + +%global relver %(tr . _ <<< %{version}) -Group: System Environment/Libraries License: GPLv2+ -URL: http://www.4ti2.de/ -Source0: http://www.4ti2.de/version_%{version}/%{name}-%{version}.tar.gz -Source1: http://www.4ti2.de/4ti2_manual.pdf -Source2: 4ti2.module.in -Patch0: 4ti2-1.3.2-gcc47.patch -Requires: environment-modules -BuildRequires: gmp-devel +URL: https://4ti2.github.io/ +Source0: https://github.com/4ti2/4ti2/releases/download/Release_%{relver}/%{name}-%{version}.tar.gz +Source1: 4ti2.module.in +# Deal with a boolean variable that can somehow hold the value 2 +Patch0: %{name}-maxnorm.patch + +BuildRequires: gcc +BuildRequires: gcc-c++ BuildRequires: glpk-devel +BuildRequires: gmp-devel +BuildRequires: tex(latex) +BuildRequires: tex(epic.sty) + +# 4ti2 contains a copy of gnulib, which has been granted a bundling exception: +# https://fedoraproject.org/wiki/Bundled_Libraries_Virtual_Provides +Provides: bundled(gnulib) + +Requires: 4ti2-libs%{?_isa} = %{version}-%{release} +Requires: environment-modules %description -A software package for algebraic, geometric and combinatorial -problems on linear spaces. +A software package for algebraic, geometric and combinatorial problems +on linear spaces. -This package uses Environment Modules, to load the binaries onto -your PATH you will need to run module load %{name}-%{_arch} +This package uses Environment Modules. Prior to invoking the binaries, +you must run "module load 4ti2-%{arch}" to modify your PATH. -%prep -%setup -q -cp -p %{SOURCE1} . -%patch0 -p1 -b .gcc47 +%package devel +Summary: Headers needed to develop software that uses 4ti2 +Requires: 4ti2-libs%{?_isa} = %{version}-%{release} +Requires: gmp-devel%{?_isa} -%build -CXXFLAGS="%{optflags} -I%{_includedir}/glpk" \ -CFLAGS="%{optflags} -I%{_includedir}/glpk" \ -./configure --disable-shared --disable-static \ - --prefix=%{_libdir}/%{name} \ - --libdir=%{_libdir}/%{name}/lib/ \ - --bindir=%{_libdir}/%{name}/bin/ -perl -pi -e 's|hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=\"-L\\\$libdir\"|g;' libtool +%description devel +Headers and library files needed to develop software that uses 4ti2. -make %{?_smp_mflags} +%package libs +Summary: Library for problems on linear spaces -%install -make install-exec DESTDIR=%{buildroot} +%description libs +A library for algebraic, geometric and combinatorial problems on linear +spaces. -# Make the environment-modules file -mkdir -p %{buildroot}%{_datadir}/Modules/modulefiles/ -# Since we're doing our own substitution here, use our own definitions. -sed 's#@LIBDIR@#'%{_libdir}/%{name}'#g;' < %SOURCE2 >%{buildroot}%{_datadir}/Modules/modulefiles/%{name}-%{_arch} +%prep +%autosetup -p0 -# The libraries are not really fit for use outside the package. -rm -rf %{buildroot}/%{_libdir}/%{name}/lib* +# Add a missing executable bit +chmod a+x ltmain.sh -%check -make check +# Fix encodings +iconv -f ISO8859-1 -t UTF-8 NEWS > NEWS.utf8 +touch -r NEWS NEWS.utf8 +mv -f NEWS.utf8 NEWS -%files -%defattr(-,root,root,-) -%doc COPYING TODO 4ti2_manual.pdf -%dir %{_libdir}/%{name}/bin -%dir %{_libdir}/%{name} -%{_datadir}/Modules/modulefiles/%{name}-%{_arch} -%{_libdir}/%{name}/bin/output -%{_libdir}/%{name}/bin/4ti2gmp -%{_libdir}/%{name}/bin/4ti2int32 -%{_libdir}/%{name}/bin/4ti2int64 -%{_libdir}/%{name}/bin/circuits -%{_libdir}/%{name}/bin/genmodel -%{_libdir}/%{name}/bin/gensymm -%{_libdir}/%{name}/bin/graver -%{_libdir}/%{name}/bin/groebner -%{_libdir}/%{name}/bin/hilbert -%{_libdir}/%{name}/bin/markov -%{_libdir}/%{name}/bin/minimize -%{_libdir}/%{name}/bin/normalform -%{_libdir}/%{name}/bin/ppi -%{_libdir}/%{name}/bin/qsolve -%{_libdir}/%{name}/bin/rays -%{_libdir}/%{name}/bin/walk -%{_libdir}/%{name}/bin/zbasis -%{_libdir}/%{name}/bin/zsolve +# Update the C++ standard +sed -i 's/c++0x/c++11/g' configure -%changelog -* Sun Feb 03 2013 Kevin Fenzi - 1.3.2-13 -- Rebuild for broken deps in rawhide +%build +%configure --enable-shared --disable-static --enable-fiber -* Wed Jul 18 2012 Fedora Release Engineering - 1.3.2-12 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild +# Get rid of undesirable hardcoded rpaths; workaround libtool reordering +# -Wl,--as-needed after all the libraries. +sed -e 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' \ + -e 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' \ + -e 's|CC="\(.*g..\)"|CC="\1 -Wl,--as-needed"|' \ + -i libtool -* Mon Mar 5 2012 Tom Callaway - 1.3.2-11 -- fix gcc47 issues +make %{?_smp_mflags} -* Tue Feb 28 2012 Fedora Release Engineering - 1.3.2-10 -- Rebuilt for c++ ABI breakage +# Build the manual +export LD_LIBRARY_PATH=$PWD/src/4ti2/.libs:$PWD/src/fiber/.libs:$PWD/src/groebner/.libs:$PWD/src/ppi/.libs:$PWD/src/util/.libs:$PWD/src/zsolve/.libs +pushd doc +make update-manual +bibtex 4ti2_manual +pdflatex 4ti2_manual +pdflatex 4ti2_manual +popd -* Thu Jan 12 2012 Fedora Release Engineering - 1.3.2-9 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild +%install +%make_install -* Wed Nov 16 2011 Peter Robinson - 1.3.2-8 -- Rebuild for new gmp +# Move the include files into a private directory +mkdir -p %{buildroot}%{_includedir}/tmp +mv %{buildroot}%{_includedir}/{4ti2,groebner,util,zsolve} \ + %{buildroot}%{_includedir}/tmp +mv %{buildroot}%{_includedir}/tmp %{buildroot}%{_includedir}/4ti2 -* Wed Sep 21 2011 Peter Schiffer - 1.3.2-7.1 -- rebuild with new gmp +# Move the 4ti2 binaries +mkdir -p %{buildroot}%{_libdir}/4ti2 +mv %{buildroot}%{_bindir} %{buildroot}%{_libdir}/4ti2 -* Mon Feb 07 2011 Fedora Release Engineering - 1.3.2-7 -- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild +# Make the environment-modules file +mkdir -p %{buildroot}%{_datadir}/Modules/modulefiles/ +# Since we're doing our own substitution here, use our own definitions. +sed 's#@LIBDIR@#'%{_libdir}/4ti2'#g;' < %SOURCE1 >%{buildroot}%{_datadir}/Modules/modulefiles/4ti2-%{_arch} -* Fri May 21 2010 Mark Chappell - 1.3.2-6 -- Take ownership of 2 directories we created +# We don't need or want libtool files +rm -f %{buildroot}%{_libdir}/*.la -* Tue Mar 02 2010 Mark Chappell - 1.3.2-5 -- Add note to description about environment modules +# We don't want documentation in _datadir +rm -fr %{buildroot}%{_datadir}/4ti2/doc -* Tue Mar 02 2010 Mark Chappell - 1.3.2-4 -- Switch to using modules -- Tag with the correct licence (GPLv2+) +%ldconfig_scriptlets libs -* Thu Feb 25 2010 Mark Chappell - 1.3.2-3 -- Preserve time stamp on 4ti2_manual.pdf -- Whitespace cleanup -- Remove obsolete post and portun calls -- Manually specify binaries +%check +export LD_LIBRARY_PATH=%{buildroot}%{_libdir} +make check -* Thu Feb 25 2010 Mark Chappell - 1.3.2-2 -- Tidy up inconsistant use of macros -- Remove empty devel package -- Include 4ti2 manual +%files +%doc doc/4ti2_manual.pdf +%{_libdir}/4ti2/ +%{_datadir}/Modules/modulefiles/4ti2-%{_arch} -* Wed Feb 17 2010 M D Chappell - 1.3.2-1 -- Initial build +%files devel +%{_includedir}/4ti2/ +%{_libdir}/lib4ti2*.so +%{_libdir}/libzsolve*.so + +%files libs +%doc NEWS README THANKS TODO +%license COPYING +%{_libdir}/lib4ti2*.so.0* +%{_libdir}/libzsolve*.so.0* + +%changelog +* Sat Sep 29 2018 Jerry James - 1.6.9-1 +- Split back out of latte-integrale diff --git a/sources b/sources index c25f9de..240fe43 100644 --- a/sources +++ b/sources @@ -1,2 +1 @@ -93367e63944d8bb18192c4984544ed0d 4ti2-1.3.2.tar.gz -1b6fb847fc0eacddfaaef3d00c8bb7ba 4ti2_manual.pdf +SHA512 (4ti2-1.6.9.tar.gz) = ca571cafb3d2f37b49c446f144499c830d940fd6b00c424a442acbbc2d947e52e6b76226769ce678367b45a21e4063da9eea1dc1acc51b45245c2c1edb95e18a