diff --git a/README.md b/README.md index 6a78d2af..01dffca5 100644 --- a/README.md +++ b/README.md @@ -48,6 +48,7 @@ Downloads: [[Source](http://exiv2.dyndns.org/0.27.0.1/bundles/exiv2-0.27.0.1-Sou The file "ReadMe.txt" in a bundle describes how to install/link code with libraries for their respective platform. The file [license.txt](license.txt) in a bundle describes is a copy of GPLv2 License +[TOC](#TOC) ## 2 Building and Installing @@ -68,19 +69,20 @@ You need CMake to build Exiv2: https://cmake.org/download/ | /usr/local/bin | for the `exiv2` utility | | /usr/local/include/exiv2 | for header files | +[TOC](#TOC) ### 2.2 Build/Install Exiv2 with Visual Studio We recommend that you use cocan with CMake to build Exiv2 with Visual Studio. See [README-CONAN](README-CONAN.md) for more information +[TOC](#TOC) ### 2.3 Uninstall Exiv2 on a UNIX-like system: $ sudo make uninstall [TOC](#TOC) - ### 2.4 Build options @@ -128,7 +130,6 @@ $ cmake -DBUILD_SHARED_LIBS=On -DEXIV2_ENABLE_NLS=OFF ``` [TOC](#TOC) - ### 2.5 Dependencies @@ -152,7 +153,6 @@ corresponding development packages (for the header files and static libraries). [TOC](#TOC) - ### 2.6 Consuming Exiv2 with CMake @@ -182,7 +182,6 @@ To build the documentation, you will need the following products: | pkg-config | http://pkg-config.freedesktop.org/wiki/ | [TOC](#TOC) - ### 2.8 Building Exiv2 Packages @@ -219,7 +218,6 @@ CPack: - package: /media/linuxDev/programming/exiv2/build/exiv2-0.27.0.1-Source. You may prefer to run `$ cmake --build . --config Release --target package_source` [TOC](#TOC) - ## 3 License and Support @@ -248,13 +246,11 @@ Foundation, Inc., 51 Franklin Street, 5th Floor, Boston, MA 02110-1301 USA. [TOC](#TOC) - ### 3.2 Support For new bug reports and feature requests, please open an issue in Github. [TOC](#TOC) - ## 4 Platform Notes @@ -278,8 +274,8 @@ $ mkdir build ; cd build ; $ cmake .. -G "Unix Makefiles" $ make ``` -[TOC](#TOC) +[TOC](#TOC) ### 4.2 MacOS-X @@ -290,7 +286,6 @@ You should build and install libexpat and zlib from source. You should build and install CMake from source. [TOC](#TOC) - ### 4.3 MinGW/msys2 @@ -347,7 +342,6 @@ $ make The exiv2 command line program provides a `--grep` option which filters output. The implementation requires the header file `` and supporting library to be available during the build. When not available, the option degenerates to a substring match. Because there are multiple versions of `` available on the MinGW platform, detection of Regex is always disabled on this platform. [TOC](#TOC) - ### 4.4 Cygwin @@ -363,7 +357,6 @@ Download and build cmake from source because I can't get the cygwin installed cm To build cmake from source (for 3.11+), you need libncurses. [TOC](#TOC) - ### 4.5 Microsoft Visual C++ @@ -375,7 +368,6 @@ As well as Microsoft Visual Studio, you will need to install CMake, Python3, and 3) Conan can be installed using python/pip. Details in README-CONAN.md [TOC](#TOC) - ## 5 Running the test suite @@ -386,41 +378,43 @@ The test suite is a mix of bash and python scripts. The python scripts are new You can run the suite directly from the build: +``` $ make build ... $ make tests ... lots of output ... Summary report +``` -You can run individual tests in the test directory using the environment string EXIV2_BINDIR to specify the location of the build artifacts: +You can run individual tests in the test directory using EXIV2\_BINDIR to specify the location of the build artifacts. For Cygwin and MinGW/msys builds, set EXIV2_EXT=.exe +``` rmills@rmillsmbp-w7 ~/gnu/github/exiv2/exiv2/build $ cd ../test - rmills@rmillsmbp-w7 ~/gnu/github/exiv2/exiv2/test $ env EXIV2_BINDIR=${PWD}/../build/bin ./icc-test.sh ICC jpg md5 webp md5 png md5 jpg md5 all testcases passed. rmills@rmillsmbp-w7 ~/gnu/github/exiv2/exiv2/test $ env EXIV2_BINDIR=${PWD}/../build/bin make newtests +``` [TOC](#TOC) - ### 5.2 Running tests on Visual Studio builds -Use the bash interpreter for MinGW/msys2 to run the test suite. +Use the bash interpreter for MinGW/msys2 to run the test suite. It's essential to have a DOS Python3 interpreter on your path. The variables EXIV2\_BINDIR and EXIV2\_EXT enable the test suite to locate the MSVC build artifacts. -$ cd ...../build/../test +``` +$ cd /build +$ cd ../test +$ PATH="/c/Python36:$PATH" $ export EXIV2_EXT=.exe $ export EXIV2_BINDIR=${PWD}/../build/bin +``` -It's essential to have a DOS Python3 interpreter on your path. - -$ PATH="/c/Python36:$PATH" - -These variables enables the test suite to locate the MSVC build artifacts and you can follow the guidelines for UNIX-like systems above. +You can proceed to execute the components of the test suite as described for Unix type systems: ``` -$ make tests +$ make test $ make newtests $ ./icc-test.sh ``` diff --git a/contrib/buildserver/build.sh b/contrib/buildserver/build.sh index 5a06162f..c0fbd3a8 100755 --- a/contrib/buildserver/build.sh +++ b/contrib/buildserver/build.sh @@ -1,68 +1,95 @@ #!/bin/bash syntax() { - echo "usage: $0 { --help | -? | -h | platform | option | switch }+ " - echo "platform: all | cygwin | linux | macosx | mingw | msvc " - echo "switch: --32 | --64 | --2015 | --2017 --publish | --verbose | --static " - echo "option: --branch x | --server x | --user x" + echo "usage: $0 { --help | -? | -h | platform | option | switch }+ " + echo "platform: all | cygwin | linux | macosx | mingw | msvc " + echo "switch: --32 | --64 | --2015 | --2017 --publish | --verbose | --static | --status" + echo "option: --branch x | --server x | --user x" } announce() { - echo ++++++++++++++++++++++++++++++++ - echo $* - echo ++++++++++++++++++++++++++++++++ + if [ "$status" != "1" ]; then + echo ++++++++++++++++++++++++++++++++ + echo $* + echo ++++++++++++++++++++++++++++++++ + fi } bomb() { - echo "*** $1 requires an argument ***" >&2 - exit 1 + echo "*** $1 requires an argument ***" >&2 + exit 1 } unixBuild() { -announce $1 $2 -! ssh $1 ${command} <&2; help=1; ;; + --status) status=1 ;; + --server) if [ $# -gt 0 ]; then server=$1; shift; else bomb $arg ; fi ;; + --branch) if [ $# -gt 0 ]; then branch=$1; shift; else bomb $arg ; fi ;; + --user) if [ $# -gt 0 ]; then user=$1 ; shift; else bomb $arg ; fi ;; + *) echo "invalid option: $arg" 1>&2; help=1; ;; esac - if [ "$#" != "0" ]; then shift ; fi done if [ $help == 1 ]; then - syntax; - exit 0; + syntax; + exit 0; fi -if [ "$b64" == "0" -a "$b32" == "0" ]; then b64=1; fi -if [ "$b64" == "1" -a "$b32" == "1" ]; then - echo "*** can't specify --64 && --32 ***" >&2 - exit 1 +if [ "$all" == "1" ]; then + cygwin=1; linux=1; macosx=1; mingw=1; msvc=1; + if [ "$b64" == "0" -a "$b32" == "0" ]; then + b64=1;b32=1 + fi fi +if [ "$b64" == "0" -a "$b32" == "0" ]; then b64=1; fi +## +# begin builds if [ $linux == 1 ]; then -command='' -cd=/home/rmills/gnu/github/exiv2/ -unixBuild ${user}@${server}-ubuntu Linux + command='' + cd=/home/rmills/gnu/github/exiv2/ + unixBuild ${user}@${server}-ubuntu Linux fi if [ $macosx == 1 ]; then @@ -133,10 +169,16 @@ if [ $macosx == 1 ]; then fi if [ $mingw == 1 ]; then - command='msys64' - if [ $b32 == 1 ]; then command='msys32' ; fi - cd=/home/rmills/gnu/github/exiv2/ - unixBuild ${user}@${server}-w7 MinGW + if [ $b64 == 1 ]; then + command='msys64' + cd=/home/rmills/gnu/github/exiv2/ + unixBuild ${user}@${server}-w7 MinGW/32 + fi + if [ $b32 == 1 ]; then + command='msys32' + cd=/home/rmills/gnu/github/exiv2/ + unixBuild ${user}@${server}-w7 MinGW/32 + fi fi if [ $cygwin == 1 ]; then @@ -146,6 +188,7 @@ if [ $cygwin == 1 ]; then fi if [ $msvc == 1 ]; then + command='' msvcBuild ${user}@${server}-w7 fi