Opened 13 years ago

Closed 13 years ago

#28944 closed defect (fixed)

py26-mapnik 0.7.1 does not support filesystem 3 in boost 1.46

Reported by: macfreek (Freek Dijkstra) Owned by: ryandesign (Ryan Carsten Schmidt)
Priority: Normal Milestone:
Component: ports Version: 1.9.2
Keywords: haspatch Cc: dbsgeo@…
Port: py26-mapnik

Description

I just did a port upgrade outdated, which upgrade boost from 1.44.0_0 to 1.46.1_0 and py26-mapnik from 0.7.1_1 to 0.7.1_4.

When py26-mapnik compiles, it gives the following error:

 src/datasource_cache.cpp: In static member function 'static void mapnik::datasource_cache::register_datasources(const std::string&)':
 src/datasource_cache.cpp:146: error: invalid initialization of reference of type 'const std::string&' from expression of type 'boost::filesystem3::path'
 src/datasource_cache.cpp:46: error: in passing argument 1 of 'bool mapnik::is_input_plugin(const std::string&)'
 src/datasource_cache.cpp:152: error: 'class boost::filesystem3::directory_entry' has no member named 'string'
 src/datasource_cache.cpp:167: error: 'class boost::filesystem3::directory_entry' has no member named 'string'

The cause is that boost has done a major upgrade to their filesystem code. http://www.boost.org/doc/libs/1_46_1/libs/filesystem/v3/doc/ gives the details:

Version 3 is a major revision with many new and improved features. It may, however, break some user code written for Version 2.

To ease the transition, Boost releases 1.44 through 1.47 will supply both V2 and V3. Version 2 is the default version for Boost release 1.44 and 1.45. Version 3 will be the default starting with release 1.46.

There are patches available at the mapnik website, both to select filesystem version 2 or upgrade to version 3. I have not tested if this works for mapnik 0.7.1 (stable) or 0.7.2 (trunk).

Attachments (2)

patch-boost-filesystem3.diff (4.1 KB) - added by macfreek (Freek Dijkstra) 13 years ago.
Patchfile to make mapnik work with boost 1.46
Portfile.diff (490 bytes) - added by macfreek (Freek Dijkstra) 13 years ago.
patch for the Portfile

Download all attachments as: .zip

Change History (7)

Changed 13 years ago by macfreek (Freek Dijkstra)

Patchfile to make mapnik work with boost 1.46

Changed 13 years ago by macfreek (Freek Dijkstra)

Attachment: Portfile.diff added

patch for the Portfile

comment:1 Changed 13 years ago by macfreek (Freek Dijkstra)

patch-boost-filesystem3.diff should be added to the files directory and the Portfile.diff should be applied to the Portfile of py26-mapnik. The patch is based on the patch for mapnik 0.7.2-dev and works on my machine. Please verify and if it works, please commit.

comment:2 Changed 13 years ago by ryandesign (Ryan Carsten Schmidt)

Summary: py-mapnik 0.7.1 does not support filesystem 3 in boost 1.46py26-mapnik 0.7.1 does not support filesystem 3 in boost 1.46

comment:3 Changed 13 years ago by ryandesign (Ryan Carsten Schmidt)

Keywords: haspatch added

comment:4 Changed 13 years ago by ryandesign (Ryan Carsten Schmidt)

Owner: changed from macports-tickets@… to ryandesign@…
Status: newassigned

comment:5 Changed 13 years ago by ryandesign (Ryan Carsten Schmidt)

Resolution: fixed
Status: assignedclosed

Thanks; committed in r78521.

Note: See TracTickets for help on using tickets.