Bug 203509

Summary: emulators/mame: Update to version 0.166
Product: Ports & Packages Reporter: Paul Boehmer <freebsd>
Component: Individual Port(s)Assignee: Guido Falsi <madpilot>
Status: Closed FIXED    
Severity: Affects Only Me CC: madpilot
Priority: ---    
Version: Latest   
Hardware: Any   
OS: Any   
Attachments:
Description Flags
SVN diff for emulators/mame
none
pthread usage patch none

Description Paul Boehmer 2015-10-02 18:33:48 UTC
Created attachment 161655 [details]
SVN diff for emulators/mame

Update emulators/mame to version 0.166
Comment 1 Guido Falsi freebsd_committer freebsd_triage 2015-10-23 08:25:04 UTC
Created attachment 162376 [details]
pthread usage patch

Hi,

While testing I encountered a problem, it looks minor, but needs to be solved, if possible. I'm looking at a solution too, but in the while post it here for you to look at too.

both mame and mess fail on i386 architecture with this error:

Compiling generated/osd/modules/debugger/qt/mainwindow.moc.c...
Compiling 3rdparty/bgfx/src/bgfx.cpp...
In file included from ../../../../../3rdparty/bgfx/src/bgfx.cpp:6:
In file included from ../../../../../3rdparty/bgfx/src/bgfx_p.h:99:
In file included from ../../../../../3rdparty/bx/include/bx/float4x4_t.h:9:
In file included from ../../../../../3rdparty/bx/include/bx/float4_t.h:22:
../../../../../3rdparty/bx/include/bx/float4_langext.h:211:15: error: expected expression
                result.vf = { _x, _y, _z, _w };
                            ^
../../../../../3rdparty/bx/include/bx/float4_langext.h:218:15: error: expected expression
                result.vu = { _x, _y, _z, _w };
                            ^
../../../../../3rdparty/bx/include/bx/float4_langext.h:226:15: error: expected expression
                result.vu = { val, val, val, val };
                            ^
3 errors generated.
bgfx.make:416: recipe for target '../../../../freebsd/obj/x32/Release/3rdparty/bgfx/src/bgfx.o' failed
gmake[3]: *** [../../../../freebsd/obj/x32/Release/3rdparty/bgfx/src/bgfx.o] Error 1
Makefile:67: recipe for target 'bgfx' failed
gmake[2]: *** [bgfx] Error 2
gmake[2]: *** Waiting for unfinished jobs....

it's some C syntax problem, I will look it in detail later, maybe the solution is really trivial.

Please note that before this I had to patch another problem in file 3rdparty/bx/include/bx/thread.h, it was trying to use function pthread_setname_np() which on FreeBSD is named pthread_set_name_np(). I'm attaching this single patch from files directory. I think this change should be reported upstream.

I'll report back if I fix everything.
Comment 2 commit-hook freebsd_committer freebsd_triage 2015-10-24 11:13:44 UTC
A commit references this bug:

Author: madpilot
Date: Sat Oct 24 11:13:17 UTC 2015
New revision: 400117
URL: https://svnweb.freebsd.org/changeset/ports/400117

Log:
  Update mame/mess to 0.166

  PR:		203509, 203510
  Submitted by:	Paul Boehmer <freebsd at never4evil.com>

Changes:
  head/emulators/mame/Makefile
  head/emulators/mame/distinfo
  head/emulators/mame/files/patch-3rdparty_bx_include_bx_float4__t.h
  head/emulators/mame/files/patch-3rdparty_bx_include_bx_thread.h
  head/emulators/mame/pkg-plist
  head/emulators/mess/Makefile
  head/emulators/mess/pkg-plist
Comment 3 Guido Falsi freebsd_committer freebsd_triage 2015-10-24 11:14:27 UTC
Committed. Thanks!

I added compiler:c11 to force using a modern compiler. GCC included in 9.x is unable to compile this version.

I also had to patch two files to fix some minor issues.