intf_libs = # Interface dependencies.
impl_libs = # Implementation dependencies.
#import xxxx_libs += libhello%lib{hello}

lib{simplewebp}: libul{simplewebp}: {h c}{**} $impl_libs $intf_libs

libs{simplewebp}: def{simplewebp}: include = ($c.target.system == 'win32-msvc')
def{simplewebp}: libul{simplewebp}

# Build options. $src_base so the public include is <simplewebp.h>.
#
c.poptions =+ "-I$out_base" "-I$src_base"

if ($c.target.system == 'mingw32')
  c.loptions += -Wl,--export-all-symbols

# Export options. Do not export SIMPLEWEBP_IMPLEMENTATION.
#
lib{simplewebp}:
{
  c.export.poptions = "-I$out_root" "-I$src_root"
  c.export.libs = $intf_libs
}

# For pre-releases use the complete version to make sure they cannot
# be used in place of another pre-release or the final version. See
# the version module for details on the version.* variable values.
#
if $version.pre_release
  lib{simplewebp}: bin.lib.version = "-$version.project_id"
else
  lib{simplewebp}: bin.lib.version = "-$version.major.$version.minor"

# Install into include/simplewebp/.
#
h{*}:
{
  install         = include/simplewebp/
  install.subdirs = true
}
