From 87040d85ce46fd7dc6cb1f0ef2757167e22d57b1 Mon Sep 17 00:00:00 2001 From: Alec Edgington Date: Fri, 2 Jul 2021 12:16:53 +0100 Subject: [PATCH 1/4] [boost] Apply patch to fix https://github.com/boostorg/graph/issues/268 --- recipes/boost/all/conandata.yml | 6 +++++ .../boost/all/patches/graph_issue_268.patch | 26 +++++++++++++++++++ 2 files changed, 32 insertions(+) create mode 100644 recipes/boost/all/patches/graph_issue_268.patch diff --git a/recipes/boost/all/conandata.yml b/recipes/boost/all/conandata.yml index fd8af16e7cc7d..210e721b10c84 100644 --- a/recipes/boost/all/conandata.yml +++ b/recipes/boost/all/conandata.yml @@ -117,6 +117,8 @@ patches: base_path: "source_subfolder" - patch_file: "patches/boost_locale_fail_on_missing_backend.patch" base_path: "source_subfolder" + - patch_file: "patches/graph_issue_268.patch" + base_path: "source_subfolder" 1.75.0: - patch_file: "patches/boost_build_qcc_fix_debug_build_parameter_since_1_74.patch" base_path: "source_subfolder" @@ -124,6 +126,10 @@ patches: base_path: "source_subfolder" - patch_file: "patches/boost_locale_fail_on_missing_backend.patch" base_path: "source_subfolder" + - patch_file: "patches/graph_issue_268.patch" + base_path: "source_subfolder" 1.76.0: - patch_file: "patches/boost_locale_fail_on_missing_backend.patch" base_path: "source_subfolder" + - patch_file: "patches/graph_issue_268.patch" + base_path: "source_subfolder" diff --git a/recipes/boost/all/patches/graph_issue_268.patch b/recipes/boost/all/patches/graph_issue_268.patch new file mode 100644 index 0000000000000..b521f2d487504 --- /dev/null +++ b/recipes/boost/all/patches/graph_issue_268.patch @@ -0,0 +1,26 @@ +diff --git a/boost/graph/detail/adjacency_list.hpp b/boost/graph/detail/adjacency_list.hpp +index c1a2ada2..806b3f0e 100644 +--- a/boost/graph/detail/adjacency_list.hpp ++++ b/boost/graph/detail/adjacency_list.hpp +@@ -2069,15 +2069,20 @@ namespace detail + inline void reindex_edge_list( + EdgeList& el, vertex_descriptor u, boost::disallow_parallel_edge_tag) + { +- for (typename EdgeList::iterator ei = el.begin(); ei != el.end(); ++ei) ++ typename EdgeList::iterator ei = el.begin(), e_end = el.end(); ++ while (ei != e_end) { + { + if (ei->get_target() > u) + { + typename EdgeList::value_type ce = *ei; ++ ++ei; + el.erase(ce); + --ce.get_target(); + el.insert(ce); + } ++ else { ++ ++ei; ++ } + } + } + } // namespace detail From 3c30579a3ba0fbb5c035d776e8b04d79a38f3a7d Mon Sep 17 00:00:00 2001 From: Alec Edgington Date: Mon, 5 Jul 2021 13:34:39 +0100 Subject: [PATCH 2/4] Remove stray bracket. --- recipes/boost/all/patches/graph_issue_268.patch | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/boost/all/patches/graph_issue_268.patch b/recipes/boost/all/patches/graph_issue_268.patch index b521f2d487504..054e0f7db0849 100644 --- a/recipes/boost/all/patches/graph_issue_268.patch +++ b/recipes/boost/all/patches/graph_issue_268.patch @@ -8,7 +8,7 @@ index c1a2ada2..806b3f0e 100644 { - for (typename EdgeList::iterator ei = el.begin(); ei != el.end(); ++ei) + typename EdgeList::iterator ei = el.begin(), e_end = el.end(); -+ while (ei != e_end) { ++ while (ei != e_end) { if (ei->get_target() > u) { From 888fe3a4c69f4f5db44548d38cb2cf3d55b072f4 Mon Sep 17 00:00:00 2001 From: Alec Edgington Date: Wed, 21 Jul 2021 14:12:11 +0100 Subject: [PATCH 3/4] Correct line number. --- recipes/boost/all/patches/graph_issue_268.patch | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/boost/all/patches/graph_issue_268.patch b/recipes/boost/all/patches/graph_issue_268.patch index 054e0f7db0849..5bdf95999614c 100644 --- a/recipes/boost/all/patches/graph_issue_268.patch +++ b/recipes/boost/all/patches/graph_issue_268.patch @@ -2,7 +2,7 @@ diff --git a/boost/graph/detail/adjacency_list.hpp b/boost/graph/detail/adjacenc index c1a2ada2..806b3f0e 100644 --- a/boost/graph/detail/adjacency_list.hpp +++ b/boost/graph/detail/adjacency_list.hpp -@@ -2069,15 +2069,20 @@ namespace detail +@@ -2070,15 +2070,20 @@ namespace detail inline void reindex_edge_list( EdgeList& el, vertex_descriptor u, boost::disallow_parallel_edge_tag) { From c268543a4f94a2317517924166f6c6803b6f0195 Mon Sep 17 00:00:00 2001 From: Alec Edgington Date: Wed, 21 Jul 2021 18:01:00 +0100 Subject: [PATCH 4/4] Correct line number (take 2). Sorry about this. I hope I have got it right this time. --- recipes/boost/all/patches/graph_issue_268.patch | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/boost/all/patches/graph_issue_268.patch b/recipes/boost/all/patches/graph_issue_268.patch index 5bdf95999614c..7a2bfb676e24a 100644 --- a/recipes/boost/all/patches/graph_issue_268.patch +++ b/recipes/boost/all/patches/graph_issue_268.patch @@ -1,8 +1,8 @@ diff --git a/boost/graph/detail/adjacency_list.hpp b/boost/graph/detail/adjacency_list.hpp -index c1a2ada2..806b3f0e 100644 +index 4b11fa51..8ba6b12e 100644 --- a/boost/graph/detail/adjacency_list.hpp +++ b/boost/graph/detail/adjacency_list.hpp -@@ -2070,15 +2070,20 @@ namespace detail +@@ -2068,15 +2068,20 @@ namespace detail inline void reindex_edge_list( EdgeList& el, vertex_descriptor u, boost::disallow_parallel_edge_tag) {