Author Topic: BASS and related libraries for ARM Mac  (Read 2566 times)

kode54

  • Posts: 124
BASS and related libraries for ARM Mac
« on: 29 Jun '20 - 04:43 »
Is there any plan to produce early alphas that include this platform for those of us attempting to produce Universal 2 binaries early?

Basically, to build for it, you need the Xcode 12 for Universal Apps beta, and if you're using the command line tools, you also need to replace the MacOSX10.16.sdk in /Library/Developer/CommandLineTools/SDKs with the one from inside the Xcode Universal beta app to build for arm64.

It needs the `-arch arm64` switch, and if you use any assembly functions, they need to be the same ABI as iOS, only using the same features as a typical macOS build.

I'll have no idea if any of this works for now anyway, as I don't have a DTK, so this is kind of a futile process.

Ian @ un4seen

  • Administrator
  • Posts: 26172
Re: BASS and related libraries for ARM Mac
« Reply #1 on: 30 Jun '20 - 17:15 »
I will look into this.

Ian @ un4seen

  • Administrator
  • Posts: 26172
Re: BASS and related libraries for ARM Mac
« Reply #2 on: 29 Jul '20 - 15:35 »
Here are arm64 (and x86_64) builds of the latest BASS and BASSFLAC/MIDI/OPUS/WV/MPC:

   www.un4seen.com/stuff/bass-macos-arm64.zip

Please report how you get on if you give them a try. Also let me know if you need any other add-ons.
« Last Edit: 25 Aug '20 - 12:56 by Ian @ un4seen »

AlexFreud

  • Posts: 6
Re: BASS and related libraries for ARM Mac
« Reply #3 on: 9 Aug '20 - 17:12 »
Hello!

"Universal binary" BASS version not playing FLAC and M4A files (bass error: unsupported file format) on x86 (I don't have DTK and can't test on arm)

Ian @ un4seen

  • Administrator
  • Posts: 26172
Re: BASS and related libraries for ARM Mac
« Reply #4 on: 10 Aug '20 - 14:38 »
A BASSFLAC build has now been added to the package above for FLAC support, but M4A files should be supported as standard by BASS (with the help of the OS's codecs). Are you having the problem with all M4A files or only specific ones? Please upload one of them to have a look at here:

   ftp.un4seen.com/incoming/

AlexFreud

  • Posts: 6
Re: BASS and related libraries for ARM Mac
« Reply #5 on: 12 Aug '20 - 16:48 »
Rolled back the library to the latest version from the site, FLAC and M4A play great without any plugins.

Example files uploaded to ftp (FLAC and M4A)

Ian @ un4seen

  • Administrator
  • Posts: 26172
Re: BASS and related libraries for ARM Mac
« Reply #6 on: 12 Aug '20 - 17:59 »
That's strange. Please confirm what macOS version you're running. Also, are those files working if you try them with this BASS build?

   www.un4seen.com/stuff/libbass.dylib

AlexFreud

  • Posts: 6
Re: BASS and related libraries for ARM Mac
« Reply #7 on: 12 Aug '20 - 18:05 »
Yes, with this build files working perfectly. I'm running macOS Big Sur 11.0 beta 4 (20A5343i), but i'm also tested on 10.15.6, same result.

Ian @ un4seen

  • Administrator
  • Posts: 26172
Re: BASS and related libraries for ARM Mac
« Reply #8 on: 13 Aug '20 - 17:17 »
Oh yes, I see CoreAudio codec support indeed isn't working on x86_64 with the build above. That's because an AudioFileOpenWithCallbacks call is returning a strange value that looks like it's failing. On closer inspection of the assembly code, the call is actually succeeding but the return value is being corrupted/overwritten. That looks like a bug in the Xcode 7.3.x compiler. Switching to 7.2.x or 8.0 stops the problem happening. Here are Xcode 8.0 rebuilds for you to try:

   www.un4seen.com/stuff/bass-macos-arm64.zip

You may be wondering why an old Xcode version is used. It is to maintain compatibility for as many users/systems as possible. Xcode 12 is needed to build for the arm64 architecture, but that can only target macOS 10.9 at the earliest for x86_64 and doesn't support i386 at all (the next BASS release will still include i386). So an earlier Xcode version needs to be used for those architectures. The current release version on the BASS webpage (and the libbass.dylib posted above) was built with Xcode 9.4.1 on macOS 10.14, but Xcode 12 requires macOS 10.15, which Xcode 9.4.1 doesn't work at all on (missing symbols). In fact, the whole Xcode 8 and 9 series (apart from 8.0) don't work on it. Apple don't make it easy to keep supporting older systems!

AlexFreud

  • Posts: 6
Re: BASS and related libraries for ARM Mac
« Reply #9 on: 14 Aug '20 - 09:03 »
Thank you! This build working perfectly!

Can I ask you to build x86_64/arm version of the OPUS library?

P.s. support for old osx versions is a pain...

Ian @ un4seen

  • Administrator
  • Posts: 26172
Re: BASS and related libraries for ARM Mac
« Reply #10 on: 14 Aug '20 - 13:57 »
Yep, a BASSOPUS build has now been added to the package above, so please redownload to get that.

kode54

  • Posts: 124
Re: BASS and related libraries for ARM Mac
« Reply #11 on: 24 Aug '20 - 02:10 »
Cool! I'll get right to building with this, but I won't be able to test execution, since I don't have the money to acquire test hardware, let alone the final release hardware whenever that happens.

I'll also need BASS_MPC and BASS_WV, if you can. :D

Ian @ un4seen

  • Administrator
  • Posts: 26172
Re: BASS and related libraries for ARM Mac
« Reply #12 on: 25 Aug '20 - 12:55 »
BASSWV and BASS_MPC builds have now been added to the package above. Let me know if any others are needed.

AlexFreud

  • Posts: 6
Re: BASS and related libraries for ARM Mac
« Reply #13 on: 23 Sep '20 - 07:35 »
Hello!

Can you make DSD plugin for arm and x86? Thank you!

Ian @ un4seen

  • Administrator
  • Posts: 26172
Re: BASS and related libraries for ARM Mac
« Reply #14 on: 23 Sep '20 - 16:00 »
As requested, a BASSDSD build has now been added to the package above.

Marek Ledvina

  • Guest
Re: BASS and related libraries for ARM Mac
« Reply #15 on: 30 Nov '20 - 02:30 »
libbassmix.dylib please?

Marek Ledvina

  • Guest
Re: BASS and related libraries for ARM Mac
« Reply #16 on: 30 Nov '20 - 02:33 »
And bassenc.dylib please.

Marek Ledvina

  • Guest
Re: BASS and related libraries for ARM Mac
« Reply #17 on: 30 Nov '20 - 02:38 »
Are those fat binaries or just arm64?

Ian @ un4seen

  • Administrator
  • Posts: 26172
Re: BASS and related libraries for ARM Mac
« Reply #18 on: 30 Nov '20 - 13:48 »
arm64 support should be added to all of the macOS packages on the BASS webpage this week.

Marek Ledvina

  • Guest
Re: BASS and related libraries for ARM Mac
« Reply #19 on: 2 Dec '20 - 11:04 »
Thank you, Ian.

Ian @ un4seen

  • Administrator
  • Posts: 26172
Re: BASS and related libraries for ARM Mac
« Reply #20 on: 4 Dec '20 - 17:05 »
The macOS libraries including arm64 support are up now on the BASS webpage, so please redownload to get that. Note i386 support is still included for compatibility with old macOS versions. If you don't want that, you can use the included makefile to remove it (type "make 64bit").

michael9504

  • Posts: 3
Re: BASS and related libraries for ARM Mac
« Reply #21 on: 26 Oct '22 - 09:55 »
Oh yes, I see CoreAudio codec support indeed isn't working on x86_64 with the build above. That's because an AudioFileOpenWithCallbacks call is returning a strange value that looks like it's failing. On closer inspection of the assembly code, the call is actually succeeding but the return value is being corrupted/overwritten. That looks like a bug in the Xcode 7.3.x compiler. Switching to 7.2.x or 8.0 stops the problem happening. Here are Xcode 8.0 rebuilds for you to try:

   www.un4seen.com/stuff/bass-macos-arm64.zip

You may be wondering why an old Xcode version is used. It is to maintain compatibility for as many users/systems as possible. Xcode 12 is needed to build for the arm64 architecture, but that can only target macOS 10.9 at the earliest for x86_64 and doesn't support i386 at all (the next BASS release will still include i386). So an earlier Xcode version needs to be used for those architectures. The current release version on the BASS webpage (and the libbass.dylib posted above) was built with Xcode 9.4.1 on macOS 10.14, but Xcode 12 requires macOS 10.15, which Xcode 9.4.1 doesn't work at all on (missing symbols). In fact, the whole Xcode 8 and 9 series (apart from 8.0) don't work on it. Apple don't make it easy to keep supporting older systems!

hello,the link cannot open,it's got an 404 error!can u upload this libs?plz

Ian @ un4seen

  • Administrator
  • Posts: 26172
Re: BASS and related libraries for ARM Mac
« Reply #22 on: 26 Oct '22 - 12:09 »
ARM64 support is included in the macOS packages on the BASS webpage, so that separate download is no longer available/needed.

michael9504

  • Posts: 3
Re: BASS and related libraries for ARM Mac
« Reply #23 on: 27 Oct '22 - 10:02 »
ARM64 support is included in the macOS packages on the BASS webpage, so that separate download is no longer available/needed.

so is that mean the libraries in "bass24-osx.zip" is the Universal version for x64 and arm64?

Ian @ un4seen

  • Administrator
  • Posts: 26172
Re: BASS and related libraries for ARM Mac
« Reply #24 on: 27 Oct '22 - 12:21 »
Yes, the macOS libraries are universal, including support for the x86_64/arm64/i386 architectures. If any are unwanted, the makefile included in the BASS package can be used to separate them.