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

lib{uthash}: h{**} $intf_libs

# Build options.
#
out_pfx = [dir_path] $out_root/include/
src_pfx = [dir_path] $src_root/include/

c.poptions =+ "-I$out_pfx" "-I$src_pfx"

# Export options.
#
lib{uthash}:
{
  c.export.poptions = "-I$out_pfx" "-I$src_pfx"
  c.export.libs = $intf_libs
}

# Make sure headers installed into, say, /usr/include/uthash/ can also
# be included without the directory prefix for backwards compatibility.
#
lib{uthash}: c.pkgconfig.include = include/ include/uthash/

# Install into the uthash/ subdirectory of, say, /usr/include/
# recreating subdirectories.
#
h{*}:
{
  install         = include/uthash/
  install.subdirs = true
}
