Opened 10 years ago

Closed 10 years ago

Last modified 2 years ago

#46236 closed defect (fixed)

openldap @2.4.40: Undefined symbols: _posix_memalign

Reported by: zzanderr Owned by: landonf (Landon Fuller)
Priority: Normal Milestone:
Component: ports Version: 2.3.3
Keywords: tiger leopard Cc: ballapete (Peter "Pete" Dyballa), udbraumann, ryandesign (Ryan Carsten Schmidt), michaelthomassullivan
Port: openldap

Description

The build fails with the error

:info:build Undefined symbols:
:info:build   "_posix_memalign", referenced from:
:info:build       _mdb_env_copyfd2 in libbackends.a(mdbmdb.o)
:info:build ld: symbol(s) not found
:info:build collect2: ld returned 1 exit status
:info:build make[2]: *** [slapd] Error 1

I added the following line to openldap's Portfile was able to upgrade:

config.args-append --disable-mdb

Of course, I only half know what I'm doing. I am attaching the log for the failed upgrade.

I found a clue here: http://code.metager.de/source/history/openldap/libraries/liblmdb/ under Revision 4008e5e58337feb8a5ab29b7f939b1831d3f6d75.

Attachments (2)

main.log.bz2 (15.2 KB) - added by zzanderr 10 years ago.
main.log (342.4 KB) - added by ballapete (Peter "Pete" Dyballa) 10 years ago.
main.log on PPC Tiger

Download all attachments as: .zip

Change History (13)

Changed 10 years ago by zzanderr

Attachment: main.log.bz2 added

comment:1 Changed 10 years ago by ballapete (Peter "Pete" Dyballa)

Cc: Peter_Dyballa@… added

Cc Me!

comment:2 Changed 10 years ago by ballapete (Peter "Pete" Dyballa)

The same failure happens on PPC Tiger, Mac OS X 10.4.11.

Changed 10 years ago by ballapete (Peter "Pete" Dyballa)

Attachment: main.log added

main.log on PPC Tiger

comment:3 Changed 10 years ago by mf2k (Frank Schima)

Cc: landonf@… removed
Keywords: powerpc added; upgrade failure G5 removed
Owner: changed from macports-tickets@… to landonf@…

comment:4 Changed 10 years ago by udbraumann

Cc: braumann@… added

Cc Me!

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

Cc: ryandesign@… added
Keywords: tiger leopard added; powerpc removed
Summary: openldap @2.4.40+overlays build fails on ppc G5, OS X 10.5.8 during upgradeopenldap @2.4.40: Undefined symbols: _posix_memalign

Same on Tiger i386 without the overlays variant.

You were able to build by disabling mdb... What is mdb and what is the significance of disabling it?

comment:6 Changed 10 years ago by zzanderr

From what I've gathered, mdb (shorthand for "Lightning Memory-Mapped Database) will soon be the favored backend to openLDAP, as it is openldap's own in-house database. Currently the primary backend is hdb (hierarchical database), which has superseded bdb (Berkeley database), though it still uses bdb for data storage (hdb improves performance through additional caching and indexing). Openldap's default configuration builds both hdb and bdb--and now mdb. I do not know if the previous version of openldap (2.4.39) was configured to build mdb by default and some change in mdb's code is the source of the build failure, or whether openldap 2.4.40 is the first version to enable mdb. I'll download the old version and check out its configure file, then let you know.

comment:7 Changed 10 years ago by zzanderr

openLDAP @2.4.39 does default-enable mdb, so I suppose they've changed some code.

comment:8 Changed 10 years ago by zzanderr

Apparently, the developers at openLDAP were going to use memalign rather than posix_memalign because of its ubiquity. Then they discovered that OS X only has posix_memalign and only in the more recent, fully POSIX-compliant versions. They mentioned using valloc for older versions of OS X, but do not seem to have followed through with it in openLDAP @2.4.40.

comment:9 Changed 10 years ago by michaelthomassullivan

Cc: MichaelThomasSullivan@… added

Cc Me!

comment:10 Changed 10 years ago by jeremyhu (Jeremy Huddleston Sequoia)

Resolution: fixed
Status: newclosed

comment:11 Changed 2 years ago by Christopher Nielsen <mascguy@…>

In b9f146270253133b12b865db0bc6d63f53e6125e/macports-ports (master):

openldap/openldap-devel: support mdb for 10.5 and earlier
See: #46236
See: #47630

Note: See TracTickets for help on using tickets.