Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"Illegal instruction: 4" on Mid-2010 Mac Mini, MacOS 10.13.6 #5

Open
hbent opened this issue Sep 27, 2018 · 2 comments
Open

"Illegal instruction: 4" on Mid-2010 Mac Mini, MacOS 10.13.6 #5

hbent opened this issue Sep 27, 2018 · 2 comments

Comments

@hbent
Copy link

hbent commented Sep 27, 2018

dmidecode compiled with -O0 -g3 on a Mid-2010 Mac Mini, MacOS 10.13.6. I am not really a Mac person and I'm at a loss as to how to proceed:

bash-3.2# gmake dmidecode
gcc -W -Wall -Wshadow -Wstrict-prototypes -Wpointer-arith -Wcast-qual -Wcast-align -Wwrite-strings -Wmissing-prototypes -Winline -Wundef -D_FILE_OFFSET_BITS=64 -O0 -g3 -Wno-constant-logical-operand -c dmidecode.c -o dmidecode.o
gcc -W -Wall -Wshadow -Wstrict-prototypes -Wpointer-arith -Wcast-qual -Wcast-align -Wwrite-strings -Wmissing-prototypes -Winline -Wundef -D_FILE_OFFSET_BITS=64 -O0 -g3 -Wno-constant-logical-operand -c dmiopt.c -o dmiopt.o
gcc -W -Wall -Wshadow -Wstrict-prototypes -Wpointer-arith -Wcast-qual -Wcast-align -Wwrite-strings -Wmissing-prototypes -Winline -Wundef -D_FILE_OFFSET_BITS=64 -O0 -g3 -Wno-constant-logical-operand -c dmioem.c -o dmioem.o
gcc -W -Wall -Wshadow -Wstrict-prototypes -Wpointer-arith -Wcast-qual -Wcast-align -Wwrite-strings -Wmissing-prototypes -Winline -Wundef -D_FILE_OFFSET_BITS=64 -O0 -g3 -Wno-constant-logical-operand -c util.c -o util.o
gcc -framework CoreServices -framework IOKit dmidecode.o dmiopt.o dmioem.o util.o -o dmidecode
bash-3.2# ./dmidecode

dmidecode 3.1

Getting SMBIOS data from Apple SMBIOS service.
SMBIOS 2.4 present.
44 structures occupying 1946 bytes.

Bad address
Illegal instruction: 4
bash-3.2# gdb ./dmidecode
GNU gdb 6.3.50-20050815 (Apple version gdb-1708) (Mon Aug 15 16:03:10 UTC 2011)
Copyright 2004 Free Software Foundation, Inc.
GDB is free software, covered by the GNU General Public License, and you are
welcome to change it and/or distribute copies of it under certain conditions.
Type "show copying" to see the conditions.
There is absolutely no warranty for GDB. Type "show warranty" for details.
This GDB was configured as "x86_64-apple-darwin"...unable to read unknown load command 0x80000028
Reading symbols for shared libraries ..... done
unable to read unknown load command 0x80000028

(gdb) run
Starting program: /usr/local/src/dmidecode-osx/dmidecode

Program terminated with signal SIGTRAP, Trace/breakpoint trap.
The program no longer exists.

@zengxcgg
Copy link

@hbent
Follow your instructions, Why does it still prompt "illegal instruction: 4".
My computer's operating system is MacOS Catalina v10.15.I hope you can answer my question,thank you.

@kleuter
Copy link

kleuter commented Apr 23, 2020

For some reason, latest code is older than 3.1 relese.

if (NULL != properties)
     CFRelease(properties);

must be commented out.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants