cmake adds links to librt on android

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Fixed
    • Priority: Major - P3
    • 1.10.0
    • Affects Version/s: None
    • Component/s: None
    • None
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      https://github.com/mongodb/mongo-c-driver/blob/8ff2b68b57bb57a8bc66a368c14c88d77356d8f3/CMakeLists.txt#L530

      librt as well as libpthred are integrated in to libc on android and don't exist independently.

      Changing

      if (UNIX AND NOT APPLE)
         set (SHM_LIB -lrt)
      endif ()
      

      to

      if (UNIX AND NOT APPLE AND NOT ANDROID)
         set (SHM_LIB -lrt)
      endif ()
      

      worked for me.

            Assignee:
            A. Jesse Jiryu Davis
            Reporter:
            Gabriel Russell (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: