Dive into the world of programming languages used for app development.

Posts under General subtopic

Post

Replies

Boosts

Views

Activity

Symbol not found: (_objc_claimAutoreleasedReturnValue)
When I run app, it works on iOS16+ device. But when I run on iOS15 device just working on debug mode, if I run release or profile modeI got runtime error: Log: (lldb) dyld[4928]: Symbol not found: (_objc_claimAutoreleasedReturnValue) Referenced from: '/private/var/containers/Bundle/Application/C724D7C6-82FA-4AF3-AE83-EC035B4429A5/Runner.app/Frameworks/geolocator_apple.framework/geolocator_apple' Expected in: '/usr/lib/libobjc.A.dylib' thread #1, stop reason = signal SIGABRT frame #0: 0x0000000106cbb2cc dyld`__abort_with_payload + 8 dyld`__abort_with_payload: -> 0x106cbb2cc <+8>: b.lo 0x106cbb2e8 ; <+36> 0x106cbb2d0 <+12>: stp x29, x30, [sp, #-0x10]! 0x106cbb2d4 <+16>: mov x29, sp 0x106cbb2d8 <+20>: bl 0x106c8164c ; cerror_nocancel Target 0: (Runner) stopped. Flutter doctor : Doctor summary (to see all details, run flutter doctor -v): [✓] Flutter (Channel stable, 3.29.2, on macOS 15.2 24C101 darwin-arm64, locale en-VN) [✓] Android toolchain - develop for Android devices (Android SDK version 34.0.0) [✓] Xcode - develop for iOS and macOS (Xcode 16.2) [✓] Chrome - develop for the web [✓] Android Studio (version 2024.2) [✓] VS Code (version 1.97.2)
1
0
136
Mar ’25
Objective-C Literals inside a Swift Package
I have a Swift Package that contains an Objective-C target. The target contains Objective-C literals but unfortunately the compiler says "Initializer element is not a compile-time constant", what am I doing wrong? Based on the error triggering in the upper half, I take it that objc_array_literals is on. My target definition looks like: .target( name: "MyTarget", path: "Sources/MySourcesObjC", publicHeadersPath: "include", cxxSettings: [ .unsafeFlags("-fobjc-constant-literals") ] ), I believe Objective-C literals are enabled since a long time but I still tried passing in the -fobjc-constant-literals flag and no luck. To be clear I'm not interested in a run-time initialization, I really want it to be compile time. Does anyone know what I can do?
3
0
122
May ’25
How to Create Applications with Objective-C Without ARC
I've been teaching myself Objective-C and I wanted to start creating projects that don't use ARC to become better at memory management and learn how it all works. I've been attempting to build and run applications, but I'm not really sure where to start as modern iOS development is used with Swift and memory management is handled. Is there any way to create modern applications that use Objective-C, UIKit, and not use ARC?
3
0
146
May ’25
libsystem_c.dylib: Assertion failed: (p->val == key), function lookup_substsearch, file collate.c, line 596.
At least with macOS Sequoia 15.5 and Xcode 16.3: $ cat test.cc #include <locale.h> #include <string.h> #include <xlocale.h> int main(void) { locale_t l = newlocale(LC_ALL_MASK, "el_GR.UTF-8", 0); strxfrm_l(NULL, "ό", 0, l); return 0; } $ c99 test.c && ./a.out Assertion failed: (p->val == key), function lookup_substsearch, file collate.c, line 596. Abort trap: 6
3
1
149
May ’25
Integrating App Clips in .NET MAUI iOS APP
We have an iOS App built in .NET MAUI (Multi-platform App UI). This is a web view App. We wish to integrate APP Clips into this App. But we are unable to do it, due to less available resources online on such implementation. We do not wish to share code between .NET MAUI App and App clips We understand it is not possible to add APP Clips without a parent swift/Xcode app. As an alternative solution we were thinking to Create a new APP in APP Store Connect using XCode/swift and integrate app clips to it. This parent app when downloaded by users will only redirect users to our MAIN .NET MAUI app to app store connect. We need to know if such apps will be approved by APPSTORE Connect? Please guide us on this Also please do let us know if you have any other solution to integrate App clips to a .NET MAUI App
1
0
118
Jun ’25
Swapping the `objectAtIndex:` method of `__NSArrayM` using `method_exchangeImplementations` will lead to continuous memory growth.
After swapping the -objectAtIndex: method using method_exchangeImplementations, it will cause continuous memory growth. Connect the iPhone and run the provided project. Continuously tap the iPhone screen. Observe Memory; it will keep growing. Sample code
2
0
310
Jul ’25
jmp_buf layout for Apple Silicon
Greetings! I am actively working on porting x64 code to Apple Silicon now that the time is nigh and part of the fundamentals of our software is a coroutine library for handling cooperative multitasking of GUI operations on the main thread. I was hoping to get the locations of the stack pointer and frame pointer in jmp_buf so, after setjmp() can redirect them to the primary handling routines in our coroutine library that handles the cooperative scheduling (which replaced and ported the old classic MP routines) which worked for PowerPC, i386 and x64. Any thoughts on where in the jmp_buf these might be located? I didn't see anything in the XNU open source. Any advice would be much obliged instead of having to dive in and re-implement these routines in assembly myself!
7
0
343
Jul ’25
Overriding global new and delete is not working.
We developing Native App with C++17 for iOS. We override global new and delete operators. This App deallocate all allocated memories correctly by Run on Xcode (Command + R), but exception occurs launch from xcrun or App icon on iPhone. I debugged the exception. Overriding new operation was called correctly, but overriding delete operation was not called. The default delete was called. I'm not sure why is that. STEPS TO REPRODUCE Build xcode project. Run "xcrun devicectl device install app --device " Run "xcrun devicectl device process launch --console --device " PLATFORM AND VERSION iOS Development environment: Xcode 16.4, macOS macOS Sequoia 15.5 Run-time configuration: iOS 18.5 main.cpp I attached is sample code to reproduce this problem. main.cpp
4
0
596
3w
KVO crashes in older OS-Versions not replicable in Sequoia
Greetings, With MacOS 15 Sequoia, Apple updated key-value-observations in such a way, that an unremoved observation by a now deallocated object will no longer cause an exception, when the observed object triggers said observation. While this is fundamentally a positive change, the issue comes with the fact, that this change affects systems based on the version of their operating system and not the version of the operating system of the build system. Many of our customers use old operating system versions and old hardware - meaning they can't easily update. Since we need to use up to date Xcode versions to develop for newer systems, our developers tend to have rather new OS versions. This means, that we are increasingly facing bugs which only happen in customer systems but not in most developer (or QA) systems. Currently, we still can use earlier OS versions with Xcode to fix these bugs, but once the used Xcode versions no longer support MacOS 14 or below this will become a major hurdle. Are there known solutions to this issue? We are currently attempting to swizzle observer adding and removal in order to fix the problem for old systems as well, but this has proven to be quite difficult and unstable. Since any weakly held property in the middle of an observation keypath can cause crashes, one would have to split up observations into multiple subobservations, which is less simple than it sounds, due to custom implementations of addObserver (such as there seems to be in array controller proxies) and collection operators. Thanks for any suggestions!
1
0
414
2d