#!/bin/sh

# Copyright © 2009 Jakub Wilk
#
# This package is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; version 2 dated June, 1991.

exec > paths.hh
cat <<EOF
/* This file was automatically generated by \`\`$0\`\`. */

#ifndef PDF2DJVU_PATHS
#define PDF2DJVU_PATHS
namespace paths
{
EOF

while [ $# -gt 0 ]
do
  key="$1"
  value="$2"
  printf '  static const char %s[] = "%s";\n' "$key" "$value"
  shift 2
done

cat <<EOF
}
#endif
EOF
