.\" .\" srecord - manipulate eprom load files .\" Copyright (C) 2003, 2006-2011, 2013, 2014 Peter Miller .\" .\" This program is free software; you can redistribute it and/or modify .\" it under the terms of the GNU General Public License as published by .\" the Free Software Foundation; either version 3 of the License, or .\" (at your option) any later version. .\" .\" This program is distributed in the hope that it will be useful, .\" but WITHOUT ANY WARRANTY; without even the implied warranty of .\" MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU .\" General Public License for more details. .\" .\" You should have received a copy of the GNU General Public License .\" along with this program. If not, see . .\" .ad l .hy 0 .so etc/version.so .nf

# SRecord \*(v)
For Windows

The Cygwin tools are ports of the popular GNU development tools and utilities for Windows 95, 98, NT, XP, Vista, etc. They function by using the Cygwin library which provides a UNIX-like API on top of the Win32 API.

This means that you can compile SRecord for Windows 95, 98, NT, XP, Vista, etc. SRecord was tested on Windows in this way. Other tools, such as Nutcracker, are expected to work but have not been confirmed.

DJGPP is a complete 32-bit C++ development system for Intel 80386 (and higher) PCs running DOS. It includes ports of many GNU development utilities.

Once you have Cygwin or DJGPP installed, simply follow the instructions in the BUILDING file, as if it were Unix.

Pre-built MS Windows binaries are available from sourceforge.net, although they tend to lag behind the current release.

These instructions have been improved greatly with the assistance of Jens Heilig <jens@familie-heilig.net>, who is often the person who builds the MS Windows binaries you see on SourceForge. Thank you, Jens.

## FAQ

Please, please, can you just build it for me?

No. The author rarely uses Windows for anything. No.

Besides, SRecord is Open Source. That means you can get the source code. That means you can build it youself.

If you let the author know the URL to get your compiled binaries from, after some-one else confirms they work, he will upload them to SourceForge in the srecord-win32 directory. If a Windows user has built the most recent SRecord version for windows, it will be available in the \*(v) directory as the srecord-\*(v)-win32.zip file. If the link is broken, it means no MS Windows user has built SRecord and sent the author a zip file for upload.

## Prerequisites

There are three pieces of software that must be installed before you can build SRecord for Windows.

MinGW
  Download and install `mingw-get-inst` (I used version 20110530) from the MinGW project page. Select C++ and MinGW Developer Toolkit during installation.

  Start MinGW Shell from the Windows Start Menu. Install additional packages by entering following commands at the prompt: (the “`$`” sign indicates the shell-prompt, do not type it)

  >     $ mingw-get.exe install msys-groff-ext
  >     $ mingw-get.exe install gettext
  >     $

The Boost Library
  Download and install the Boost library from http://ascend4.org/Binary_installer_for_Boost_on_MinGW. Copy the newly installed files to you MinGW directory:

  >     $ cp boost-install-dir/lib/* /lib/
  >     $ cp -r boost-install-dir/include/boost-1_41/boost /include/
  >     $

The libgcrpyt Library
  Download libgcrypt-1.5.0.tar.bz2 and libgpg-error-1.10.tar.bz2 (newer versions should also work) from http://www.gnupg.org/download/index.en.html. cd to the directory where the two downloaded files are (make sure the path to this directory does not contain spaces)

  >     $ tar xjf libgpg-error-1.10.tar.bz2
  >     $ cd libgpg-error-1.10
  >     $ ./configure --disable-shared --enable-static
  >     lots of output
  >     $ make
  >     lots of output
  >     $ make install
  >     lots of output
  >     $

  (the previous step might hang when converting from ISO-8859-2 to UTF-8 late in the build process. Press ctrl-c and proceed)

  >     $ cd ..
  >     $ tar xjf libgcrypt-1.5.0.tar.bz2
  >     $ cd libgcrypt
  >     $ ./configure --disable-shared --enable-static
  >     lots of output
  >     $ make
  >     lots of output
  >     $ make install
  >     lots of output
  >     $

You now have all the prerequisites required to build the srecord tools.

## Building SRecord

cd to the directory where you unpacked the srecord source code.

Now we can start the actual build process:

Start configure for srecord:

>     $ CPPFLAGS="-static -I/include -I/usr/local/include" \
>     LDFLAGS=" -L/lib -L/usr/local/lib" \
>     CC='gcc -static-libgcc' \
>     CXX='g++ -static-libgcc -static-libstdc++' \
>     LIBS=-lgpg-error \
>     ./configure
>     lots of output
>     $

After configure has run successfully, start the build process:

>     $ make
>     lots of output
>     $

After successful build process, run the tests:

>     $ make -i sure
>     lots of output
>     $

All tests should succeed.

Next, reduce the size of the built programs by removing debugging information:

>     $ cd bin
>     $ strip *.exe
>     $

Finally, move `srec_cat.exe`, `srec_info.exe` and `srec_cmp.exe` from the bin directory to where you want them, you can then delete everything else in the bin-directory.

You should now have working SRecord tools.

This is how the executables on sourceforge.net were built. .\" ------------------------------------------------------------------------

| SRecord is maintained by Scott Finneran <scottfinneran@yahoo.com.au> and is freely distributable under the terms and conditions of the GNU GPL. |  | There is more Software by Peter Miller at his home page. |

.\" ------------------------------------------------------------------------

This page is hosted by SourceForge.
This page has been accessed approximately times since .ds MO1 Jan .ds MO2 Feb .ds MO3 Mar .ds MO4 Apr .ds MO5 May .ds MO6 Jun .ds MO7 Jul .ds MO8 Aug .ds MO9 Sep .ds MO10 Oct .ds MO11 Nov .ds MO12 Dec .nr y4 \n[yr]+1900 \n[dy]-\*[MO\n[mo]]-\n[y4].
/* vim: set ts=8 sw=4 et : */