Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • CMake CMake
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 4,101
    • Issues 4,101
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 15
    • Merge requests 15
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Releases
  • Packages and registries
    • Packages and registries
    • Container Registry
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • External wiki
    • External wiki
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • CMakeCMake
  • CMakeCMake
  • Issues
  • #19163
Closed
Open
Issue created Apr 11, 2019 by David Edelsohn@edelsohn

AIX export symbols incorrect

CMake rules for AIX do not export the correct symbols and do not use the correct mechanism to export symbols.

CMake currently invokes the AIX linker with -bexpall to export "all" symbols. This is incorrect because it does not export C++ mangled symbols as defined by the Itanium ABI. (-bexpfull would export more symbols but causes even more problems and NEVER SHOULD BE USED.) Exporting too many symbols causes problems because a shared library may re-export symbols from another library causing confused dependencies, duplicate symbols and other problems. CMake should explicitly create an export list in the same manner as GNU Libtool.

CMake also creates shared libraries with -G/-brtl. This normally is not necessary and harmful. This often will overflow the TOC. It forces all global calls through function descriptors (PLTs) so that they can be overridden, but most applications are not invoked in a manner that requires symbolic overriding of symbols. The excessive use of function descriptors also greatly harms performance on AIX.

This behavior seems to have been introduced in CMake in 2013. The Mantis bug reports are unclear about the exact symptoms, but the solution needs to be redesigned in a manner more consistent with AIX semantics.

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking