[Git][debian-gis-team/tilemaker][master] Add patch to fix FTBFS with boost1.88. (closes: #1110670)
Bas Couwenberg (@sebastic)
gitlab at salsa.debian.org
Sat Aug 9 20:03:49 BST 2025
Bas Couwenberg pushed to branch master at Debian GIS Project / tilemaker
Commits:
5c41ff4e by Bas Couwenberg at 2025-08-09T21:03:17+02:00
Add patch to fix FTBFS with boost1.88. (closes: #1110670)
- - - - -
3 changed files:
- debian/changelog
- + debian/patches/boost1.86.patch
- + debian/patches/series
Changes:
=====================================
debian/changelog
=====================================
@@ -3,6 +3,8 @@ tilemaker (3.0.0-2) UNRELEASED; urgency=medium
* Team upload.
* Bump Standards-Version to 4.7.2, no changes.
* Fix old FSF address in copyright file.
+ * Add patch to fix FTBFS with boost1.88.
+ (closes: #1110670)
-- Bas Couwenberg <sebastic at debian.org> Sun, 28 Jul 2024 20:04:59 +0200
=====================================
debian/patches/boost1.86.patch
=====================================
@@ -0,0 +1,165 @@
+Description Boost 186 (#759)
+Author: Colin Dellow <cldellow at gmail.com>
+Origin: https://github.com/systemed/tilemaker/pull/759
+
+--- a/action.yml
++++ b/action.yml
+@@ -7,11 +7,11 @@ inputs:
+ config:
+ description: 'A JSON file listing each layer, and the zoom levels at which to apply it'
+ required: false
+- default: '/resources/config-openmaptiles.json'
++ default: 'config.json'
+ process:
+ description: "A Lua program that looks at each node/way's tags, and places it into layers accordingly"
+ required: false
+- default: '/resources/process-openmaptiles.lua'
++ default: 'process.lua'
+ output:
+ description: 'Could be directory of tiles, or a .mbtiles files'
+ required: true
+--- a/include/mmap_allocator.h
++++ b/include/mmap_allocator.h
+@@ -10,9 +10,6 @@ public:
+ typedef std::size_t size_type;
+
+ static void *allocate(size_type n, const void *hint = 0);
+- static void deallocate(void *p, size_type n);
+- static void destroy(void *p);
+- static void shutdown();
+ static void reportStoreSize(std::ostringstream &str);
+ static void openMmapFile(const std::string& mmapFilename);
+ };
+@@ -47,15 +44,15 @@ public:
+
+ void deallocate(pointer p, size_type n)
+ {
+- void_mmap_allocator::deallocate(p, n);
++ // This is a no-op. Most usage of tilemaker should never deallocate
++ // an mmap_allocator resource. On program termination, everything gets
++ // freed.
+ }
+
+ void construct(pointer p, const_reference val)
+ {
+ new((void *)p) T(val);
+ }
+-
+- void destroy(pointer p) { void_mmap_allocator::destroy(p); }
+ };
+
+ template<typename T1, typename T2>
+--- a/src/mmap_allocator.cpp
++++ b/src/mmap_allocator.cpp
+@@ -180,10 +180,6 @@ void mmap_shm::close()
+ mmap_shm_thread_region_ptr.reset();
+ }
+
+-bool void_mmap_allocator_shutdown = false;
+-
+-void void_mmap_allocator::shutdown() { void_mmap_allocator_shutdown = true; }
+-
+ void * void_mmap_allocator::allocate(size_type n, const void *hint)
+ {
+ while(true) {
+@@ -211,52 +207,6 @@ void * void_mmap_allocator::allocate(siz
+ }
+ }
+
+-void void_mmap_allocator::deallocate(void *p, size_type n)
+-{
+- destroy(p);
+-}
+-
+-void void_mmap_allocator::destroy(void *p)
+-{
+- if(void_mmap_allocator_shutdown) return;
+-
+- if(mmap_shm_thread_region_ptr != nullptr) {
+- auto &i = *mmap_shm_thread_region_ptr;
+- if(p >= (void const *)i.region.data() && p < reinterpret_cast<void const *>(reinterpret_cast<uint8_t const *>(i.region.data()) + i.region.size())) {
+- allocator_t allocator(i.buffer.get_segment_manager());
+- return allocator.destroy(reinterpret_cast<uint8_t *>(p));
+- }
+- }
+-
+- if(mmap_file_thread_ptr != nullptr) {
+- auto &i = *mmap_file_thread_ptr;
+- if(p >= i.region.get_address() && p < reinterpret_cast<void const *>(reinterpret_cast<uint8_t const *>(i.region.get_address()) + i.region.get_size())) {
+- allocator_t allocator(i.buffer.get_segment_manager());
+- allocator.destroy(reinterpret_cast<uint8_t *>(p));
+- return;
+- }
+- }
+-
+- std::lock_guard<std::mutex> lock(mmap_allocator_mutex);
+- for(auto &i: mmap_shm_regions) {
+- if(p >= (void const *)i->region.data() && p < reinterpret_cast<void const *>(reinterpret_cast<uint8_t const *>(i->region.data()) + i->region.size())) {
+- std::lock_guard<std::mutex> lock(i->mutex);
+- allocator_t allocator(i->buffer.get_segment_manager());
+- allocator.destroy(reinterpret_cast<uint8_t *>(p));
+- return;
+- }
+- }
+-
+- for(auto &i: mmap_dir.files) {
+- if(p >= i->region.get_address() && p < reinterpret_cast<void const *>(reinterpret_cast<uint8_t const *>(i->region.get_address()) + i->region.get_size())) {
+- std::lock_guard<std::mutex> lock(i->mutex);
+- allocator_t allocator(i->buffer.get_segment_manager());
+- allocator.destroy(reinterpret_cast<uint8_t *>(p));
+- return;
+- }
+- }
+-}
+-
+ void void_mmap_allocator::reportStoreSize(std::ostringstream &str) {
+ if (mmap_dir.mmap_file_size>0) { str << "Store size " << (mmap_dir.mmap_file_size / 1000000000) << "G | "; }
+ }
+--- a/src/sorted_node_store.cpp
++++ b/src/sorted_node_store.cpp
+@@ -64,8 +64,6 @@ SortedNodeStore::SortedNodeStore(bool co
+
+ void SortedNodeStore::reopen()
+ {
+- for (const auto entry: allocatedMemory)
+- void_mmap_allocator::deallocate(entry.first, entry.second);
+ allocatedMemory.clear();
+
+ totalNodes = 0;
+@@ -86,9 +84,6 @@ void SortedNodeStore::reopen()
+ }
+
+ SortedNodeStore::~SortedNodeStore() {
+- for (const auto entry: allocatedMemory)
+- void_mmap_allocator::deallocate(entry.first, entry.second);
+-
+ s(this) = ThreadStorage();
+ }
+
+--- a/src/sorted_way_store.cpp
++++ b/src/sorted_way_store.cpp
+@@ -64,15 +64,10 @@ SortedWayStore::SortedWayStore(bool comp
+ }
+
+ SortedWayStore::~SortedWayStore() {
+- for (const auto entry: allocatedMemory)
+- void_mmap_allocator::deallocate(entry.first, entry.second);
+-
+ s(this) = ThreadStorage();
+ }
+
+ void SortedWayStore::reopen() {
+- for (const auto entry: allocatedMemory)
+- void_mmap_allocator::deallocate(entry.first, entry.second);
+ allocatedMemory.clear();
+
+ totalWays = 0;
+--- a/src/tilemaker.cpp
++++ b/src/tilemaker.cpp
+@@ -563,6 +563,5 @@ int main(const int argc, const char* arg
+ #endif
+
+ cout << endl << "Filled the tileset with good things at " << sharedData.outputFile << endl;
+- void_mmap_allocator::shutdown(); // this clears the mmap'ed nodes/ways/relations (quickly!)
+ }
+
=====================================
debian/patches/series
=====================================
@@ -0,0 +1 @@
+boost1.86.patch
View it on GitLab: https://salsa.debian.org/debian-gis-team/tilemaker/-/commit/5c41ff4e52c17f938dac3afc142e019954241539
--
View it on GitLab: https://salsa.debian.org/debian-gis-team/tilemaker/-/commit/5c41ff4e52c17f938dac3afc142e019954241539
You're receiving this email because of your account on salsa.debian.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/pkg-grass-devel/attachments/20250809/4166062a/attachment-0001.htm>
More information about the Pkg-grass-devel
mailing list