[GRASS-dev] discussion: replacing ps.map
woklist at kyngchaos.com
Fri Apr 6 10:02:33 EDT 2007
On Apr 6, 2007, at 6:12 AM, Glynn Clements wrote:
> William Kyngesburye wrote:
>> I'm having a problem building libraster now. I get a bunch of
>> multiple definitions errors between the linked pngdriver and psdriver
>> when linking the raster library.
> Can you find out whether the Mac linker has an option to ignore
> duplicate symbols (at least for the case where none of the symbols are
> actually being imported)?
> If it does, adding that switch to the definition of SHLIB_LD in
> SC_CONFIG_CFLAGS (in aclocal.m4) is the appropriate solution.
> If it doesn't, I can give these functions/variables unique names, but
> that's really just a workaround; this issue is likely to crop up again
> in the future.
The flag to manually make them warnings is -multiply_defined warning
(or suppress). But it's really an effect of using a flat namespace.
-flat_namespace (and -fno-common) might be a holdover from the early
Mac days building GRASS, when there were probably issues. The
default on OSX, since 10.1, is a two-level namespace, where multiply-
defined symbols are a warning by default.
I removed -flat_namespace from my SHLIB_LD in platform.make (quick-n-
dirty hack). The multiply-defined symbols don't break the raster
library linking now. But instead I have an undefined symbol in the
ld: Undefined symbols:
_PS_Driver referenced from libgrass expected to be defined in /
(that 'libgrass' got truncated, it's really libgrass_display - it's
an intentional quirk of the OSX linker)
William Kyngesburye <kyngchaos*at*kyngchaos*dot*com>
"Time is an illusion - lunchtime doubly so."
- Ford Prefect
More information about the grass-dev