# libdmtx - open source software for reading and writing Data Matrix barcodes.
# http://www.libdmtx.org/

[buildout]
extends =
  ../autoconf/buildout.cfg
  ../automake/buildout.cfg
  ../bzip2/buildout.cfg
  ../imagemagick/buildout.cfg
  ../jbigkit/buildout.cfg
  ../libtool/buildout.cfg
  ../m4/buildout.cfg
  ../patch/buildout.cfg
  ../zlib/buildout.cfg
parts =
  libdmtx
  dmtx-utils

[libdmtx]
recipe = slapos.recipe.cmmi
shared = true
pre-configure =
  ./autogen.sh
url = https://github.com/dmtx/libdmtx/archive/refs/tags/v0.7.4.tar.gz
md5sum = aee0184c1374242996c9991a3133ada9
configure-options =
  --disable-static
environment =
  PATH=${m4:location}/bin:${autoconf:location}/bin:${automake:location}/bin:${pkgconfig:location}/bin:${libtool:location}/bin:%(PATH)s
  ACLOCAL_PATH=${pkgconfig:location}/share/aclocal:${libtool:location}/share/aclocal

[dmtx-utils]
recipe = slapos.recipe.cmmi
pre-configure =
  ./autogen.sh
url = https://github.com/dmtx/dmtx-utils/archive/refs/tags/v0.7.4.tar.gz
md5sum = cefffcdfd02d90b668dac6c24215a17c
configure-options =
  --disable-static
patch-options = -p1
patches =
  ${:_profile_base_location_}/imagemagick-7.patch#7fcbbfe7f15b92ac840efb2d13729582
environment =
  PATH=${m4:location}/bin:${autoconf:location}/bin:${automake:location}/bin:${pkgconfig:location}/bin:${libtool:location}/bin:${patch:location}/bin:%(PATH)s
  PKG_CONFIG_PATH=${imagemagick:location}/lib/pkgconfig:${libdmtx:location}/lib/pkgconfig
  CPPFLAGS=-I${libdmtx:location}/include
  LDFLAGS=-Wl,-rpath=${jbigkit:location}/lib -Wl,-rpath=${bzip2:location}/lib -Wl,-rpath=${zlib:location}/lib -Wl,-rpath=${libdmtx:location}/lib -L${libdmtx:location}/lib
  ACLOCAL_PATH=${pkgconfig:location}/share/aclocal:${libtool:location}/share/aclocal
