Author Topic: Codeblocks on MAC OS Catalina  (Read 12419 times)

maffio79

  • Guest
Codeblocks on MAC OS Catalina
« on: January 27, 2020, 10:50:46 pm »
Hi I need to install the Codeblocks app in my laptop but it seems the version is in 32bits and now Apple is just allowing 64bits versions.

Can somebody please tell me if there is a new update or version or way to install it in my Macbook with Catalina?

Thank you.

Regards,

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13413
    • Travis build status
Re: Codeblocks on MAC OS Catalina
« Reply #1 on: January 28, 2020, 08:42:13 am »
Nope, there are only night builds or you'll have to self compile. The latest version available on the site is not usable anyway, because it is too buggy.
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Offline anb

  • Multiple posting newcomer
  • *
  • Posts: 13
Re: Codeblocks on MAC OS Catalina
« Reply #2 on: September 16, 2020, 02:25:31 pm »
Hi,

I have recently had the need to do some development on Macs for my work and I would love to use Code::Blocks.  I use Code::Blocks on Linux.  I have tried v13 but that crashes constantly.  I also found a v17 but that crashes even more frequently!  So I have looked at building it myself using the latest source of everything, as a starting point.

I have successfully built wxWidgets (v3.1), and compiling Code::Blocks appears to get a very long way before it fails complaining about wxPaintEvent not having an empty constructor.  I then tried building v2.8 of wxWidgets (actually wxMac) but that fails to build on Mojave (10.14).  I then tried v3.0 but that fails too.  So it looks like I am stuck with v3.1 of wxWidgets but then Code::Blocks doesn't appear to like it.

I cannot find much out about the Mac build issues.  Is this truly an impossible task or are we talking about tweaks and little fixes?

The latest version available on the site is not usable anyway, because it is too buggy.

Even though this is dated from January, are you just referring to the latest nightly build or the latest "stable" build?  Is this generally or for the Mac?

I would love to get this building and working on a Mac but I cannot spend forever on sorting it out so if anyone has any pointers then I can look in to it for a bit.

Offline Miguel Gimenez

  • Developer
  • Lives here!
  • *****
  • Posts: 1553
Re: Codeblocks on MAC OS Catalina
« Reply #3 on: September 16, 2020, 03:06:56 pm »
Quote
it fails complaining about wxPaintEvent not having an empty constructor

This was fixed time ago in trunk removing the event and the associated code. Which C::B version are you trying to compile?. Which wxWidgets version are you using?. You can use wx3.1.1, 3.1.2, 3.1.3, 3.1.4 and the current master will be 3.1.5, please specify.

Offline anb

  • Multiple posting newcomer
  • *
  • Posts: 13
Re: Codeblocks on MAC OS Catalina
« Reply #4 on: September 16, 2020, 04:01:03 pm »
Hi Miguel,

Thanks for getting back to me so quickly.

I am using wxWidgets v3.1.4.

I downloaded the C::B source for v20.03.  I will try the trunk code.

This was fixed time ago in trunk removing the event and the associated code.

I commented out this error earlier and it failed on something else but I will try the latest trunk code.

I was also going to try building it on Ubuntu so I can see how it is supposed to build on there, with the hope of then getting it to build on a Mac.

Offline anb

  • Multiple posting newcomer
  • *
  • Posts: 13
Re: Codeblocks on MAC OS Catalina
« Reply #5 on: September 16, 2020, 05:20:43 pm »
I have now managed to successfully build and run the latest C::B from trunk on Mojave, so thank you very much.  It has only just finished building, and it runs.  I haven't really done anything else beyond that yet so will use it properly tomorrow.

If all goes well then I will look at putting together a proper Mac app for it tomorrow.  I guess it would be useful for many others if I share this somehow.  Any suggestions?  I have my own website(s) I could use.

Offline Miguel Gimenez

  • Developer
  • Lives here!
  • *****
  • Posts: 1553
Re: Codeblocks on MAC OS Catalina
« Reply #6 on: September 16, 2020, 07:57:25 pm »
Very few users have MAC OS, and most developers do not use it. Any help of a skilled user would be a benefit. User Xaviou creates nightlies for MAC OS, but I have seen little feedback from users. See http://forums.codeblocks.org/index.php/topic,23973.msg163511.html#msg163511 for more details on this.

From http://www.codeblocks.org/downloads/binaries:
Quote
Code::Blocks 20.03 for Mac is currently not available due to issues caused by Apple hardening their install packages and lack of Mac developers. We could use an extra Mac developer to work on these issues.

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13413
    • Travis build status
Re: Codeblocks on MAC OS Catalina
« Reply #7 on: September 16, 2020, 08:23:08 pm »
Shipping a version for mac requires Paid Apple developer account. Without it we cannot apply the new hardening required in the latest OS.
But this is the least of our concerns, we need someone to use this software on a daily basis and fix the problems which are macOS specific.
I use it from time to time, but I don't plan to spend too much fixing macOS issues.

Using the latest wx dev release and the latest code from trunk should work fine. If it doesn't please post the build steps/commands you're using and the build log. I'll try to help you.
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Offline anb

  • Multiple posting newcomer
  • *
  • Posts: 13
Re: Codeblocks on MAC OS Catalina
« Reply #8 on: September 17, 2020, 10:21:11 am »
Shipping a version for mac requires Paid Apple developer account. Without it we cannot apply the new hardening required in the latest OS.

Yes, that is a pain.  My work need to port some Windows apps to Mac and it is proving to be a painful process.

Our development environment for the Mac is on Mojave.  It's a long story.  So I am fine running the builds from Xaviou.

But this is the least of our concerns, we need someone to use this software on a daily basis and fix the problems which are macOS specific.
I use it from time to time, but I don't plan to spend too much fixing macOS issues.

I'll be pretty much the same, to be honest.  I just need to use it to port our Windows apps and libraries to the Mac.  But I imagine we'll end up doing more and more work on the Mac as time passes.

I can certainly report issues, etc.

Using the latest wx dev release and the latest code from trunk should work fine. If it doesn't please post the build steps/commands you're using and the build log. I'll try to help you.

As I said yesterday, it built fine and ran fine.  Although, when I came to use it this morning it wouldn't open a project.  It moaned about turning off the compiler, or something like that.  I built C::B with no plugins so I assumed that was the cause so tried to build it with all plugins but that failed to build.  At that point I saw your post about Xaviou builds so I downloaded one of those and that is working fine so far.

If issues do crop up then I may be able to look in to them but it depends if I have time.  I spent far too long messing with this yesterday that I had to find another app.  I ended up using CodeLite but that is nowhere near as good as C::B, but at least it wasn't crashing constantly for me.

My configure command line is:

Quote
./configure --prefix=/Volumes/Mac_USB_2TB/MacStuff/CodeBlock_Trunk/ --enable-unicode --enable-debug --disable-shared --disable-mediactrl

With this, it builds fine and runs but I can't open any project.  It also never asks me about compilers when launching.

Offline anb

  • Multiple posting newcomer
  • *
  • Posts: 13
Re: Codeblocks on MAC OS Catalina
« Reply #9 on: September 17, 2020, 10:59:36 am »
Whilst build 12198 is running and I can happily edit files, and it seems far more stable, I unfortunately cannot build/compile anything.  When I do so the command line appears in t he Build Log window but then nothing happens, and C::B thinks it is still building.  I cannot abort it either.  I have to completely kill the app.

Copying and pasting the command line to a Terminal runs fine, so the command line is correct.

This is happening on every file I try to build.  Any ideas?

If we can get my source building correctly then I can at least look in to some of these issues.  I can also use the very latest code too (12201).

Offline anb

  • Multiple posting newcomer
  • *
  • Posts: 13
Re: Codeblocks on MAC OS Catalina
« Reply #10 on: September 17, 2020, 11:29:00 am »
Copying to the clipboard is not working at all.  This is a big problem for me.  I have tried the standard shortcut keys, which were not assigned to be begin with, also tried the Copy menu item from the Edit menu, as well as Copy from the context menu.  None of them copy the selection to the clipboard.

Offline anb

  • Multiple posting newcomer
  • *
  • Posts: 13
Re: Codeblocks on MAC OS Catalina
« Reply #11 on: September 18, 2020, 04:56:23 pm »
Can anyone please advise what I need to do to enable the compiler for the build?  This is NOT to build C::B but once built it doesn't appear to support any compilers once running.

Once I have this working I can start using this again and looking in to issues I encounter.

Thanks.

Offline anb

  • Multiple posting newcomer
  • *
  • Posts: 13
Re: Codeblocks on MAC OS Catalina
« Reply #12 on: September 28, 2020, 11:07:27 am »
Can anyone help me in building C::B properly on a Mac?  I really could do with getting this working.

With Xavier Perrissoud's latest build (rev 12198) I cannot copy and paste any text and cannot build anything.  Trying to build anything just hangs.

Thanks.