Re: [flac-dev] Enabling universal building of libFLAC

2022-09-19 Thread Martijn van Beurden
Op zo 18 sep. 2022 om 19:08 schreef Robert Kausch : > As an integrator targeting four different architectures on Mac (ppc, > x86, x86-64 and aarch64), I build all the libraries separately for each > architecture and then combine the resulting binaries into a universal > binary using the lipo

Re: [flac-dev] Enabling universal building of libFLAC

2022-09-18 Thread Robert Kausch
As an integrator targeting four different architectures on Mac (ppc, x86, x86-64 and aarch64), I build all the libraries separately for each architecture and then combine the resulting binaries into a universal binary using the lipo tool. That's the standard way to build universal binaries

Re: [flac-dev] Enabling universal building of libFLAC

2022-09-18 Thread brianw
Ah, yes, the preprocessor defines. Now I see what you're talking about. Those are crucial because there is often code specific to a particular architecture. NeXT and Apple have supported up to four-processor multi-architecture builds since the nineties. I don't know whether they modified the

Re: [flac-dev] Enabling universal building of libFLAC

2022-09-18 Thread Martijn van Beurden
Op zo 18 sep. 2022 om 16:06 schreef brianw : > When you refer to "runtime variables," do you really mean build time? > Yes, build time. That was formulated wrong. I would assume that the source code does not need to change in order to > support multiple architectures on macOS, but the compiler

Re: [flac-dev] Enabling universal building of libFLAC

2022-09-18 Thread brianw
When you refer to "runtime variables," do you really mean build time? It's not really an option to wait until flac runs to determine the runtime architecture. I suspect you mean make variables that are used at build time. I would assume that the source code does not need to change in order to

Re: [flac-dev] Enabling universal building of libFLAC

2022-09-18 Thread Martijn van Beurden
Op zo 18 sep. 2022 11:55 schreef Cristian Adam : > Hi, > > Building with CMake for both x86_64 and aarch64 for MacOS is as easy as > setting the CMake configuration > variable: "-DCMAKE_OSX_ARCHITECTURES=x86_64;arm64" when configuring the > project. > That might be enough to make CMake

Re: [flac-dev] Enabling universal building of libFLAC

2022-09-18 Thread Cristian Adam
Hi, Building with CMake for both x86_64 and aarch64 for MacOS is as easy as setting the CMake configuration variable: "-DCMAKE_OSX_ARCHITECTURES=x86_64;arm64" when configuring the project. See How do I build cmake from source as universal(arm64 and x86_64) binary on Mac? - Usage - CMake