Questions tagged [weak-linking]

74 questions
0
votes
1 answer

dyld: Symbol not found: ___darwin_check_fd_set_overflow

When I build my app in XCode 12.4 target device iOS 13.3, it will crash at launch with error message below. But works fine target device simulator. dyld: Symbol not found: ___darwin_check_fd_set_overflow Referenced from:…
weizhoufeng
  • 3
  • 1
  • 2
0
votes
2 answers

Weak Linking Framework for Printing

I have a simple project that uses mail and print routines. For printing, i have a subclass of UIPrintPageRenderer. I'm following Apple's guidelines for using weakly linked classes: - The base SDK for your Xcode project must be iOS 4.2 or newer. The…
Mustafa
  • 20,504
  • 42
  • 146
  • 209
0
votes
1 answer

Getting the address of a overwritten weak symbol

My question assumes gcc or clang for x86 or x86_64. Let's say I have the following files: // weak.c #include __attribute__((weak)) void i_am_weak(void) { printf("I am weak\n"); } int main() { i_am_weak(); return 0; } //…
icebp
  • 1,608
  • 1
  • 14
  • 24
0
votes
1 answer

Weak linking in static library iOS

We have a static framework that we have built and it depends upon an SDK that we use to access ID's. This SDK has come out with a new version which has a new interface. Currently the user would add our framework and the dependency SDK and…
user3440639
  • 185
  • 2
  • 12
0
votes
0 answers

How to see which functions are weak-linked in an object?

Is there a way to see/capture weakly linked functions in an object? I removed older library's linkage but since some are linked with weak-linkage, I can't capture all of the used functions.
Mert Can Ergün
  • 399
  • 5
  • 14
0
votes
3 answers

weak linking in shared object not working as expected

I'm trying to use the cmocka unit test framework which suggests to use weak linking to be able to select a user-defined implementation over the actual implementation of a function. In my environment I have a shared object which I want to unit test.…
Thanos
  • 691
  • 1
  • 5
  • 14
0
votes
1 answer

Checking for the existence of externally defined identifiers in C

I ran into this problem while developing in Objective-C for iOS, but this should apply to any C/C++/Objective-C code using the Mac OS X/iOS linker. The solution is covered by another question, but I'm interested in the why. Let's say I'm using a…
benzado
  • 82,288
  • 22
  • 110
  • 138
0
votes
1 answer

Weak linked class in Xcode

My project has an Objective-C class MockupModel that provides mockup information to an iOS Xcode project to help with creating screen shots for the App store. The project has two targets. The mockup target includes MockupModel.m. I want the main…
Benjohn
  • 13,228
  • 9
  • 65
  • 127
0
votes
1 answer

Only weak link the frameworks which is not available in deployment target?

In my app, Most frameworks is weak linked. As I read the document, I consider that maybe I needn't weak-link these frameworks. Setting of my app My app's deployment target is iOS4.3 and the base SDK is iOS7.1. My idea In my app I use CIImage and…
KudoCC
  • 6,912
  • 1
  • 24
  • 53
0
votes
1 answer

Error when weak-linking StoreKit framework on iPhone

I am trying to add In App Purchase support to my app. I would like the app to still be able to support OS2.2.1, but IAP are not available unless the OS version is 3.0 or higher. I have tried weak-linking the StoreKit framework. Basically, I have…
CG.
  • 1
  • 1
0
votes
2 answers

Objective-C Check if Structs is defined

My iOS application can use an optional external 3rd party library. I thought of using this answer (Weak Linking - check if a class exists and use that class) and detect if the class exists before executing code specific to this library. However, I…
Nathan H
  • 48,033
  • 60
  • 165
  • 247
0
votes
0 answers

Conditional weak-linked symbol modification/redeclaration

I have the following weakly linked declaration: extern __attribute__((visibility ("default"))) Type* const symbolName __attribute__((weak_import)); The problem is, the symbol may or may not be defined, depending on the operating system. So, when I…
Léo Natan
  • 56,823
  • 9
  • 150
  • 195
0
votes
2 answers

Can you inherit from a class in objc not available at compile time?

I have code inheriting from UIActivity introduced in iOS 6 which compiles fines with Xcode 4.5 and works fine on iOS 6 and previous versions (I detect availability of the class at runtime). However, is it possible to make this code compile with…
Grzegorz Adam Hankiewicz
  • 7,349
  • 1
  • 36
  • 78
0
votes
1 answer

Weak linking popoverBackgroundViewClass to make it work in <5.0 IOS

Already checked this question: Weak linking UIPopoverBackgroundView and already read: http://www.marco.org/2010/11/22/supporting-older-versions-of-ios-while-using-new-apis#fnref:1 I have a custom PopoverBackgroundView declared in a .h and…
pdrcabrod
  • 1,467
  • 1
  • 14
  • 22
1 2 3 4
5