Project

General

Profile

Actions

Feature #17741

open

Ruby links to `objc` for convenience - this should be moved into a native ext

Added by rickmark (Rick Mark) 4 months ago. Updated 4 months ago.

Status:
Open
Priority:
Normal
Assignee:
-
Target version:
-
[ruby-core:102979]

Description

As a convenance to extension developers Ruby on macOS always links to libobjc. This could be better handled with a native ObjC extension so that one could require 'objc' to add this to the process.

The extension would link to libobjc and provide bindings to objc_msgSend and friends. By not linking to libobjc we can also avoid linking to libc++abi and all that entails.

This makes ruby on mac more similar to ruby when compiled on other platforms.


Files

ruby_final.txt (2.24 KB) ruby_final.txt rickmark (Rick Mark), 03/22/2021 07:56 PM

Related issues

Related to Ruby master - Feature #17730: Ruby on macOS transitively links to ~150 dylibsClosedActions
Actions #1

Updated by mame (Yusuke Endoh) 4 months ago

  • Related to Feature #17730: Ruby on macOS transitively links to ~150 dylibs added

Updated by nobu (Nobuyoshi Nakada) 4 months ago

As far as I remember, I've heard that libobjc needs to be linked against the executable file instead of dynamically loaded modules for startup routines.
I'm not sure if still it is true though.

Actions

Also available in: Atom PDF