Tango-icon-naming is a project mainly written in Shell, based on the GPL-2.0 license.
icon-naming-utils is a script for maintaining backwards compatibility with current desktop icon themes, while migrating to the names specified in the Icon Naming Specification [1].
The recommended method for using icon-naming-utils is via the Makefile scripts used to build a project. An example of how to do this, in an automake-parsed Makefile.am, is shown below:
size = 32x32 context = actions
iconsdir = $(themedir)/$(size)/$(context)
install-data-local: install-iconsDATA (cd $(DESTDIR)$(themedir)/$(size) && $(ICONMAP) -c $(context))
And in configure.{in,ac} you should have:
AC_SUBST(themedir, "\${datadir}/icons/Theme")
UTILS_REQUIRED=0.8.2
AC_MSG_CHECKING([icon-naming-utils >= $UTILS_REQUIRED])
PKG_CHECK_EXISTS(icon-naming-utils >= $UTILS_REQUIRED,
have_utils=yes, have_utils=no)
if test "x$have_utils" = "xyes"; then
UTILS_PATH="$PKG_CONFIG --variable=program_path icon-naming-utils
"
ICONMAP="$UTILS_PATH/icon-name-mapping"
AC_SUBST(ICONMAP)
AC_MSG_RESULT([yes])
else
AC_MSG_RESULT([no])
AC_MSG_ERROR([icon-naming-utils >= $UTILS_REQUIRED is required to build
and install tango-icon-theme])
fi
In this example, we define $(themedir) to point to the theme's install path, and ICONMAP gets defined as the path to the icon-name-mapping script. This script is not installed in a normal $(bindir) path, as it is not intended to be run by users by hand, but to be called from scripts, such as Makefiles.
[1] http://www.freedesktop.org/wiki/Standards_2ficon_2dnaming_2dspec