Previous Thread
Next Thread
Print Thread
Joined: Sep 2021
Posts: 41
Likes: 3
S
Member
Member
S Offline
Joined: Sep 2021
Posts: 41
Likes: 3
Hello, trying to compile Mame 0.270 on Linux 32 bit I get the following error message:

Code
Compiling src/emu/uiinput.cpp...
Compiling src/emu/validity.cpp...
../../../../../src/emu/validity.cpp: In function ‘void {anonymous}::validate_integer_semantics()’:
../../../../../src/emu/validity.cpp:179:38: error: static assertion failed: PTR64 flag enabled, but was compiled for 32-bit target

  179 |         static_assert(sizeof(void *) == 8, "PTR64 flag enabled, but was compiled for 32-bit target\n");
      |                       ~~~~~~~~~~~~~~~^~~~
make[2]: *** [emu.make:1410: ../../../../linux_gcc/obj/x64/Release/src/emu/validity.o] Error 1
make[1]: *** [Makefile:94: emu] Error 2
make: *** [makefile:1290: linux_x64] Error 2

Can that PTR64 flag be disabled?

Joined: Feb 2014
Posts: 1,180
Likes: 215
G
Very Senior Member
Very Senior Member
G Offline
Joined: Feb 2014
Posts: 1,180
Likes: 215
well you can try to set PTR64=0 in the makefile to see if that will work


knoppix (livecd/liveflash based on debian) will compile mame264 and that is based on i386 packages and 32bit. It hasn't been updated for 3 years which is why it won't compile anything more recent than 264, because of changes needing a new compiler version.

Last edited by Golden Child; 02/27/25 09:20 PM.
Joined: Feb 2004
Posts: 2,626
Likes: 332
Very Senior Member
Very Senior Member
Joined: Feb 2004
Posts: 2,626
Likes: 332
I build every MAME release for 32-bit i686 Linux. What actual make command are you using? Just something like make PTR64=0 TOOLS=1 without any other options works.

Joined: Sep 2021
Posts: 41
Likes: 3
S
Member
Member
S Offline
Joined: Sep 2021
Posts: 41
Likes: 3
Originally Posted by Golden Child
well you can try to set PTR64=0 in the makefile to see if that will work


knoppix (livecd/liveflash based on debian) will compile mame264 and that is based on i386 packages and 32bit. It hasn't been updated for 3 years which is why it won't compile anything more recent than 264, because of changes needing a new compiler version.

I'm using Slackware 32 bit kernel 5.15, I've chosen 0.270 coz I've been able to build it successfully on the 64 bit version of Slack, gcc 11.2.0.

Originally Posted by Vas Crabb
I build every MAME release for 32-bit i686 Linux. What actual make command are you using? Just something like make PTR64=0 TOOLS=1 without any other options works.

The command I've used is:

Code
make SOURCES=src/mame/pc,src/mame/hp,src/mame/sgi

I'll try adding PTR64=0 TOOLS=1. Thank you so much.

Last edited by stef-ux; 02/28/25 12:55 PM.
Joined: Feb 2004
Posts: 2,626
Likes: 332
Very Senior Member
Very Senior Member
Joined: Feb 2004
Posts: 2,626
Likes: 332
You should compile the 32-bit binary on an equivalent 64-bit system if possible (same libc, libstdc++, SDL2, etc.). Install the 32-bit development library packages on your 64-bit system, compile on the 64-bit system, and copy the binary to the 32-bit system. The 64-bit compiler will be substantially faster.

What’s your actual reason for wanting MAME on a 32-bit system? Performance takes a pretty big hit.

Joined: Sep 2021
Posts: 41
Likes: 3
S
Member
Member
S Offline
Joined: Sep 2021
Posts: 41
Likes: 3
Originally Posted by Vas Crabb
You should compile the 32-bit binary on an equivalent 64-bit system if possible (same libc, libstdc++, SDL2, etc.). Install the 32-bit development library packages on your 64-bit system, compile on the 64-bit system, and copy the binary to the 32-bit system. The 64-bit compiler will be substantially faster.

Yes, it's what I'm doing.

My main PC is a 64 bit i5 10600 32 Gb RAM box running Slackware 15_64. It has a multilib 32 bit environment to build 32 bit programs.

The settings you suggested just worked, thank you so much. smile

Quote
What’s your actual reason for wanting MAME on a 32-bit system? Performance takes a pretty big hit.

In short: coz I'm a poor (old) boy smile

I'm not interested in running performing games but just old OSs and the relevant software.
On my 64 bit PC I'm running some machines and would like to run them on my Pentium IV 32 bit PC as well, though with some efforts.
It would be a sort of backup PC, in case the main one got broken.

I got a ten of old PCs an I'm trying to get them communicate each other.
I've installed Tinycore Linux (kernel 6) on my Pentium 166 PC and thanks to a USB 1.1 port I've been able to run wifi and tethering on it, downloading stuffs via my mobile phone.

Thst's all. smile

Last edited by stef-ux; 03/01/25 10:22 AM.
1 member likes this: exidyboy

Moderated by  R. Belmont 

Link Copied to Clipboard
Who's Online Now
2 members (robcfg, 1 invisible), 136 guests, and 3 robots.
Key: Admin, Global Mod, Mod
ShoutChat
Comment Guidelines: Do post respectful and insightful comments. Don't flame, hate, spam.
Forum Statistics
Forums9
Topics9,356
Posts122,431
Members5,082
Most Online1,283
Dec 21st, 2022
Our Sponsor
These forums are sponsored by Superior Solitaire, an ad-free card game collection for macOS and iOS. Download it today!

Superior Solitaire
Powered by UBB.threads™ PHP Forum Software 8.0.0