How to Detect Apple Silicon and Rosetta from within a Shell Script

Compiled code can conclude the instruction set through conditional compilation. But what about processor-independent scripts? Finding out the current native processor architecture and emulation status thereof would be very useful in build systems that doesn’t support cross-compilations. Find out how a shell script can find out whether it is running under Apple’s processor, Intel, or emulated.

How to Run Legacy Command Line Apps on Apple Silicon

Being in the “bleeding edge” has its drawbacks in addition to benefits. Blazing a fresh trail means it’s more rough and plenty of unknowns. Similarly in open source software, support for the ARM architecture is slim and even slimmer on the Mac. But there is a way to run “legacy” Intel-only command line apps on the Mac.

Should You do Free Work to Get Hired?

Have you been asked to do a sample project as part of a hiring process? I’ve done it, not only once but **twice** as part of the same process. Here are those projects. You should be able to learn a thing or two from it Either learn the iOS programming techniques behind these two 40-hour projects or learn how to hunt for purple squirrels.

Bringing Asynchronous Core Data documents to OS X

Core Data now officially supports concurrency and I/O in background threads since OS X 10.7 and iOS 5. In the same release, Apple also brought the document architecture to iOS that leverages this new capability of Core Data. However OS X didn’t get the same level of multicore love. In this post, I’ll show you how to create a multi-core supporting document architecture application for OS X.

Google Reader API for Cocoa

Today I have just made the world a slightly better place. Better for Mac developers, that is. That’s because I have made an open-source Google Reader library for Cocoa. You can download the library from Github: GReader-Cocoa and hopefully you’ll like it enough to contribute patches. Why yet another Google API library? Two reasons why,…

Building mp4v2 library for Leopard compatibility

How to build mp4v2 for Leopard compatibility. 1. Download mp4v2-r355 from the MP4v2 project. 2. Setup these environment variables: export MACOSX_DEPLOYMENT_TARGET=10.5export CFLAGS=”-isysroot /Developer/SDKs/MacOSX10.5.sdk”export CXXFLAGS=”-isysroot /Developer/SDKs/MacOSX10.5.sdk” 3. Run configure with the following command: (refer to mp4v2 issue 58) ./configure –disable-gch –enable-ub=ppc,i386,x86_64 4. Go to the “.libs” directory that contains the compiled mp4v2 library and adjust the…