Skip to content

Commit

Permalink
still testing gcov
Browse files Browse the repository at this point in the history
  • Loading branch information
markcmiller86 committed Feb 17, 2018
1 parent b41bdaa commit 15ddd19
Show file tree
Hide file tree
Showing 3 changed files with 37 additions and 25 deletions.
50 changes: 27 additions & 23 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,33 +2,37 @@ language: C


before_install:
- sudo apt-get -qq update
- sudo apt-get install -y gfortran
- pwd
- ls
- pushd /tmp
- wget http://computation.llnl.gov/projects/floating-point-compression/download/zfp-0.5.0.tar.gz
- tar -xzf zfp-0.5.0.tar.gz
- pushd zfp-0.5.0
- make DEFS=-DBIT_STREAM_WORD_TYPE=uint8
- popd
- wget https://support.hdfgroup.org/ftp/HDF5/releases/hdf5-1.8/hdf5-1.8.14/src/hdf5-1.8.14.tar.gz
- tar -xzf hdf5-1.8.14.tar.gz
- pushd hdf5-1.8.14
- patch ./tools/h5repack/h5repack_parse.c /home/travis/build/LLNL/H5Z-ZFP/test/h5repack_parse.patch
- ./configure --prefix=`pwd`/my_install --enable-production --enable-fortran --enable-fortran2003 --enable-silent-rules
- make -j4 install 1>/dev/null 2>&1
- popd
- popd
- sudo apt-get -qq update
- sudo apt-get install -y gfortran
- pwd
- ls
- pushd /tmp
- wget http://computation.llnl.gov/projects/floating-point-compression/download/zfp-0.5.2.tar.gz
- tar -xzf zfp-0.5.2.tar.gz
- pushd zfp-0.5.2
- make DEFS=-DBIT_STREAM_WORD_TYPE=uint8
- popd
- wget https://support.hdfgroup.org/ftp/HDF5/releases/hdf5-1.8/hdf5-1.8.14/src/hdf5-1.8.14.tar.gz
- tar -xzf hdf5-1.8.14.tar.gz
- pushd hdf5-1.8.14
- patch ./tools/h5repack/h5repack_parse.c /home/travis/build/LLNL/H5Z-ZFP/test/h5repack_parse.patch
- ./configure --prefix=`pwd`/my_install --enable-production --enable-fortran --enable-fortran2003 --enable-silent-rules
- make -j4 install 1>/dev/null 2>&1
- popd
- popd

install: true

script:
- make FCFLAGS="-O0 -fPIC --coverage -fprofile-arcs -ftest-coverage" CFLAGS="-O0 -fPIC --coverage" LDFLAGS=--coverage FC=gfortran CC=gcc ZFP_HOME=/tmp/zfp-0.5.0 HDF5_HOME=/tmp/hdf5-1.8.14/my_install check
- ls -R
- pushd src; ls; gcov H5Zzfp_lib H5Zzfp_plugin H5Zzfp_props; popd
- pushd test; ls; gcov test_read_lib test_write_lib test_write_plugin; popd
- make FCFLAGS="-O0 -fPIC --coverage -fprofile-arcs -ftest-coverage" \
CFLAGS="-O0 -fPIC --coverage" \
LDFLAGS="--coverage -lm" \
FC=gfortran CC=gcc \
ZFP_HOME=/tmp/zfp-0.5.2 \
HDF5_HOME=/tmp/hdf5-1.8.14/my_install check
- pushd src; gcov -a H5Zzfp_lib H5Zzfp_plugin H5Zzfp_props; popd
- pushd test; gcov -a test_read_lib test_write_lib test_write_plugin; popd

after_success:
- bash <(curl -s https://codecov.io/bash)
- bash <(curl -s https://codecov.io/bash)

11 changes: 9 additions & 2 deletions docs/interfaces.rst
Original file line number Diff line number Diff line change
Expand Up @@ -134,9 +134,16 @@ interface is the only interface available for Fortran callers.
Plugin vs. Library Operation
----------------------------

The filter is designed to be compiled for use as both a standalone HDF5_ *plugin*
The filter is designed to be compiled for use as both a standalone HDF5_
`dynamically loaded HDF5 plugin <https://support.hdfgroup.org/HDF5/doc/Advanced/DynamicallyLoadedFilters/HDF5DynamicallyLoadedFilters.pdf>`_.
and as an explicitly linked *library*.
When it is used as a plugin, all HDF5_ applications are *required*
When it is used as a plugin, it is a best practice to link the ZFP_ library
into the plugin dynamic/shared object as a *static* library. Why? In so doing,
we ensure that all ZFP_ public namespace symbols remain *confined* to the plugin
so as not to interfere with any application that may be directly explicitly linking
to the ZFP_ library for other reasons.

All HDF5_ applications are *required*
to *find* the plugin dynamic library (named ``lib*.{so,dylib}``)
in a directory specified by the enviornment
variable, ``HDF5_PLUGIN_PATH``. Currently, the HDF5 library offers
Expand Down
1 change: 1 addition & 0 deletions src/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -63,3 +63,4 @@ clean:
rm -rf plugin
rm -f libh5zzfp.a *.o *.[mM][oO][dD]
rm -f *.gcno *.gcda *.gcov
rm -f H5Zzfp_props_f.mod

0 comments on commit 15ddd19

Please sign in to comment.