[Rpcemu] Autotools build environment

Kai Thomsen kai.thomsen at gmx.de
Sun Oct 7 00:40:34 BST 2007


Hi all,

here's a patch for the Autoconf & Automake build files:

  * Unify the build process for Windows (MinGW/MSYS), Linux (x86 &
    x86-64) and Mac OS X (untested).

  * Introduce the configure options `--enable-dynarec' and
    `--disable-dynarec' for specifying whether to include the dynamic
    recompiler or the standard CPU emulation -- the latter is default.
    The DynaRec feature is marked as experimental in the `configure
    --help' text. `make clean' is recommended after switching the
    option.

  * Introduce the configure options `--enable-debug' and
    `--disable-debug' for specifying whether to build a debug
    executable. Default is non-debug. CFLAGS are set as follows:

       --enable-debug => "-Wall -O0 -g -D_DEBUG"
      --disable-debug => "-Wall -O2"

  * Introduce endianness checking to allow for PPC (Mac) builds. On PPC
    (and other big-endian architectures, of course), WORDS_BIGENDIAN is
    #defined.

  * Change vidc20.c to use the WORDS_BIGENDIAN #define instead of
    _RPCEMU_BIG_ENDIAN.

(Authors: Christof Efkemann, Kai Thomsen)

After applying the patch, you'll have to run `autoreconf --force
--install' (or likewise) in order to rebuild `configure',
`config.h.in', `aclocal.m4' and `Makefile.in'.

Unfortunately, I can't seem to find a MinGW binary distribution of
Allegro that contains the allegro.m4 file, which the Autoconf-processed
configure.ac needs, so to be able to run `autoreconf' on MinGW, you
should:

  - extract allegro.m4 from the DOS/Windows Allegro sources (it's
    located under `misc') and
  - copy it to the /share/aclocal directory (on my machine, this
    corresponds to D:\msys\1.0\share\aclocal) or to RPCemu's `src'
    directory

In case Allegro's header and library files aren't located on the common
default paths, e. g., if you've installed Allegro in your home
directory, it's possible to specify custom paths by running `configure'
like this:

  ./configure CPPFLAGS="-I/path/to/include" LDFLAGS="-L/path/to/lib"

The following auto{conf,make} versions have worked for me on

  - Linux x86: autoconf 2.61, automake 1.10
  - Linux x86-64: ditto
  - Windows: autoconf 2.56, automake 1.7.1

By the way, I encountered two things on Windows (MSYS/MinGW):

  * The cmos.ram currently in SVN has a MouseType setting that doesn't
    work. `*Configure MouseType 0' unfreezes the pointer.

  * rpclog() in rpc-win.c uses a hardcoded absolute file path
    (apparently left over from debugging) that leads to a segmentation
    fault. Alex Waugh already mentioned this.


Cheers,
--Kai
-------------- next part --------------
A non-text attachment was scrubbed...
Name: rpcemu-autotools-svn89.patch
Type: text/x-patch
Size: 8824 bytes
Desc: not available
Url : http://www.riscos.info/pipermail/rpcemu/attachments/20071007/c53c3603/attachment.bin 


More information about the Rpcemu mailing list