Bug 226687 - emulators/mame: update to 0.195
Summary: emulators/mame: update to 0.195
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Only Me
Assignee: Steve Wills
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-03-18 00:33 UTC by Ryo ONODERA
Modified: 2018-03-28 15:20 UTC (History)
1 user (show)

See Also:


Attachments
Update emulators/mame to 0.195 (43.43 KB, patch)
2018-03-18 00:33 UTC, Ryo ONODERA
no flags Details | Diff
Update emulators/mame to 0.195, rev. 2 (43.44 KB, patch)
2018-03-21 03:46 UTC, Ryo ONODERA
no flags Details | Diff
Update emulators/mame to 0.195, rev. 3 (43.85 KB, patch)
2018-03-24 08:08 UTC, Ryo ONODERA
no flags Details | Diff
Update emulators/mame to 0.195, rev. 4 (43.85 KB, patch)
2018-03-26 19:53 UTC, Ryo ONODERA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Ryo ONODERA 2018-03-18 00:33:31 UTC
Created attachment 191587 [details]
Update emulators/mame to 0.195

Please update emulators/mame to 0.195.
Tested under FreeBSD/amd64 11.1.
Comment 1 Steve Wills freebsd_committer freebsd_triage 2018-03-19 04:55:03 UTC
This fails to build for me, though I'm not sure why, the error isn't very informative:

Compiling src/devices/machine/ie15.cpp...
Archiving liboptional.a...
gmake[2]: Leaving directory '/wrkdirs/usr/ports/emulators/mame/work/mame-mame0195/build/projects/sdl/mame/gmake-freebsd-clang'
gmake[1]: *** [makefile:1389: freebsd_x64_clang] Error 2
gmake[1]: Leaving directory '/wrkdirs/usr/ports/emulators/mame/work/mame-mame0195'

I'm using FreeBSD CURRENT r330240 FWIW.
Comment 2 Steve Wills freebsd_committer freebsd_triage 2018-03-19 06:19:50 UTC
(In reply to Steve Wills from comment #1)
Found it, it needs USE_QT5= moc
Comment 3 Steve Wills freebsd_committer freebsd_triage 2018-03-19 06:35:20 UTC
(In reply to Steve Wills from comment #2)
Err, buildtools, not moc:

USE_QT5=        buildtools gui qmake_build widgets

Anyway, made some other changes to make portlint happy and avoided deleting the files/target.ini.in and files/pkg-message.in as I don't understand why they were removed in the patch and they are still used in the port Makefile. Will do more testing and commit.
Comment 4 Steve Wills freebsd_committer freebsd_triage 2018-03-19 14:05:58 UTC
Failed to build on 10.3, so I switched to USES=compiler:c++14-lang but even then I get:

Compiling src/lib/netlist/nl_setup.cpp...                                                                                                                               
In file included from ../../../../../src/lib/netlist/nl_setup.cpp:8:                                                                                                            
In file included from ../../../../../src/lib/netlist/plib/palloc.h:11:                                                                                                
In file included from ../../../../../src/lib/netlist/plib/pstring.h:12:                                                            
In file included from /usr/include/c++/v1/string:439:                
In file included from /usr/include/c++/v1/algorithm:627:
/usr/include/c++/v1/utility:284:11: error: call to implicitly-deleted copy constructor of 'std::__1::unique_ptr<netlist::logic_family_desc_t, std::__1::default_delete<netlist::logic_family_desc_t> >'
          second(__p.second)                                          
          ^      ~~~~~~~~~~

Not sure of the solution there, any ideas?
Comment 5 Steve Wills freebsd_committer freebsd_triage 2018-03-19 14:14:16 UTC
(In reply to Steve Wills from comment #4)
Looks like the same issue was hit in bug 205097 which also tried to update this port. Perhaps we just mark this broken on 10.x?
Comment 6 Ryo ONODERA 2018-03-19 14:16:42 UTC
(In reply to Steve Wills from comment #3)

My patch will not remove pkg-message and target.ini. It has no diffs for these files.

And I will run pkglint and rewite my patch.
Comment 7 Ryo ONODERA 2018-03-19 14:17:22 UTC
(In reply to Steve Wills from comment #3)
Thank you. I will update my patch with your suggestion.
Comment 8 Steve Wills freebsd_committer freebsd_triage 2018-03-19 14:30:02 UTC
(In reply to Ryo ONODERA from comment #6)
Sorry, I think I made a mistake somewhere between "git apply ..." and "make makepatch". Perhaps run "make makepatch" on your end before sending the updated patch so that the patch files match the expected format.
Comment 9 Ryo ONODERA 2018-03-21 03:46:09 UTC
Created attachment 191682 [details]
Update emulators/mame to 0.195, rev. 2

Partially make portlint happier.
Comment 10 Steve Wills freebsd_committer freebsd_triage 2018-03-21 14:32:31 UTC
(In reply to Ryo ONODERA from comment #9)

Fails to build on 10.3:

Generating ../build/projects/sdl/mame/gmake-freebsd-clang/castool.make...
Generating ../build/projects/sdl/mame/gmake-freebsd-clang/floptool.make...
Generating ../build/projects/sdl/mame/gmake-freebsd-clang/imgtool.make...
Done. Generated 357/357 projects.
gmake -C build/projects/sdl/mame/gmake-freebsd-clang config=release64 precompile
gmake[2]: Entering directory '/wrkdirs/usr/ports/emulators/mame/work/mame-mame0195/build/projects/sdl/mame/gmake-freebsd-clang'
Creating ../../../../freebsd/bin/x64/Release
Precompiling src/emu/emu.h...
Compiling src/emu/drivers/empty.cpp...
../../../../../src/emu/drivers/empty.cpp:72:1: error: reference to type 'const emu::detail::device_type_impl' could not bind to an lvalue of type 'const auto'
GAME( 2007, ___empty, 0, ___empty, 0, empty_state, 0, ROT0, "MAME", "No Driver Loaded", MACHINE_NO_SOUND_HW )
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
In file included from ../../../../../src/emu/drivers/empty.cpp:1:
In file included from /wrkdirs/usr/ports/emulators/mame/work/mame-mame0195/build/projects/sdl/mame/gmake-freebsd-clang/../../../../../src/emu/emu.h:87:
/wrkdirs/usr/ports/emulators/mame/work/mame-mame0195/build/projects/sdl/mame/gmake-freebsd-clang/../../../../../src/emu/gamedrv.h:178:2: note: expanded from macro 'GAME'
        GAME_DRIVER_TYPE(NAME, CLASS, FLAGS),                               \
        ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/wrkdirs/usr/ports/emulators/mame/work/mame-mame0195/build/projects/sdl/mame/gmake-freebsd-clang/../../../../../src/emu/gamedrv.h:164:46: note: expanded from macro 'GAME_DRIVER_TYPE'
#define GAME_DRIVER_TYPE(NAME, CLASS, FLAGS) \
                                             ^
1 error generated.
gmake[3]: *** [precompile.make:308: ../../../../freebsd/obj/x64/Release/src/emu/drivers/empty.o] Error 1
gmake[2]: *** [Makefile:79: precompile] Error 2
gmake[2]: Leaving directory '/wrkdirs/usr/ports/emulators/mame/work/mame-mame0195/build/projects/sdl/mame/gmake-freebsd-clang'
gmake[1]: *** [makefile:1388: freebsd_x64_clang] Error 2
gmake[1]: Leaving directory '/wrkdirs/usr/ports/emulators/mame/work/mame-mame0195'
===> Compilation failed unexpectedly.
Comment 11 Ryo ONODERA 2018-03-22 16:09:47 UTC
(In reply to Steve Wills from comment #10)
It seems that a output of "c++ -E -C -P" with clang 3.4.1
in FreeBSD/amd64 10.3-RELEASE-p24 is correct as C++14.
I have no idea about why this error happens.
Comment 12 Ryo ONODERA 2018-03-24 08:08:48 UTC
Created attachment 191774 [details]
Update emulators/mame to 0.195, rev. 3

For FreeBSD 10, GCC 4.9 or later is useful to avoid the build failures.
Comment 13 Steve Wills freebsd_committer freebsd_triage 2018-03-26 16:38:28 UTC
(In reply to Ryo ONODERA from comment #12)
Unfortunately, this still fails to build on 10.3 for me:

gmake[2]: Entering directory '/wrkdirs/usr/ports/emulators/mame/work/mame-mame0195/build/projects/sdl/mame/gmake-freebsd'
Creating ../../../../freebsd/bin/x64/Release
Precompiling src/emu/emu.h...
Compiling src/emu/drivers/empty.cpp...

g++6: internal compiler error: Bus error (program cc1plus)
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://gcc.gnu.org/bugs.html> for instructions.
gmake[3]: *** [precompile.make:308: ../../../../freebsd/obj/x64/Release/src/emu/drivers/empty.o] Error 4
gmake[2]: *** [Makefile:79: precompile] Error 2
gmake[2]: Leaving directory '/wrkdirs/usr/ports/emulators/mame/work/mame-mame0195/build/projects/sdl/mame/gmake-freebsd'
gmake[1]: *** [makefile:1368: freebsd_x64] Error 2
gmake[1]: Leaving directory '/wrkdirs/usr/ports/emulators/mame/work/mame-mame0195'
===> Compilation failed unexpectedly.

I tried gcc 4 and got an error that at least gcc 5 was required. Trying gcc 5, 6 and 7 and all produce internal compiler errors. Perhaps it's a local issue. Are you able to build on 10.3? If not, perhaps we just mark this broken on 10.x?
Comment 14 Ryo ONODERA 2018-03-26 19:53:10 UTC
Created attachment 191848 [details]
Update emulators/mame to 0.195, rev. 4

GCC 4.9+ part is incorrect. emulators/mame requires GCC 6 under FreeBSD/amd64 10.3.
Comment 15 Ryo ONODERA 2018-03-26 19:55:31 UTC
(In reply to Steve Wills from comment #13)
Sorry. My patch is incorrect. I have attached rev. 4.
And with this revision, emulators/mame builds fine with GCC 6 for me.
My FreeBSD/amd64 10.3-RELEASE-p24 is almost freshly installed.
I think that your the internal compiler errors are your local issues.
Comment 16 Ryo ONODERA 2018-03-26 19:56:47 UTC
(In reply to Ryo ONODERA from comment #15)
I have forgotten to mension about GCC 5.
With GCC 5, I have gotten another C++ error.
And I uses GCC 6.
Comment 17 Steve Wills freebsd_committer freebsd_triage 2018-03-27 01:37:25 UTC
(In reply to Ryo ONODERA from comment #15)
Can you send me the log for this? I tried building on another host and also got the ICE, but if you can send me the log I'll go ahead and commit.
Comment 18 Ryo ONODERA 2018-03-28 13:08:39 UTC
(In reply to Steve Wills from comment #17)
I have send you a URI of the log.
See:
https://deuterium.ryoon.net/pub/FreeBSD/ports/emulators_mame-0.195-gcc6-10.3REL.log
Comment 19 commit-hook freebsd_committer freebsd_triage 2018-03-28 15:19:31 UTC
A commit references this bug:

Author: swills
Date: Wed Mar 28 15:18:55 UTC 2018
New revision: 465815
URL: https://svnweb.freebsd.org/changeset/ports/465815

Log:
  emulators/mame: update to 0.195

  PR:		226687
  Submitted by:	Ryo ONODERA <ryo@tetera.org>

Changes:
  head/emulators/mame/Makefile
  head/emulators/mame/distinfo
  head/emulators/mame/files/patch-3rdparty_bgfx_include_bgfxplatform.h
  head/emulators/mame/files/patch-3rdparty_bx_include_bx_float4__t.h
  head/emulators/mame/files/patch-3rdparty_bx_include_bx_platform.h
  head/emulators/mame/files/patch-3rdparty_bx_include_bx_thread.h
  head/emulators/mame/files/patch-3rdparty_bx_src_mutex.cpp
  head/emulators/mame/files/patch-3rdparty_bx_src_thread.cpp
  head/emulators/mame/files/patch-3rdparty_lzma_C_CpuArch.h
  head/emulators/mame/files/patch-makefile
  head/emulators/mame/files/patch-scripts_toolchain.lua
  head/emulators/mame/files/patch-src__osd__eigccx86.h
  head/emulators/mame/files/patch-src__osd__eminline.h
  head/emulators/mame/files/patch-src_emu_webengine.c
  head/emulators/mame/files/patch-src_lib_netlist_plib_pparser.c
  head/emulators/mame/files/patch-src_lib_netlist_plib_pparser.cpp
  head/emulators/mame/files/patch-src_lib_netlist_plib_pparser.h
  head/emulators/mame/files/patch-src_osd_modules_file_posixptty.cpp
  head/emulators/mame/files/patch-src_osd_sdl_sdlprefix.h
  head/emulators/mame/files/pkg-message.in
  head/emulators/mame/pkg-plist
Comment 20 Steve Wills freebsd_committer freebsd_triage 2018-03-28 15:20:21 UTC
Committed, thanks!