cartr / homebrew-qt4

Homebrew tap for Qt4 and dependent formulae on Sierra
BSD 2-Clause "Simplified" License
105 stars 42 forks source link

Illegal Instruction: 4 #29

Closed sandvige closed 7 years ago

sandvige commented 7 years ago

Hello,

Would it be possible to provide bottles compiled with more backward compatibles options to avoid the "Illegal Instruction: 4" on old CPUs? It looks like you're building everything on recent machines

Some people says it would be better to compile with LLVM/GCC instead of CLANG to avoid such a problem, what do you think?

Maybe there's an -mmarch=core2? It probably makes no sense to use recent arch compilation (like corei7) since Qt4 was designed and developed when these specific instructions wasn't existing :)

Thanks,

cartr commented 7 years ago

Sorry to hear the bottles aren't working on your system. Could you please run brew config and copy-paste the output into a Gist, so I can see the details of the system you're running on?

AFAIK I'm using the same process as the Homebrew Core people to build my bottles. Do you see similar errors when you try to use Qt 5?

sandvige commented 7 years ago

Hello, we're distributing the libs through a bundle we're building using macdeployqt. The machine I'm using to build is pretty recent (core i7), and everything is working well, but on our customer machine, this is not the same story. Unfortunately, they don't have homebrew installed, so I cannot give you a brew config sample. Here are the machines we've tested and isolated the issue (with the CPU model):

We cannot test with Qt 5. I will try to run a VM with VirtualBox, using an old emulated CPU (like a Core2Duo), hoping the instruction set will be old enough, and I will try to build the bottle from sources (with brew -s).

sandvige commented 7 years ago

I've been able to tweak a Travis CI script to bundle my apps with the pre-compiled bottle, and it is working on some of the previously failing Mac. It looks like your bottles are OK, so I now need to understand what flag to pass to the compiler of my application to use an "enough old" instruction set...