The following commit has been merged in the master branch:
commit b584a05546ff63557f57a15de5c6591d9d423fd2
Author: Jordi Mallach <[email protected]>
Date:   Fri May 13 04:39:00 2011 +0200

    Enable builds of MESS.
    
    * Rework debian/rules as needed to make mess fit in.
    * Create a minimal mess.ini (identical to mame.ini).
    * Add castool and imgtool to mame-tools.

diff --git a/debian/changelog b/debian/changelog
index e90a66b..cc50294 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -12,6 +12,9 @@ mame (0.142-2) UNRELEASED; urgency=low
   * Setup the source dir to enable building mess even if its source is in
     a mess subdir, by creating necessary symlinks and directory renames
     before the build, and restoring everything on clean.
+  * Rework debian/rules as needed to make mess fit in.
+  * Create a minimal mess.ini (identical to mame.ini).
+  * Add castool and imgtool to mame-tools.
 
  -- Jordi Mallach <[email protected]>  Thu, 12 May 2011 16:37:27 +0200
 
diff --git a/debian/control b/debian/control
index 8dd5294..2c43bd4 100644
--- a/debian/control
+++ b/debian/control
@@ -43,14 +43,17 @@ Description: Tools for Multiple Arcade Machine Emulator 
(MAME)
  machines. These ROMs are subject to copyright and it is in most of the cases
  illegal to use them if you do not own the arcade machine.
  .
- This package provides tools to be used with MAME :
-  - chdman (MAME Compressed Hunks of Data CHD manager)
-  - jedutil (binary to/from JEDEC file converter)
-  - ldresample (Laserdisc audio synchronizer and resampler)
-  - ldverify (Laserdisc AVI/CHD verifier)
-  - romcmp (ROM comparison utility program)
-  - testkeys (Keyboard code viewer)
-  - unidasm (Generic MAME disassembler)
+ This package provides tools to be used with MAME and MESS. It currently
+ contains:
+  castool -- generic cassette manipulation tool for MESS
+  chdman -- MAME Compressed Hunks of Data CHD manager
+  imgtool -- generic image manipulation tool for MESS
+  jedutil -- binary to/from JEDEC file converter
+  ldresample -- Laserdisc audio synchronizer and resampler
+  ldverify -- Laserdisc AVI/CHD verifier
+  romcmp -- ROM comparison utility program
+  testkeys -- keyboard code viewer
+  unidasm -- generic MAME disassembler
 
 Package: mess
 Architecture: amd64 i386 kfreebsd-amd64 kfreebsd-i386 powerpc s390
diff --git a/debian/mame-tools.install b/debian/mame-tools.install
index f1b8b97..bef5e9d 100644
--- a/debian/mame-tools.install
+++ b/debian/mame-tools.install
@@ -1,8 +1,9 @@
+castool     usr/bin/
 chdman      usr/bin/
+imgtool     usr/bin/
 jedutil     usr/bin/
 ldresample  usr/bin/
 ldverify    usr/bin/
 romcmp      usr/bin/
 testkeys    usr/bin/
 unidasm     usr/bin/
-#FIXME# Add MESS tools here
diff --git a/debian/mess.examples b/debian/mess.examples
new file mode 100644
index 0000000..7b7f82e
--- /dev/null
+++ b/debian/mess.examples
@@ -0,0 +1 @@
+default.mess.ini
diff --git a/debian/mess.ini b/debian/mess.ini
new file mode 100644
index 0000000..09fc95e
--- /dev/null
+++ b/debian/mess.ini
@@ -0,0 +1,34 @@
+# Default MESS configuration file for Debian
+# See /usr/share/doc/mess/examples/default.mess.ini
+# for an example file with all possible options.
+
+# Allow per-user mess.ini configuration files
+inipath                  $HOME/.mess;/etc/mess
+
+# Default data search paths
+rompath                  $HOME/mess/roms;/usr/share/games/mess/roms
+hashpath                 $HOME/mess/hash;/usr/share/games/mess/hash
+samplepath               $HOME/mess/samples;/usr/share/games/mess/samples
+artpath                  $HOME/mess/artwork;/usr/share/games/mess/artwork
+ctrlrpath                $HOME/mess/ctrlr;/usr/share/games/mess/ctrlr
+fontpath                 $HOME/mess/fonts;/usr/share/games/mess/fonts
+cheatpath                $HOME/mess/cheat;/usr/share/games/mess/cheat
+crosshairpath            $HOME/mess/crosshair;/usr/share/games/mess/crosshair
+
+# Default data output paths
+cfg_directory            $HOME/.mess/cfg
+nvram_directory          $HOME/.mess/nvram
+memcard_directory        $HOME/.mess/memcard
+input_directory          $HOME/.mess/inp
+state_directory          $HOME/.mess/sta
+snapshot_directory       $HOME/.mess/snap
+diff_directory           $HOME/.mess/diff
+comment_directory        $HOME/.mess/comments
+
+# Debian feature defaults
+# Set video to 'opengl' if DRI is enabled and reliable on your hardware
+video                    soft
+# Set multithreading to '1' if you have more than one core
+multithreading           0
+# Set joystick to 1 if you have a joystick available
+joystick                 0
diff --git a/debian/mess.install b/debian/mess.install
index e0e87fb..942b583 100644
--- a/debian/mess.install
+++ b/debian/mess.install
@@ -1,12 +1,11 @@
-#FIXME# I have no idea of what we need here
 mess                           usr/games
 
-#FIXMEsrc/osd/sdl/keymaps              usr/share/games/mame
+src/osd/sdl/keymaps            usr/share/games/mess
 
-#FIXMEdebian/install/mame.xpm          usr/share/pixmaps
-#FIXMEdebian/install/mame.desktop      usr/share/applications
+#FIXMEdebian/install/mess.xpm          usr/share/pixmaps
+#FIXMEdebian/install/mess.desktop      usr/share/applications
 
-#FIXMEdebian/mess.ini                  etc/mame
+debian/mess.ini                        etc/mame
 
-mess/artwork                   usr/share/games/mess/artwork
-mess/hash/*                    usr/share/games/mess/hash
+messdir/artwork                        usr/share/games/mess
+messdir/hash/*                 usr/share/games/mess/hash
diff --git a/debian/rules b/debian/rules
index 318ce6c..e42cd5a 100755
--- a/debian/rules
+++ b/debian/rules
@@ -42,6 +42,13 @@ DEB_MAME_OPTS = \
     LDFLAGSEMULATOR="-Wl,--as-needed" \
     NOWERROR=1
 
+DEB_MESS_OPTS = \
+    $(DEB_MAME_OPTS) \
+    OPT_FLAGS="-D'INI_PATH=\"/etc/mess\"'" \
+    FULLNAME=mess \
+    TARGET=mess \
+    SUBTARGET=mess
+
 # Override make variables for specific archs
 # Linux architectures
 ifeq ($(DEB_HOST_ARCH),amd64)
@@ -103,14 +110,20 @@ override_dh_auto_build:
        # the code in a mess directory, as that's how dpkg components
        # work. Move dirs and create symlinks for MESS stuff outside its
        # component directory to enable its build.
-       mv hash hash.mame
-       ln -s ../../hash.mame/megatech.xml mess/hash/
-       ln -s mess/hash hash
-       ln -s mess/artwork artwork
-       ln -s ../mess/src/mess src/mess
+       [ -d mess ] && mv mess messdir
+       [ -d hash ] && mv hash hash.mame
+       [ ! -L messdir/hash/megatech.xmk ] && \
+         ln -s ../../hash.mame/megatech.xml messdir/hash
+       [ ! -L hash ] && ln -s messdir/hash hash
+       [ ! -L artwork ] && ln -s messdir/artwork artwork
+       [ ! -L sysinfo.dat ] && ln -s messdir/sysinfo.dat sysinfo.dat
+       [ ! -L src/mess ] && ln -s ../messdir/src/mess src/mess
        $(MAKE) -j3 $(DEB_MAME_OPTS) all
        $(CURDIR)/mame -createconfig
        mv mame.ini default.mame.ini
+       $(MAKE) -j3 $(DEB_MESS_OPTS) all
+       $(CURDIR)/mess -createconfig
+       mv mess.ini default.mess.ini
 
 # dh_installchangelogs doesn't know about whatsnew.txt,
 # so we need to make an explicit call
@@ -127,9 +140,15 @@ override_dh_installdocs:
 
 clean:
        $(MAKE) $(DEB_MAME_OPTS) clean
-       # Undo MESS modifications. This could be a bit more robust.
-       -rm artwork hash src/mess mess/hash/megatech.xml
-       -mv hash.mame hash
+       -rm default.mame.ini default.mess.ini
+       # Undo MESS modifications.
+       [ -L artwork ] && rm artwork
+       [ -L hash ] && rm hash
+       [ -L sysinfo.dat ] && rm sysinfo.dat
+       [ -L src/mess ] && rm src/mess
+       [ -L messdir/hash/megatech.xml ] && rm messdir/hash/megatech.xml
+       [ -d hash.mame ] && mv hash.mame hash
+       [ -d messdir ] && mv messdir mess
 
 # Convert upstream sources from zip to tar.bz2
 VERSION := $(shell dpkg-parsechangelog | sed -ne 's/^Version: \(.*\)-.*/\1/p')

-- 
packaging for the mame arcade game emulator

_______________________________________________
Pkg-games-commits mailing list
[email protected]
http://lists.alioth.debian.org/mailman/listinfo/pkg-games-commits

Reply via email to