I cannot run Code::Blocks on Mac Air chip M2

I could download Code::Blocks but every time I try to open it, it will open and suddenly out from the app and have a pop up window said "CodeBlocks quit unexpectedly". I need to use this app due to my university studying😭 What I have to do?

MacBook Air 15″, macOS 14.2

Posted on Dec 21, 2023 07:10 PM

Reply
5 replies

Dec 22, 2023 04:47 AM in response to MindPTT

According to what I read on the website, the Mac version only supports i386, i.e. 32 bit. Rosetta2 which is a translation layer to translate Intel Mac code to Apple Silicon code is only 64 bit.


One solution could be to download the source code version, get Apple development tools and build an Apple Silicon native version.


The macOS branch of Code::Blocks developers have admitted that their version is woefully out date do to that lack of Apple developers for the project. This is always an issue with open source tools as they are all generally developed on a volunteer basis.


Another solution might be creating a Windows11 or a Linux virtual machine with something like Parallels Desktop or VMware Fusion. However these will be ARM64 versions and again the tools may be needed to be built from scratch. In this case however, Linux may be an easier option as the distros often have build tools to build apps from source.


Bottom line is that here really is not a quick and easy solution to the issue using an M2 Mac.



Dec 22, 2023 07:43 AM in response to MindPTT

Code::Blocks was done for the Mac years ago and has not been upgraded to be compatible with 64-bit Macs and in particular, Apple Silicon Macs. You are done with Code:Blocks unless you choose to run it on an old Mac with macOS Mojave. Even if you could download the Code::Blocks source and build it yourself, you would need to resolve porting 32-bit code to 64-bit and any external dependencies the developers used. Not worth the time lost.


Apple's Xcode IDE supports C/C++ development. There is the less complicated Microsoft Visual Studio Code (not Visual Studio which is EOL in Aug 2024) which has C/C++ and other extensible modules. It has a ARM build too for the M-series Apple architecture. There are other IDE available with a Google search. You will still need Apple's compilation tools in the form of the command line tools for Xcode (~3GB) that are installed via the Terminal command:


/usr/bin/xcode-select --install


and the C/C++ compiler is clang/clang++.


You can see the supported C++ standards available to you where x is arbitrary to get the usage list:


/usr/bin/clang++ foo.C -std=x


This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

I cannot run Code::Blocks on Mac Air chip M2

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.