Skip to content

libexif/libexif-testsuite

Repository files navigation

		libexif-testsuite
		-----------------

This is a testsuite for libexif and exif. Its usage requires the usual
development enviroment to compile libexif, exif, and some testcases.


Legal stuff:
------------

This testsuite consists of two parts: source code and testcase data files:

  * The source code of this testsuite framework is licensed under GPL or
    LGPL. See the respective sources in src/ for details.

  * The testcase data files are copyrighted by their respective copyright
    holders. These files are not licensed for anything else but use as
    test data in their respective testcase.
    For all other uses, contact the respective copyright holders for
    license modalities.

That is probably not proper legalese, but you get the idea.


Getting libexif-testsuite:
--------------------------

If you happen to have a personal access method to the CVS repo of some
module mentioned in build-config.txt, you may want to add a line
"${anonymous_cvsroot} ${your_cvsroot} to build-config.cvsroot.map.

Get libexif-testsuite via Git and change into its directory:

    git clone https://github.com/libexif/libexif-testsuite.git
    cd libexif-testsuite

Then run

    ./build-config.sh

or, if that fails,

    cd src

and check out the other modules according to the definitions from
build-config.txt.

If you got libexif-testsuite from a tarball, the source subdirectories
should already be there. To get the missing subdirectories, you can
also run build-config.sh.


Initialize the buildsystem:
---------------------------

Run

    autoreconf -vis


Configure the build system:
---------------------------

Run

    ./configure --help=recursive

to get help on all the parameters for subprojects.

Note that some subproject options will be automatically set by
libexif-testsuite. This mostly concerns the *_CFLAGS and *_LIBS
for the libraries libexif-testsuite provides by itself.

Then run (for an in-tree build)

    ./configure

with your favourite configure parameters. Or, for an out-of-tree build:

    mkdir ../libexif-testsuite-build
    cd ../libexif-testsuite-build
    ../libexif-testsuite/configure

with your favourite configure parameters.


Cross-compilation:
------------------

This is an example using "i586-mingw32msvc" as the system for which
you want to compile (i.e. i586-mingw32msvc-gcc will be the compiler).
The build system is i686-pc-linux (you can run config.guess to
determine the build system).

Cross-compile popt-1.7 and install it:

    cd popt-1.7
    mkdir _win32 && cd _win32
    ../configure --prefix="$HOME/root/i586-mingw32msv" \
         --host=i586-mingw32msvc --build=i686-pc-linux
    make all
    make install

Then you can build libexif-testsuite for that platform by running:

    mkdir _win32 && cd _win32
    ../configure --prefix=/tmp/lt-win32-inst \
        --host=i586-mingw32msvc --build=i686-pc-linux \
        POPT_LIBS="-L$HOME/root/i586-mingw32msvc/lib -lpopt" \
	POPT_CFLAGS="-I$HOME/root/i586-mingw32msvc/include"
    make all
    make install

If you have an emulator properly installed for the binaries, even
"make check" will give results.


Run the tests:
--------------

Run

    make check

and examine the output.


Check the distribution mechanism:
---------------------------------

Run

    make distcheck

and see whether it finishes without errors.