Ticket #27 (closed enhancement: fixed)
FreeBSD build
| Reported by: | anonymous | Owned by: | artem |
|---|---|---|---|
| Priority: | critical (top) | Milestone: | 0.5.0 |
| Component: | Scons Build Scripts | Version: | SVN Trunk |
| Severity: | Normal | Keywords: | scons |
| Cc: | None | Patch Needs Improvement: | no |
| Needs Docmentation: | no | Has Patch?: | yes |
| Design Decision Needed: | no |
Description
FreeBSD builds and installs boost libraries with posix threads but without the -mt suffix.
The following changes were necessary for mapnik components to build on FreeBSD. I'm just signalling the breakage: a real check or some added logic that needs to be put into the SConstruct files (by someone more well-versed than I in scons). This is just a hackish change.
svn diff
Index: bindings/python/SConscript
===================================================================
--- bindings/python/SConscript (revision 479)
+++ bindings/python/SConscript (working copy)
@@ -28,7 +28,7 @@
linkflags = ''
if env['THREADING'] == 'multi':
- libraries = ['mapnik', 'boost_python%s-mt' % env['BOOST_APPEND']]
+ libraries = ['mapnik', 'boost_python%s' % env['BOOST_APPEND']]
else :
libraries = ['mapnik', 'boost_python%s' % env['BOOST_APPEND']]
Index: SConstruct
===================================================================
--- SConstruct (revision 479)
+++ SConstruct (working copy)
@@ -64,6 +64,9 @@
print "Building on %s ..." % env['PLATFORM']
Help(opts.GenerateHelpText(env))
+if env['PLATFORM'] == 'FreeBSD' :
+ env.Append(LIBS = 'pthread')
+
conf = Configure(env)
# Libraries and headers dependency checks
@@ -145,7 +148,7 @@
for count, libinfo in enumerate(BOOST_LIBSHEADERS):
if env['THREADING'] == 'multi' :
- if not conf.CheckLibWithHeader('boost_%s%s-mt' % (libinfo[0],env['BOOST_APPEND']), libinfo[1], 'C++') and libinfo[2] :
+ if not conf.CheckLibWithHeader('boost_%s%s' % (libinfo[0],env['BOOST_APPEND']), libinfo[1], 'C++') and libinfo[2] :
print 'Could not find header or shared library for boost %s, exiting!' % libinfo[0]
Exit(1)
elif not conf.CheckLibWithHeader('boost_%s%s' % (libinfo[0], env['BOOST_APPEND']), libinfo[1], 'C++') :
@@ -169,9 +172,9 @@
# Build shapeindex and remove its dependency from the LIBS
-if 'boost_program_options%s-mt' % env['BOOST_APPEND'] in env['LIBS']:
+if 'boost_program_options%s' % env['BOOST_APPEND'] in env['LIBS']:
SConscript('utils/shapeindex/SConscript')
- env['LIBS'].remove('boost_program_options%s-mt' % env['BOOST_APPEND'])
+ env['LIBS'].remove('boost_program_options%s' % env['BOOST_APPEND'])
# Build the input plug-ins
Change History
Note: See
TracTickets for help on using
tickets.
