=== modified file 'debian/changelog' --- debian/changelog 2012-05-24 10:13:23 +0000 +++ debian/changelog 2012-10-31 15:44:58 +0000 @@ -1,3 +1,9 @@ +libpng (1.2.49-1ubuntu2) quantal; urgency=low + + * Added a compile/link/run autopkg test. + + -- Rafał Cieślak Wed, 31 Oct 2012 16:43:53 +0100 + libpng (1.2.49-1ubuntu1) quantal; urgency=low * Merge from Debian unstable. Remaining changes: === modified file 'debian/control' --- debian/control 2012-05-24 10:13:23 +0000 +++ debian/control 2012-10-31 11:37:57 +0000 @@ -30,6 +30,7 @@ Conflicts: libpng2-dev, libpng-dev, libpng12-0-dev, libpng2 (<< 1.0.12-3) Provides: libpng-dev, libpng12-0-dev, libpng3-dev Replaces: libpng3-dev (<= 1.2.5), libpng12-0-dev +XS-Testsuite: autopkgtest Description: PNG library - development libpng is a library implementing an interface for reading and writing PNG (Portable Network Graphics) format files. === added directory 'debian/tests' === added file 'debian/tests/build' --- debian/tests/build 1970-01-01 00:00:00 +0000 +++ debian/tests/build 2012-10-31 11:37:57 +0000 @@ -0,0 +1,25 @@ +#!/bin/sh +# autopkgtest check: Builds a small application against libpng, checking +# if it compiles, links and runs successfully. +# Author: Rafał Cieślak + +set -e + +WORKDIR=$(mktemp -d) +trap "rm -rf $WORKDIR" 0 INT QUIT ABRT PIPE TERM +cd $WORKDIR +cat < build_test.c +#include +int main(int argc, char** argv) { + png_structp png_ptr = NULL; + //Just creating a simple wrie struct. + png_ptr = png_create_write_struct (PNG_LIBPNG_VER_STRING, NULL, NULL, NULL); + if(!png_ptr) return 1; + return 0; +} +EOF +gcc -o build_test build_test.c -lpng +echo "build: OK" +[ -x build_test ] +./build_test +echo "run: OK" === added file 'debian/tests/control' --- debian/tests/control 1970-01-01 00:00:00 +0000 +++ debian/tests/control 2012-10-31 11:37:57 +0000 @@ -0,0 +1,2 @@ +Tests: build +Depends: build-essential, libpng12-dev