dosdude1, Homebrew, Node (and lot of other applications) throwing illegal hardware instruction on patched Catalina (installed on incompatible machine)

Yesterday I decided to give a try in making my old 7.1 MacBook Pro second chance by upgrading macOS to Catalina with IS NOT supported by Apple.

There is a reason why they want drop support for older architecture but You can squeeze last breath if You can allow for sacrifice in stability or compatibility. Upfront I can say that iMovie crash and I was unable to resolve that issue, other applications used for basic web-dev (phpstorm, mysql, nginx, npm) looks and feel working good but still I would not recommend it for profesional work when disruption in workflow cause money or data loss – for any non critical applications, reading email, watching YT it’s worth of trying.

First step is to upgrade patched macOS dosdude1

When You got Your system set up, and try to execute applications installed with Homebrew (in my case it was node) I got this error:

illegal hardware instruction

After investigation, I was able to locate problem. Applications distributed in Homebrew as bottle are compiled for specified architecture. Authors of Homebrew have valid reason to assume that this compiled software is going to be executed on compatible hardware in correlation with macOS version. There is no change of having C2D CPU in Catalina, here is why compiled code is targeted for newer CPU.

Lucky Homebrew have ability for self compiling any packages, but that operation have exactly same (error) outcome as when installing compiled bottle.

answer to this problem, is in telling Homebrew to set target architecture for older CPU-s.

You can edit this file:

nano /usr/local/Homebrew/Library/Homebrew/extend/os/mac/hardware.rb

and change it’s content to

frozen_string_literal: true
module Hardware
def self.oldest_cpu(version = MacOS.version)
if version >= :mojave
:core2
else
generic_oldest_cpu
end
end
end

Notice edited architecture, when OS is greater or equal to Mojave

After that change we can recompile from source our not working applications by using following command.

brew reinstall -s python

-s stands from source

When trying recompile node, I still got error. After more investigation i found out that Node depend on another packages, that are already installed but not recompiled with new directive. Dirty solution i found is to see what node depend on:

brew info npm

and from following code, read dependencies section to recompile all dependent packages with -s

brew reinstall -s pkg-config
brew reinstall -s icu4c
brew reinstall -s python

After that, we can reinstall node

brew reinstall -s npm

After this operation, node works perfect. You can follow same schematic for any other applications that can be found in Homebrew.

Why it’s important to have oscilloscope and not always rely on multimeter measurement.

Here I post couple pictures of me, fixing LED WALL CLOCK.

There are spikes caused by (DC-DC converter) capacitor that failed (open, lost capacitance, high ESR) and they lead to RTC / MCU freeze and cause undesired operation.

On pictures there is waveform with failed capacitor (notice spikes) and after replacement.

Video:

Good looking capacitor turn’s BAD – why it’s good to have ESR meter

Here i’m working on Dymo PSU that failed, i most like expect leaked capacitor – but everything looks fine… for my eye… but not for ESR meter… we find a open (dead) cap that looks perfectly good and would never expect me to believe it was cause problem!

Also here is my video

How RIP VideoCD disc on linux and play it back on device without cdrom

I have lot of movies on VideoCD that i bought just to have in my collection and are still fun to watch, but DVD drive on my laptop computer many years ago was switched to second HDD caddy. Only way to play them is using external USB DVD drive with is problematic to carry around:) Is there option to easy “RIP” copy VideoCD disc into video file for easy playback?

Yes… on Ubuntu and many other distributions is easy as one command.

vcdxrip -C=/dev/sr0

where /dev/sr0 is our drive, in my case external USB drive
after running that command, we get extracted all .avi files that can be played from HDD using for example VLC player.

3d printer – real case of use on Dell Optiplex 760

Recently i got Dell Optiplex 760 as computer for driving my 3d printer and web browsing while working on my projects.

This is very good computer dedicated for office use, many things could be replaced without use any tools, just by pulling right lever You can for example extract 3.5″ HDD drive without need of using screwdriver, same thing goes to DVD-ROM.

There is also a FDD drive, with today i call obsolete (i still have couple 3.5″ floppy drives around but with USB port, in case i need read – write FDD i can) but having it hard mount on computer it’s not necessary.

I want mount old SSD drive, 2.5″ in place of floppy disc drive, but because it was using latches and special bracket i will left in option throwing it inside without securing in place…. but? i found answer… we have 3d printer.

Before designing anything myself i always check Thingverse to make sure i won’t reinvent wheel second time… and… i get everything i need!
Special adapter that convert 2.5″ SSD for caddy that will swap in place of FDD and also COVER in exactly right size to fill hole after FDD.
I send picture to friend, and he realize that i 3d printed it after i told him to look for it.

Here are pictures of ready print before and after install:

Here You can download STL files for print:

CADDY:

https://www.thingiverse.com/thing:3229517

FDD cover:

https://www.thingiverse.com/thing:3229510

Zello sounding like DMR Motorola aka Talk Permit Tone

Here are two files that make Zello sound more like proper 2 way radio. ( Motorola Mototrbo )

One file is for beginning second for end transmission

Installing Mac OSX from USB on Power MAC G5

My DVD drive was broken on old Power MAC G5.

Im not interested in finding replacement because it’s anyway obsolete but i need to install Mac OSX.

Lucky G5 have Open Firmware that allow booting up straight from USB flash drive and take install painlessly!

First You need to create RAW image of  Your Mac OSX DVD into file.

Than using for example DD on linux put it straight to USB flash-drive.

There many tutorials about that topic.

 

I have Microsoft keyboard while starting up Your mac press and hold four keys at once:

Windows key + alt + o + f

until You get a gray screen with letters “Welcome to Open Firmware” and command prompt.

type

boot ud:3,\\:tbxi

and press enter

after while You will get standard installer just like on DVD.

ud:3 is device id, to not confuse Yourself remove all USB storage devices except that one You want boot from.

 

Here is mine video in real live:

Clansman PRC-350 (RT350) battery adapter mod for use rechargeable AA

Before and after applying mod

 


Warning: Undefined array key 0 in /www/wwwroot/electronicnoobblog.com/wp-content/plugins/wp-google-analytics-scripts/wp-google-analytics-scripts.php on line 602